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

Side by Side Diff: chrome/browser/ui/browser_instant_controller_unittest.cc

Issue 1336823003: Move chrome::HostDesktopType to ui::HostDesktopType (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@base_session_service_delegate_impl
Patch Set: Fix build on Mac and CrOS Created 5 years, 3 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
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 #include <string> 5 #include <string>
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/memory/scoped_vector.h" 8 #include "base/memory/scoped_vector.h"
9 #include "base/metrics/field_trial.h" 9 #include "base/metrics/field_trial.h"
10 #include "chrome/browser/chrome_notification_types.h" 10 #include "chrome/browser/chrome_notification_types.h"
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 EXPECT_EQ(GURL(chrome::kChromeSearchLocalNtpUrl), observer->current_url()) 197 EXPECT_EQ(GURL(chrome::kChromeSearchLocalNtpUrl), observer->current_url())
198 << test.description; 198 << test.description;
199 // The navigation to Local NTP should be definitive i.e. can't go back. 199 // The navigation to Local NTP should be definitive i.e. can't go back.
200 EXPECT_FALSE(observer->can_go_back()); 200 EXPECT_FALSE(observer->can_go_back());
201 } 201 }
202 } 202 }
203 } 203 }
204 204
205 TEST_F(BrowserInstantControllerTest, BrowserWindowLifecycle) { 205 TEST_F(BrowserInstantControllerTest, BrowserWindowLifecycle) {
206 scoped_ptr<BrowserWindow> window(CreateBrowserWindow()); 206 scoped_ptr<BrowserWindow> window(CreateBrowserWindow());
207 Browser::CreateParams params(profile(), chrome::HOST_DESKTOP_TYPE_NATIVE); 207 Browser::CreateParams params(profile(), ui::HOST_DESKTOP_TYPE_NATIVE);
208 params.window = window.get(); 208 params.window = window.get();
209 scoped_ptr<Browser> browser(new Browser(params)); 209 scoped_ptr<Browser> browser(new Browser(params));
210 InstantServiceObserver* bic; 210 InstantServiceObserver* bic;
211 bic = browser->instant_controller(); 211 bic = browser->instant_controller();
212 EXPECT_TRUE(IsInstantServiceObserver(bic)) 212 EXPECT_TRUE(IsInstantServiceObserver(bic))
213 << "New BrowserInstantController should register as InstantServiceObserver"; 213 << "New BrowserInstantController should register as InstantServiceObserver";
214 214
215 browser.reset(NULL); 215 browser.reset(NULL);
216 window.reset(NULL); 216 window.reset(NULL);
217 EXPECT_FALSE(IsInstantServiceObserver(bic)) 217 EXPECT_FALSE(IsInstantServiceObserver(bic))
218 << "New BrowserInstantController should register as InstantServiceObserver"; 218 << "New BrowserInstantController should register as InstantServiceObserver";
219 } 219 }
220 220
221 } // namespace 221 } // namespace
222 222
223 } // namespace chrome 223 } // namespace chrome
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698