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

Side by Side Diff: ios/web/shell/test/earl_grey/shell_earl_grey.mm

Issue 2665423002: Update web shell app to not load dev.chromium.org on launch. (Closed)
Patch Set: remove chrome code Created 3 years, 10 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
« no previous file with comments | « ios/web/shell/test/earl_grey/shell_base_test_case.mm ('k') | ios/web/shell/view_controller.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #import "ios/web/shell/test/earl_grey/shell_earl_grey.h" 5 #import "ios/web/shell/test/earl_grey/shell_earl_grey.h"
6 6
7 #import <EarlGrey/EarlGrey.h> 7 #import <EarlGrey/EarlGrey.h>
8 8
9 #import "ios/testing/wait_util.h" 9 #import "ios/testing/wait_util.h"
10 #import "ios/web/public/test/earl_grey/js_test_util.h" 10 #import "ios/web/public/test/earl_grey/js_test_util.h"
(...skipping 16 matching lines...) Expand all
27 [GREYCondition conditionWithName:@"Wait for page to complete loading." 27 [GREYCondition conditionWithName:@"Wait for page to complete loading."
28 block:^BOOL { 28 block:^BOOL {
29 return !web::shell_test_util::IsLoading(); 29 return !web::shell_test_util::IsLoading();
30 }]; 30 }];
31 GREYAssert([condition waitWithTimeout:testing::kWaitForPageLoadTimeout], 31 GREYAssert([condition waitWithTimeout:testing::kWaitForPageLoadTimeout],
32 @"Page did not complete loading."); 32 @"Page did not complete loading.");
33 33
34 web::WebState* webState = web::shell_test_util::GetCurrentWebState(); 34 web::WebState* webState = web::shell_test_util::GetCurrentWebState();
35 if (webState->ContentIsHTML()) 35 if (webState->ContentIsHTML())
36 web::WaitUntilWindowIdInjected(webState); 36 web::WaitUntilWindowIdInjected(webState);
37
38 // Ensure any UI elements handled by EarlGrey become idle for any subsequent
39 // EarlGrey steps.
40 [[GREYUIThreadExecutor sharedInstance] drainUntilIdle];
37 } 41 }
38 42
39 @end 43 @end
OLDNEW
« no previous file with comments | « ios/web/shell/test/earl_grey/shell_base_test_case.mm ('k') | ios/web/shell/view_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698