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

Unified Diff: ios/chrome/browser/voice/text_to_speech_listener_unittest.mm

Issue 2506253007: [ObjC ARC] Converts ios/chrome/browser/voice:unit_tests to ARC.Automatically generated ARCMigrate… (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « ios/chrome/browser/voice/BUILD.gn ('k') | ios/chrome/browser/voice/text_to_speech_parser_unittest.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/browser/voice/text_to_speech_listener_unittest.mm
diff --git a/ios/chrome/browser/voice/text_to_speech_listener_unittest.mm b/ios/chrome/browser/voice/text_to_speech_listener_unittest.mm
index ed2670d5d5c8cd081d085ddc84e4caa90738e455..0c632f53e3c5b371226455a142fee01ed36ac785 100644
--- a/ios/chrome/browser/voice/text_to_speech_listener_unittest.mm
+++ b/ios/chrome/browser/voice/text_to_speech_listener_unittest.mm
@@ -11,6 +11,10 @@
#include "testing/gtest_mac.h"
#import "third_party/google_toolbox_for_mac/src/Foundation/GTMStringEncoding.h"
+#if !defined(__has_feature) || !__has_feature(objc_arc)
+#error "This file requires ARC support."
+#endif
+
namespace {
NSString* const kHTMLFormat =
@"<html><head><script>%@</script></head><body></body></html>";
@@ -26,7 +30,7 @@ NSString* const kValidVoiceSearchScript =
}
// The expected audio data to be returned by the TextToSpeechListener.
-@property(nonatomic, retain) NSData* expectedAudioData;
+@property(nonatomic, strong) NSData* expectedAudioData;
// Whether |-textToSpeechListener:didReceiveResult:| was called.
@property(nonatomic, assign) BOOL audioDataReceived;
@@ -38,7 +42,7 @@ NSString* const kValidVoiceSearchScript =
@synthesize audioDataReceived = _audioDataReceived;
- (void)setExpectedAudioData:(NSData*)expectedAudioData {
- _expectedAudioData.reset([expectedAudioData retain]);
+ _expectedAudioData.reset(expectedAudioData);
}
- (NSData*)expectedAudioData {
« no previous file with comments | « ios/chrome/browser/voice/BUILD.gn ('k') | ios/chrome/browser/voice/text_to_speech_parser_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698