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

Side by Side Diff: chrome/browser/ui/cocoa/media_picker/desktop_media_picker_controller_unittest.mm

Issue 112913004: Update some uses of UTF conversions in chrome/browser to use the base:: namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 12 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import "chrome/browser/ui/cocoa/media_picker/desktop_media_picker_controller.h" 5 #import "chrome/browser/ui/cocoa/media_picker/desktop_media_picker_controller.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "chrome/browser/media/desktop_media_list_observer.h" 10 #include "chrome/browser/media/desktop_media_list_observer.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 50
51 DesktopMediaPicker::DoneCallback callback = 51 DesktopMediaPicker::DoneCallback callback =
52 base::Bind(&DesktopMediaPickerControllerTest::OnResult, 52 base::Bind(&DesktopMediaPickerControllerTest::OnResult,
53 base::Unretained(this)); 53 base::Unretained(this));
54 54
55 controller_.reset( 55 controller_.reset(
56 [[DesktopMediaPickerController alloc] 56 [[DesktopMediaPickerController alloc]
57 initWithMediaList:scoped_ptr<DesktopMediaList>(media_list_) 57 initWithMediaList:scoped_ptr<DesktopMediaList>(media_list_)
58 parent:nil 58 parent:nil
59 callback:callback 59 callback:callback
60 appName:ASCIIToUTF16("Screenshare Test")]); 60 appName:base::ASCIIToUTF16("Screenshare Test")]);
61 } 61 }
62 62
63 virtual void TearDown() OVERRIDE { 63 virtual void TearDown() OVERRIDE {
64 controller_.reset(); 64 controller_.reset();
65 CocoaTest::TearDown(); 65 CocoaTest::TearDown();
66 } 66 }
67 67
68 bool WaitForCallback() { 68 bool WaitForCallback() {
69 if (!callback_called_) { 69 if (!callback_called_) {
70 base::RunLoop().RunUntilIdle(); 70 base::RunLoop().RunUntilIdle();
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 media_list_->SetSourceThumbnail(0); 179 media_list_->SetSourceThumbnail(0);
180 EXPECT_NE(version, [[items objectAtIndex:0] imageVersion]); 180 EXPECT_NE(version, [[items objectAtIndex:0] imageVersion]);
181 } 181 }
182 182
183 TEST_F(DesktopMediaPickerControllerTest, RemoveSource) { 183 TEST_F(DesktopMediaPickerControllerTest, RemoveSource) {
184 [controller_ showWindow:nil]; 184 [controller_ showWindow:nil];
185 185
186 media_list_->AddSource(0); 186 media_list_->AddSource(0);
187 media_list_->AddSource(1); 187 media_list_->AddSource(1);
188 media_list_->AddSource(2); 188 media_list_->AddSource(2);
189 media_list_->SetSourceName(1, ASCIIToUTF16("foo")); 189 media_list_->SetSourceName(1, base::ASCIIToUTF16("foo"));
190 190
191 NSArray* items = [controller_ items]; 191 NSArray* items = [controller_ items];
192 EXPECT_EQ(3U, [items count]); 192 EXPECT_EQ(3U, [items count]);
193 EXPECT_NSEQ(@"foo", [[items objectAtIndex:1] imageTitle]); 193 EXPECT_NSEQ(@"foo", [[items objectAtIndex:1] imageTitle]);
194 } 194 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698