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

Side by Side Diff: chrome/browser/profiles/profile_manager_unittest.cc

Issue 7327007: Moving notification types which are chrome specific to a new header file chrome_notification_type... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 5 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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include <string> 5 #include <string>
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/scoped_temp_dir.h" 10 #include "base/scoped_temp_dir.h"
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 std::string profile_dir("my_user"); 106 std::string profile_dir("my_user");
107 107
108 cl->AppendSwitchASCII(switches::kLoginProfile, profile_dir); 108 cl->AppendSwitchASCII(switches::kLoginProfile, profile_dir);
109 cl->AppendSwitch(switches::kTestType); 109 cl->AppendSwitch(switches::kTestType);
110 110
111 FilePath expected_default = 111 FilePath expected_default =
112 FilePath().AppendASCII(chrome::kNotSignedInProfile); 112 FilePath().AppendASCII(chrome::kNotSignedInProfile);
113 EXPECT_EQ(expected_default.value(), 113 EXPECT_EQ(expected_default.value(),
114 profile_manager_->GetCurrentProfileDir().value()); 114 profile_manager_->GetCurrentProfileDir().value());
115 115
116 profile_manager_->Observe(NotificationType::LOGIN_USER_CHANGED, 116 profile_manager_->Observe(chrome::LOGIN_USER_CHANGED,
117 NotificationService::AllSources(), 117 NotificationService::AllSources(),
118 NotificationService::NoDetails()); 118 NotificationService::NoDetails());
119 FilePath expected_logged_in(profile_dir); 119 FilePath expected_logged_in(profile_dir);
120 EXPECT_EQ(expected_logged_in.value(), 120 EXPECT_EQ(expected_logged_in.value(),
121 profile_manager_->GetCurrentProfileDir().value()); 121 profile_manager_->GetCurrentProfileDir().value());
122 VLOG(1) << temp_dir_.path().Append( 122 VLOG(1) << temp_dir_.path().Append(
123 profile_manager_->GetCurrentProfileDir()).value(); 123 profile_manager_->GetCurrentProfileDir()).value();
124 } 124 }
125 125
126 #endif 126 #endif
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 temp_dir_.path().Append(FILE_PATH_LITERAL("New Profile 2")); 226 temp_dir_.path().Append(FILE_PATH_LITERAL("New Profile 2"));
227 227
228 MockObserver mock_observer; 228 MockObserver mock_observer;
229 EXPECT_CALL(mock_observer, OnProfileCreated(testing::NotNull())).Times(2); 229 EXPECT_CALL(mock_observer, OnProfileCreated(testing::NotNull())).Times(2);
230 230
231 profile_manager_->CreateProfileAsync(dest_path1, &mock_observer); 231 profile_manager_->CreateProfileAsync(dest_path1, &mock_observer);
232 profile_manager_->CreateProfileAsync(dest_path2, &mock_observer); 232 profile_manager_->CreateProfileAsync(dest_path2, &mock_observer);
233 233
234 message_loop_.RunAllPending(); 234 message_loop_.RunAllPending();
235 } 235 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_manager.cc ('k') | chrome/browser/renderer_host/chrome_render_view_host_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698