Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Side by Side Diff: chrome/android/javatests/src/org/chromium/chrome/browser/tabmodel/UndoTabModelTest.java

Issue 1856273002: Change all FlakyTest import to use org.chromium.base.test.util.FlakyTest (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Change @FlakyTest bug message Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package org.chromium.chrome.browser.tabmodel; 5 package org.chromium.chrome.browser.tabmodel;
6 6
7 import android.test.FlakyTest;
8 import android.test.suitebuilder.annotation.MediumTest; 7 import android.test.suitebuilder.annotation.MediumTest;
9 8
10 import org.chromium.base.ThreadUtils; 9 import org.chromium.base.ThreadUtils;
10 import org.chromium.base.test.util.FlakyTest;
11 import org.chromium.chrome.browser.tab.Tab; 11 import org.chromium.chrome.browser.tab.Tab;
12 import org.chromium.chrome.browser.tabmodel.TabModel.TabLaunchType; 12 import org.chromium.chrome.browser.tabmodel.TabModel.TabLaunchType;
13 import org.chromium.chrome.browser.tabmodel.TabModel.TabSelectionType; 13 import org.chromium.chrome.browser.tabmodel.TabModel.TabSelectionType;
14 import org.chromium.chrome.test.ChromeTabbedActivityTestBase; 14 import org.chromium.chrome.test.ChromeTabbedActivityTestBase;
15 import org.chromium.content.browser.test.util.CallbackHelper; 15 import org.chromium.content.browser.test.util.CallbackHelper;
16 import org.chromium.content_public.browser.LoadUrlParams; 16 import org.chromium.content_public.browser.LoadUrlParams;
17 17
18 import java.util.concurrent.TimeoutException; 18 import java.util.concurrent.TimeoutException;
19 19
20 /** 20 /**
(...skipping 969 matching lines...) Expand 10 before | Expand all | Expand 10 after
990 * 9. CloseTab(1, allow undo) [ 3s ] [ 1 2 ] [ 1 2 3s ] 990 * 9. CloseTab(1, allow undo) [ 3s ] [ 1 2 ] [ 1 2 3s ]
991 * 10. CommitClose(2) [ 3s ] [ 1 ] [ 1 3 s ] 991 * 10. CommitClose(2) [ 3s ] [ 1 ] [ 1 3 s ]
992 * 11. CancelClose(1) [ 1 3s ] - [ 1 3 s ] 992 * 11. CancelClose(1) [ 1 3s ] - [ 1 3 s ]
993 * 12. CloseTab(3, allow undo) [ 1s ] [ 3 ] [ 1s 3 ] 993 * 12. CloseTab(3, allow undo) [ 1s ] [ 3 ] [ 1s 3 ]
994 * 13. CloseTab(1, allow undo) - [ 1 3 ] [ 1s 3 ] 994 * 13. CloseTab(1, allow undo) - [ 1 3 ] [ 1s 3 ]
995 * 14. CommitAll - - - 995 * 14. CommitAll - - -
996 * 996 *
997 * @throws InterruptedException 997 * @throws InterruptedException
998 */ 998 */
999 @MediumTest 999 @MediumTest
1000 @FlakyTest // crbug.com/592969 1000 @FlakyTest(message = "crbug.com/592969")
1001 public void testOutOfOrder2() throws InterruptedException { 1001 public void testOutOfOrder2() throws InterruptedException {
1002 TabModel model = getActivity().getTabModelSelector().getModel(false); 1002 TabModel model = getActivity().getTabModelSelector().getModel(false);
1003 ChromeTabCreator tabCreator = getActivity().getTabCreator(false); 1003 ChromeTabCreator tabCreator = getActivity().getTabCreator(false);
1004 createTabOnUiThread(tabCreator); 1004 createTabOnUiThread(tabCreator);
1005 createTabOnUiThread(tabCreator); 1005 createTabOnUiThread(tabCreator);
1006 createTabOnUiThread(tabCreator); 1006 createTabOnUiThread(tabCreator);
1007 1007
1008 Tab tab0 = model.getTabAt(0); 1008 Tab tab0 = model.getTabAt(0);
1009 Tab tab1 = model.getTabAt(1); 1009 Tab tab1 = model.getTabAt(1);
1010 Tab tab2 = model.getTabAt(2); 1010 Tab tab2 = model.getTabAt(2);
(...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after
1399 checkState(model, new Tab[] { tab1 }, tab1, EMPTY, fullList, tab1); 1399 checkState(model, new Tab[] { tab1 }, tab1, EMPTY, fullList, tab1);
1400 1400
1401 // 3. 1401 // 3.
1402 saveStateOnUiThread(selector); 1402 saveStateOnUiThread(selector);
1403 fullList = new Tab[] { tab1 }; 1403 fullList = new Tab[] { tab1 };
1404 checkState(model, new Tab[] { tab1 }, tab1, EMPTY, fullList, tab1); 1404 checkState(model, new Tab[] { tab1 }, tab1, EMPTY, fullList, tab1);
1405 assertTrue(tab0.isClosing()); 1405 assertTrue(tab0.isClosing());
1406 assertFalse(tab0.isInitialized()); 1406 assertFalse(tab0.isInitialized());
1407 } 1407 }
1408 } 1408 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698