Commit 79d15aac authored by stkhapugin's avatar stkhapugin Committed by Commit bot

[ObjC ARC] Converts ios/chrome/app/safe_mode:eg_tests to ARC.

Automatically generated ARCMigrate commit
Notable issues:None
BUG=624363
TEST=None

Review-Url: https://codereview.chromium.org/2627623002
Cr-Commit-Position: refs/heads/master@{#442603}
parent f5399360
......@@ -37,6 +37,7 @@ source_set("safe_mode") {
}
source_set("eg_tests") {
configs += [ "//build/config/compiler:enable_arc" ]
testonly = true
sources = [
"safe_mode_egtest.mm",
......
......@@ -7,7 +7,6 @@
#include "base/logging.h"
#include "base/mac/foundation_util.h"
#include "base/mac/scoped_nsobject.h"
#import "ios/chrome/app/chrome_overlay_window.h"
#import "ios/chrome/app/safe_mode/safe_mode_view_controller.h"
#import "ios/chrome/browser/ui/main/main_view_controller.h"
......@@ -15,6 +14,10 @@
#import "ios/chrome/test/base/scoped_block_swizzler.h"
#import "ios/chrome/test/earl_grey/chrome_test_case.h"
#if !defined(__has_feature) || !__has_feature(objc_arc)
#error "This file requires ARC support."
#endif
namespace {
// Returns the top view controller for rendering the Safe Mode Controller.
......@@ -80,8 +83,8 @@ void AssertTryAgainButtonOnPage() {
});
// Instantiates a Safe Mode controller and displays it.
base::scoped_nsobject<SafeModeViewController> safeModeController(
[[SafeModeViewController alloc] initWithDelegate:nil]);
SafeModeViewController* safeModeController =
[[SafeModeViewController alloc] initWithDelegate:nil];
[GetActiveViewController() presentViewController:safeModeController
animated:NO
completion:nil];
......@@ -110,8 +113,8 @@ void AssertTryAgainButtonOnPage() {
});
// Instantiates a Safe Mode controller and displays it.
base::scoped_nsobject<SafeModeViewController> safeModeController(
[[SafeModeViewController alloc] initWithDelegate:nil]);
SafeModeViewController* safeModeController =
[[SafeModeViewController alloc] initWithDelegate:nil];
[GetActiveViewController() presentViewController:safeModeController
animated:NO
completion:nil];
......@@ -146,8 +149,8 @@ void AssertTryAgainButtonOnPage() {
return YES;
});
// Instantiates a Safe Mode controller and displays it.
base::scoped_nsobject<SafeModeViewController> safeModeController(
[[SafeModeViewController alloc] initWithDelegate:nil]);
SafeModeViewController* safeModeController =
[[SafeModeViewController alloc] initWithDelegate:nil];
[GetActiveViewController() presentViewController:safeModeController
animated:NO
completion:nil];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment