OLD | NEW |
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 <EarlGrey/EarlGrey.h> | 5 #import <EarlGrey/EarlGrey.h> |
6 | 6 |
7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
8 #include "base/strings/stringprintf.h" | 8 #include "base/strings/stringprintf.h" |
9 #include "base/strings/sys_string_conversions.h" | 9 #include "base/strings/sys_string_conversions.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
11 #include "components/version_info/version_info.h" | 11 #include "components/version_info/version_info.h" |
12 #include "ios/chrome/browser/chrome_url_constants.h" | 12 #include "ios/chrome/browser/chrome_url_constants.h" |
13 #import "ios/chrome/browser/ui/commands/generic_chrome_command.h" | 13 #import "ios/chrome/browser/ui/commands/generic_chrome_command.h" |
14 #include "ios/chrome/browser/ui/commands/ios_command_ids.h" | 14 #include "ios/chrome/browser/ui/commands/ios_command_ids.h" |
15 #include "ios/chrome/browser/ui/ui_util.h" | 15 #include "ios/chrome/browser/ui/ui_util.h" |
16 #import "ios/chrome/test/app/chrome_test_util.h" | 16 #import "ios/chrome/test/app/chrome_test_util.h" |
17 #import "ios/chrome/test/earl_grey/chrome_earl_grey.h" | 17 #import "ios/chrome/test/earl_grey/chrome_earl_grey.h" |
18 #import "ios/chrome/test/earl_grey/chrome_earl_grey_ui.h" | 18 #import "ios/chrome/test/earl_grey/chrome_earl_grey_ui.h" |
19 #import "ios/chrome/test/earl_grey/chrome_matchers.h" | 19 #import "ios/chrome/test/earl_grey/chrome_matchers.h" |
20 #import "ios/chrome/test/earl_grey/chrome_test_case.h" | 20 #import "ios/chrome/test/earl_grey/chrome_test_case.h" |
21 #import "ios/web/public/test/http_server.h" | 21 #include "ios/web/public/test/http_server/html_response_provider.h" |
22 #include "ios/web/public/test/http_server_util.h" | 22 #import "ios/web/public/test/http_server/http_server.h" |
23 #include "ios/web/public/test/response_providers/html_response_provider.h" | 23 #include "ios/web/public/test/http_server/http_server_util.h" |
24 #include "ios/web/public/test/url_test_util.h" | 24 #include "ios/web/public/test/url_test_util.h" |
25 #include "url/gurl.h" | 25 #include "url/gurl.h" |
26 | 26 |
27 #if !defined(__has_feature) || !__has_feature(objc_arc) | 27 #if !defined(__has_feature) || !__has_feature(objc_arc) |
28 #error "This file requires ARC support." | 28 #error "This file requires ARC support." |
29 #endif | 29 #endif |
30 | 30 |
31 using chrome_test_util::WebViewContainingText; | 31 using chrome_test_util::WebViewContainingText; |
32 using chrome_test_util::OmniboxText; | 32 using chrome_test_util::OmniboxText; |
33 | 33 |
(...skipping 556 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
590 - (BOOL)waitForServerToReceiveRequestWithURL:(GURL)URL { | 590 - (BOOL)waitForServerToReceiveRequestWithURL:(GURL)URL { |
591 return [[GREYCondition | 591 return [[GREYCondition |
592 conditionWithName:@"Wait for received request" | 592 conditionWithName:@"Wait for received request" |
593 block:^{ | 593 block:^{ |
594 return _responseProvider->last_request_url() == URL ? YES | 594 return _responseProvider->last_request_url() == URL ? YES |
595 : NO; | 595 : NO; |
596 }] waitWithTimeout:10]; | 596 }] waitWithTimeout:10]; |
597 } | 597 } |
598 | 598 |
599 @end | 599 @end |
OLD | NEW |