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

Unified Diff: ios/web/web_state/ui/crw_web_controller_observer_unittest.mm

Issue 2933363002: [ObjC ARC] Converts ios/web:ios_web_web_state_ui_unittests to ARC. (Closed)
Patch Set: Review nits. Created 3 years, 6 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 side-by-side diff with in-line comments
Download patch
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 a4f54b134520302b32fa3a20c57f04c38ba3f436..1c648930c71b41580f1229960af874e24d34f7b6 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
@@ -4,10 +4,13 @@
#import "ios/web/public/web_state/crw_web_controller_observer.h"
-#import "base/mac/scoped_nsobject.h"
#import "ios/web/test/crw_fake_web_controller_observer.h"
#import "ios/web/test/web_test_with_web_controller.h"
+#if !defined(__has_feature) || !__has_feature(objc_arc)
+#error "This file requires ARC support."
+#endif
+
namespace web {
// Test fixture to test web controller observing.
@@ -15,19 +18,17 @@ class CRWWebControllerObserverTest : public web::WebTestWithWebController {
protected:
void SetUp() override {
web::WebTestWithWebController::SetUp();
- fake_web_controller_observer_.reset(
- [[CRWFakeWebControllerObserver alloc] init]);
+ fake_web_controller_observer_ = [[CRWFakeWebControllerObserver alloc] init];
[web_controller() addObserver:fake_web_controller_observer_];
}
void TearDown() override {
[web_controller() removeObserver:fake_web_controller_observer_];
- fake_web_controller_observer_.reset();
+ fake_web_controller_observer_ = nil;
web::WebTestWithWebController::TearDown();
}
- base::scoped_nsobject<CRWFakeWebControllerObserver>
- fake_web_controller_observer_;
+ CRWFakeWebControllerObserver* fake_web_controller_observer_;
};
TEST_F(CRWWebControllerObserverTest, PageLoaded) {

Powered by Google App Engine
This is Rietveld 408576698