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

Side by Side Diff: chrome/browser/chromeos/policy/device_local_account_browsertest.cc

Issue 19869003: ChromeOS changes for GetURL refactor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing failing tests. Created 7 years, 4 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
« no previous file with comments | « chrome/browser/chromeos/offline/offline_load_page_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 <map> 5 #include <map>
6 #include <string> 6 #include <string>
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 BrowserList* browser_list = 336 BrowserList* browser_list =
337 BrowserList::GetInstance(chrome::HOST_DESKTOP_TYPE_ASH); 337 BrowserList::GetInstance(chrome::HOST_DESKTOP_TYPE_ASH);
338 EXPECT_EQ(1U, browser_list->size()); 338 EXPECT_EQ(1U, browser_list->size());
339 Browser* browser = browser_list->get(0); 339 Browser* browser = browser_list->get(0);
340 ASSERT_TRUE(browser); 340 ASSERT_TRUE(browser);
341 341
342 TabStripModel* tabs = browser->tab_strip_model(); 342 TabStripModel* tabs = browser->tab_strip_model();
343 ASSERT_TRUE(tabs); 343 ASSERT_TRUE(tabs);
344 int expected_tab_count = static_cast<int>(arraysize(kStartupURLs)); 344 int expected_tab_count = static_cast<int>(arraysize(kStartupURLs));
345 EXPECT_EQ(expected_tab_count, tabs->count()); 345 EXPECT_EQ(expected_tab_count, tabs->count());
346 for (int i = 0; i < expected_tab_count && i < tabs->count(); ++i) 346 for (int i = 0; i < expected_tab_count && i < tabs->count(); ++i) {
347 EXPECT_EQ(GURL(kStartupURLs[i]), tabs->GetWebContentsAt(i)->GetURL()); 347 EXPECT_EQ(GURL(kStartupURLs[i]),
348 tabs->GetWebContentsAt(i)->GetVisibleURL());
349 }
348 } 350 }
349 351
350 IN_PROC_BROWSER_TEST_F(DeviceLocalAccountTest, TermsOfService) { 352 IN_PROC_BROWSER_TEST_F(DeviceLocalAccountTest, TermsOfService) {
351 // Specify Terms of Service. The URL does not really matter as the test does 353 // Specify Terms of Service. The URL does not really matter as the test does
352 // not wait for the terms to load. 354 // not wait for the terms to load.
353 device_local_account_policy_.payload().mutable_termsofserviceurl()->set_value( 355 device_local_account_policy_.payload().mutable_termsofserviceurl()->set_value(
354 "http://localhost/tos"); 356 "http://localhost/tos");
355 InstallDeviceLocalAccountPolicy(); 357 InstallDeviceLocalAccountPolicy();
356 AddPublicSessionToDevicePolicy(kAccountId1); 358 AddPublicSessionToDevicePolicy(kAccountId1);
357 359
(...skipping 28 matching lines...) Expand all
386 // Verify that the Terms of Service screen is being shown. 388 // Verify that the Terms of Service screen is being shown.
387 chromeos::WizardController* wizard_controller = 389 chromeos::WizardController* wizard_controller =
388 chromeos::WizardController::default_controller(); 390 chromeos::WizardController::default_controller();
389 ASSERT_TRUE(wizard_controller); 391 ASSERT_TRUE(wizard_controller);
390 ASSERT_TRUE(wizard_controller->current_screen()); 392 ASSERT_TRUE(wizard_controller->current_screen());
391 EXPECT_EQ(chromeos::WizardController::kTermsOfServiceScreenName, 393 EXPECT_EQ(chromeos::WizardController::kTermsOfServiceScreenName,
392 wizard_controller->current_screen()->GetName()); 394 wizard_controller->current_screen()->GetName());
393 } 395 }
394 396
395 } // namespace policy 397 } // namespace policy
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/offline/offline_load_page_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698