Index: ios/chrome/browser/ui/first_run/first_run_util_unittest.mm |
diff --git a/ios/chrome/browser/ui/first_run/first_run_util_unittest.mm b/ios/chrome/browser/ui/first_run/first_run_util_unittest.mm |
index 3e4270b4ac48d1e7a042b2b5e2126ed983edaca9..5b95b3004b8d6d3842abd3fd28b03b6a506bd142 100644 |
--- a/ios/chrome/browser/ui/first_run/first_run_util_unittest.mm |
+++ b/ios/chrome/browser/ui/first_run/first_run_util_unittest.mm |
@@ -4,10 +4,13 @@ |
#import <UIKit/UIKit.h> |
-#include "base/mac/scoped_nsobject.h" |
#include "ios/chrome/browser/ui/first_run/first_run_util.h" |
#include "testing/gtest/include/gtest/gtest.h" |
+#if !defined(__has_feature) || !__has_feature(objc_arc) |
+#error "This file requires ARC support." |
+#endif |
+ |
namespace { |
TEST(UICommonTest, TestFixOrphanWord) { |
@@ -31,8 +34,7 @@ TEST(UICommonTest, TestFixOrphanWord) { |
"那只敏捷的棕色狐狸跃过那只懒狗。快速狐狸"; |
// clang-format on |
- base::scoped_nsobject<UILabel> label( |
- [[UILabel alloc] initWithFrame:CGRectMake(0, 0, 300, 500)]); |
+ UILabel* label = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, 300, 500)]; |
[label setText:englishString]; |
ios_internal::FixOrphanWord(label); |
NSRange range = [[label text] rangeOfString:@"\n"]; |