| Index: ios/web/web_state/ui/crw_web_controller_observer_unittest.mm
|
| diff --git a/ios/web/web_state/ui/crw_web_controller_observer_unittest.mm b/ios/web/web_state/ui/crw_web_controller_observer_unittest.mm
|
| index 8e1233ce2a3219638393c67e210e83144b5310e6..b070e30ede4a4aeb1389b87b527269e52d517752 100644
|
| --- a/ios/web/web_state/ui/crw_web_controller_observer_unittest.mm
|
| +++ b/ios/web/web_state/ui/crw_web_controller_observer_unittest.mm
|
| @@ -12,7 +12,7 @@
|
| #import "ios/web/public/web_state/js/crw_js_injection_manager.h"
|
| #import "ios/web/public/web_state/js/crw_js_injection_receiver.h"
|
| #import "ios/web/test/crw_fake_web_controller_observer.h"
|
| -#import "ios/web/test/web_test.h"
|
| +#import "ios/web/test/web_test_with_web_controller.h"
|
| #include "testing/gtest_mac.h"
|
|
|
| namespace web {
|
| @@ -24,11 +24,11 @@ class CRWWebControllerObserverTest : public web::WebTestWithWebController {
|
| web::WebTestWithWebController::SetUp();
|
| fake_web_controller_observer_.reset(
|
| [[CRWFakeWebControllerObserver alloc] initWithCommandPrefix:@"test"]);
|
| - [webController_ addObserver:fake_web_controller_observer_];
|
| + [web_controller() addObserver:fake_web_controller_observer_];
|
| }
|
|
|
| void TearDown() override {
|
| - [webController_ removeObserver:fake_web_controller_observer_];
|
| + [web_controller() removeObserver:fake_web_controller_observer_];
|
| fake_web_controller_observer_.reset();
|
| web::WebTestWithWebController::TearDown();
|
| }
|
| @@ -63,7 +63,7 @@ TEST_F(CRWWebControllerObserverTest, HandleCommand) {
|
| TEST_F(CRWWebControllerObserverTest, HandleImmediateCommand) {
|
| LoadHtml(@"<p></p>");
|
| ASSERT_NSNE(@"http://testimmediate#target",
|
| - [webController_ externalRequestWindowName]);
|
| + [web_controller() externalRequestWindowName]);
|
| // The only valid immediate commands are window.unload and externalRequest.
|
| base::DictionaryValue command;
|
| command.SetString("command", "externalRequest");
|
| @@ -77,7 +77,7 @@ TEST_F(CRWWebControllerObserverTest, HandleImmediateCommand) {
|
| message.c_str()]);
|
| WaitForBackgroundTasks();
|
| ASSERT_NSEQ(@"http://testimmediate#target",
|
| - [webController_ externalRequestWindowName]);
|
| + [web_controller() externalRequestWindowName]);
|
| }
|
|
|
| // Send a large number of commands and check each one is immediately received.
|
|
|