OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <algorithm> | 5 #include <algorithm> |
6 #include <string> | 6 #include <string> |
7 | 7 |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/files/file_path.h" | 9 #include "base/files/file_path.h" |
10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
246 // We don't do non-process-startup browser launches on ChromeOS. | 246 // We don't do non-process-startup browser launches on ChromeOS. |
247 // Session restore for process-startup browser launches is tested | 247 // Session restore for process-startup browser launches is tested |
248 // in session_restore_uitest. | 248 // in session_restore_uitest. |
249 #if !defined(OS_CHROMEOS) | 249 #if !defined(OS_CHROMEOS) |
250 // Verify that startup URLs are honored when the process already exists but has | 250 // Verify that startup URLs are honored when the process already exists but has |
251 // no tabbed browser windows (eg. as if the process is running only due to a | 251 // no tabbed browser windows (eg. as if the process is running only due to a |
252 // background application. | 252 // background application. |
253 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, | 253 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, |
254 StartupURLsOnNewWindowWithNoTabbedBrowsers) { | 254 StartupURLsOnNewWindowWithNoTabbedBrowsers) { |
255 // Use a couple same-site HTTP URLs. | 255 // Use a couple same-site HTTP URLs. |
256 ASSERT_TRUE(test_server()->Start()); | 256 ASSERT_TRUE(embedded_test_server()->Start()); |
257 std::vector<GURL> urls; | 257 std::vector<GURL> urls; |
258 urls.push_back(test_server()->GetURL("files/title1.html")); | 258 urls.push_back(embedded_test_server()->GetURL("/title1.html")); |
259 urls.push_back(test_server()->GetURL("files/title2.html")); | 259 urls.push_back(embedded_test_server()->GetURL("/title2.html")); |
260 | 260 |
261 Profile* profile = browser()->profile(); | 261 Profile* profile = browser()->profile(); |
262 chrome::HostDesktopType host_desktop_type = browser()->host_desktop_type(); | 262 chrome::HostDesktopType host_desktop_type = browser()->host_desktop_type(); |
263 | 263 |
264 // Set the startup preference to open these URLs. | 264 // Set the startup preference to open these URLs. |
265 SessionStartupPref pref(SessionStartupPref::URLS); | 265 SessionStartupPref pref(SessionStartupPref::URLS); |
266 pref.urls = urls; | 266 pref.urls = urls; |
267 SessionStartupPref::SetStartupPref(profile, pref); | 267 SessionStartupPref::SetStartupPref(profile, pref); |
268 | 268 |
269 // Keep the browser process running while browsers are closed. | 269 // Keep the browser process running while browsers are closed. |
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
520 EXPECT_FALSE(StartupBrowserCreator::WasRestarted()); | 520 EXPECT_FALSE(StartupBrowserCreator::WasRestarted()); |
521 } | 521 } |
522 | 522 |
523 // Fails on official builds. See http://crbug.com/313856 | 523 // Fails on official builds. See http://crbug.com/313856 |
524 #if defined(GOOGLE_CHROME_BUILD) | 524 #if defined(GOOGLE_CHROME_BUILD) |
525 #define MAYBE_AddFirstRunTab DISABLED_AddFirstRunTab | 525 #define MAYBE_AddFirstRunTab DISABLED_AddFirstRunTab |
526 #else | 526 #else |
527 #define MAYBE_AddFirstRunTab AddFirstRunTab | 527 #define MAYBE_AddFirstRunTab AddFirstRunTab |
528 #endif | 528 #endif |
529 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, MAYBE_AddFirstRunTab) { | 529 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, MAYBE_AddFirstRunTab) { |
| 530 ASSERT_TRUE(embedded_test_server()->Start()); |
530 StartupBrowserCreator browser_creator; | 531 StartupBrowserCreator browser_creator; |
531 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 532 browser_creator.AddFirstRunTab( |
532 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title2.html")); | 533 embedded_test_server()->GetURL("/title1.html")); |
| 534 browser_creator.AddFirstRunTab( |
| 535 embedded_test_server()->GetURL("/title2.html")); |
533 | 536 |
534 // Do a simple non-process-startup browser launch. | 537 // Do a simple non-process-startup browser launch. |
535 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 538 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
536 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 539 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
537 chrome::startup::IS_FIRST_RUN); | 540 chrome::startup::IS_FIRST_RUN); |
538 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), false, | 541 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), false, |
539 browser()->host_desktop_type())); | 542 browser()->host_desktop_type())); |
540 | 543 |
541 // This should have created a new browser window. | 544 // This should have created a new browser window. |
542 Browser* new_browser = FindOneOtherBrowser(browser()); | 545 Browser* new_browser = FindOneOtherBrowser(browser()); |
(...skipping 10 matching lines...) Expand all Loading... |
553 | 556 |
554 // Test hard-coded special first run tabs (defined in | 557 // Test hard-coded special first run tabs (defined in |
555 // StartupBrowserCreatorImpl::AddStartupURLs()). | 558 // StartupBrowserCreatorImpl::AddStartupURLs()). |
556 // Fails on official builds. See http://crbug.com/313856 | 559 // Fails on official builds. See http://crbug.com/313856 |
557 #if defined(GOOGLE_CHROME_BUILD) | 560 #if defined(GOOGLE_CHROME_BUILD) |
558 #define MAYBE_AddCustomFirstRunTab DISABLED_AddCustomFirstRunTab | 561 #define MAYBE_AddCustomFirstRunTab DISABLED_AddCustomFirstRunTab |
559 #else | 562 #else |
560 #define MAYBE_AddCustomFirstRunTab AddCustomFirstRunTab | 563 #define MAYBE_AddCustomFirstRunTab AddCustomFirstRunTab |
561 #endif | 564 #endif |
562 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, MAYBE_AddCustomFirstRunTab) { | 565 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, MAYBE_AddCustomFirstRunTab) { |
| 566 ASSERT_TRUE(embedded_test_server()->Start()); |
563 StartupBrowserCreator browser_creator; | 567 StartupBrowserCreator browser_creator; |
564 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 568 browser_creator.AddFirstRunTab( |
| 569 embedded_test_server()->GetURL("/title1.html")); |
565 browser_creator.AddFirstRunTab(GURL("http://new_tab_page")); | 570 browser_creator.AddFirstRunTab(GURL("http://new_tab_page")); |
566 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title2.html")); | 571 browser_creator.AddFirstRunTab( |
| 572 embedded_test_server()->GetURL("/title2.html")); |
567 browser_creator.AddFirstRunTab(GURL("http://welcome_page")); | 573 browser_creator.AddFirstRunTab(GURL("http://welcome_page")); |
568 | 574 |
569 // Do a simple non-process-startup browser launch. | 575 // Do a simple non-process-startup browser launch. |
570 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 576 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
571 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 577 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
572 chrome::startup::IS_FIRST_RUN); | 578 chrome::startup::IS_FIRST_RUN); |
573 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), false, | 579 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), false, |
574 browser()->host_desktop_type())); | 580 browser()->host_desktop_type())); |
575 | 581 |
576 // This should have created a new browser window. | 582 // This should have created a new browser window. |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
653 } else { | 659 } else { |
654 EXPECT_EQ(GURL(chrome::kChromeUINewTabURL), | 660 EXPECT_EQ(GURL(chrome::kChromeUINewTabURL), |
655 tab_strip->GetWebContentsAt(0)->GetURL()); | 661 tab_strip->GetWebContentsAt(0)->GetURL()); |
656 } | 662 } |
657 EXPECT_EQ(internals::GetWelcomePageURL(), | 663 EXPECT_EQ(internals::GetWelcomePageURL(), |
658 tab_strip->GetWebContentsAt(1)->GetURL()); | 664 tab_strip->GetWebContentsAt(1)->GetURL()); |
659 } | 665 } |
660 } | 666 } |
661 | 667 |
662 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, SyncPromoWithFirstRunTabs) { | 668 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, SyncPromoWithFirstRunTabs) { |
| 669 ASSERT_TRUE(embedded_test_server()->Start()); |
663 StartupBrowserCreator browser_creator; | 670 StartupBrowserCreator browser_creator; |
664 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 671 browser_creator.AddFirstRunTab( |
| 672 embedded_test_server()->GetURL("/title1.html")); |
665 | 673 |
666 // The welcome page should not be shown, even if | 674 // The welcome page should not be shown, even if |
667 // first_run::ShouldShowWelcomePage() says so, when there are already | 675 // first_run::ShouldShowWelcomePage() says so, when there are already |
668 // more than 2 first run tabs. | 676 // more than 2 first run tabs. |
669 first_run::SetShouldShowWelcomePage(); | 677 first_run::SetShouldShowWelcomePage(); |
670 | 678 |
671 // Do a simple non-process-startup browser launch. | 679 // Do a simple non-process-startup browser launch. |
672 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 680 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
673 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 681 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
674 chrome::startup::IS_FIRST_RUN); | 682 chrome::startup::IS_FIRST_RUN); |
(...skipping 15 matching lines...) Expand all Loading... |
690 EXPECT_EQ(1, tab_strip->count()); | 698 EXPECT_EQ(1, tab_strip->count()); |
691 EXPECT_EQ("title1.html", | 699 EXPECT_EQ("title1.html", |
692 tab_strip->GetWebContentsAt(0)->GetURL().ExtractFileName()); | 700 tab_strip->GetWebContentsAt(0)->GetURL().ExtractFileName()); |
693 } | 701 } |
694 } | 702 } |
695 | 703 |
696 // The welcome page should still be shown if there are more than 2 first run | 704 // The welcome page should still be shown if there are more than 2 first run |
697 // tabs, but the welcome page was explcitly added to the first run tabs. | 705 // tabs, but the welcome page was explcitly added to the first run tabs. |
698 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, | 706 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, |
699 SyncPromoWithFirstRunTabsIncludingWelcomePage) { | 707 SyncPromoWithFirstRunTabsIncludingWelcomePage) { |
| 708 ASSERT_TRUE(embedded_test_server()->Start()); |
700 StartupBrowserCreator browser_creator; | 709 StartupBrowserCreator browser_creator; |
701 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 710 browser_creator.AddFirstRunTab( |
| 711 embedded_test_server()->GetURL("/title1.html")); |
702 browser_creator.AddFirstRunTab(GURL("http://welcome_page")); | 712 browser_creator.AddFirstRunTab(GURL("http://welcome_page")); |
703 | 713 |
704 // Do a simple non-process-startup browser launch. | 714 // Do a simple non-process-startup browser launch. |
705 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 715 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
706 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 716 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
707 chrome::startup::IS_FIRST_RUN); | 717 chrome::startup::IS_FIRST_RUN); |
708 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), false, | 718 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), false, |
709 browser()->host_desktop_type())); | 719 browser()->host_desktop_type())); |
710 | 720 |
711 // This should have created a new browser window. | 721 // This should have created a new browser window. |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
808 ASSERT_TRUE(new_browser); | 818 ASSERT_TRUE(new_browser); |
809 tab_strip = new_browser->tab_strip_model(); | 819 tab_strip = new_browser->tab_strip_model(); |
810 ASSERT_EQ(1, tab_strip->count()); | 820 ASSERT_EQ(1, tab_strip->count()); |
811 EXPECT_EQ(urls2[0], tab_strip->GetWebContentsAt(0)->GetURL()); | 821 EXPECT_EQ(urls2[0], tab_strip->GetWebContentsAt(0)->GetURL()); |
812 } | 822 } |
813 | 823 |
814 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, PRE_UpdateWithTwoProfiles) { | 824 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, PRE_UpdateWithTwoProfiles) { |
815 // Simulate a browser restart by creating the profiles in the PRE_ part. | 825 // Simulate a browser restart by creating the profiles in the PRE_ part. |
816 ProfileManager* profile_manager = g_browser_process->profile_manager(); | 826 ProfileManager* profile_manager = g_browser_process->profile_manager(); |
817 | 827 |
818 ASSERT_TRUE(test_server()->Start()); | 828 ASSERT_TRUE(embedded_test_server()->Start()); |
819 | 829 |
820 // Create two profiles. | 830 // Create two profiles. |
821 base::FilePath dest_path = profile_manager->user_data_dir(); | 831 base::FilePath dest_path = profile_manager->user_data_dir(); |
822 | 832 |
823 Profile* profile1 = profile_manager->GetProfile( | 833 Profile* profile1 = profile_manager->GetProfile( |
824 dest_path.Append(FILE_PATH_LITERAL("New Profile 1"))); | 834 dest_path.Append(FILE_PATH_LITERAL("New Profile 1"))); |
825 ASSERT_TRUE(profile1); | 835 ASSERT_TRUE(profile1); |
826 | 836 |
827 Profile* profile2 = profile_manager->GetProfile( | 837 Profile* profile2 = profile_manager->GetProfile( |
828 dest_path.Append(FILE_PATH_LITERAL("New Profile 2"))); | 838 dest_path.Append(FILE_PATH_LITERAL("New Profile 2"))); |
829 ASSERT_TRUE(profile2); | 839 ASSERT_TRUE(profile2); |
830 | 840 |
831 // Open some urls with the browsers, and close them. | 841 // Open some urls with the browsers, and close them. |
832 Browser* browser1 = new Browser( | 842 Browser* browser1 = new Browser( |
833 Browser::CreateParams(Browser::TYPE_TABBED, profile1, | 843 Browser::CreateParams(Browser::TYPE_TABBED, profile1, |
834 browser()->host_desktop_type())); | 844 browser()->host_desktop_type())); |
835 chrome::NewTab(browser1); | 845 chrome::NewTab(browser1); |
836 ui_test_utils::NavigateToURL(browser1, | 846 ui_test_utils::NavigateToURL(browser1, |
837 test_server()->GetURL("files/empty.html")); | 847 embedded_test_server()->GetURL("/empty.html")); |
838 CloseBrowserSynchronously(browser1); | 848 CloseBrowserSynchronously(browser1); |
839 | 849 |
840 Browser* browser2 = new Browser( | 850 Browser* browser2 = new Browser( |
841 Browser::CreateParams(Browser::TYPE_TABBED, profile2, | 851 Browser::CreateParams(Browser::TYPE_TABBED, profile2, |
842 browser()->host_desktop_type())); | 852 browser()->host_desktop_type())); |
843 chrome::NewTab(browser2); | 853 chrome::NewTab(browser2); |
844 ui_test_utils::NavigateToURL(browser2, | 854 ui_test_utils::NavigateToURL(browser2, |
845 test_server()->GetURL("files/form.html")); | 855 embedded_test_server()->GetURL("/form.html")); |
846 CloseBrowserSynchronously(browser2); | 856 CloseBrowserSynchronously(browser2); |
847 | 857 |
848 // Set different startup preferences for the 2 profiles. | 858 // Set different startup preferences for the 2 profiles. |
849 std::vector<GURL> urls1; | 859 std::vector<GURL> urls1; |
850 urls1.push_back(ui_test_utils::GetTestUrl( | 860 urls1.push_back(ui_test_utils::GetTestUrl( |
851 base::FilePath(base::FilePath::kCurrentDirectory), | 861 base::FilePath(base::FilePath::kCurrentDirectory), |
852 base::FilePath(FILE_PATH_LITERAL("title1.html")))); | 862 base::FilePath(FILE_PATH_LITERAL("title1.html")))); |
853 std::vector<GURL> urls2; | 863 std::vector<GURL> urls2; |
854 urls2.push_back(ui_test_utils::GetTestUrl( | 864 urls2.push_back(ui_test_utils::GetTestUrl( |
855 base::FilePath(base::FilePath::kCurrentDirectory), | 865 base::FilePath(base::FilePath::kCurrentDirectory), |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
914 EXPECT_TRUE(profile1->restored_last_session()); | 924 EXPECT_TRUE(profile1->restored_last_session()); |
915 EXPECT_TRUE(profile2->restored_last_session()); | 925 EXPECT_TRUE(profile2->restored_last_session()); |
916 | 926 |
917 Browser* new_browser = NULL; | 927 Browser* new_browser = NULL; |
918 ASSERT_EQ(1u, chrome::GetBrowserCount(profile1, | 928 ASSERT_EQ(1u, chrome::GetBrowserCount(profile1, |
919 browser()->host_desktop_type())); | 929 browser()->host_desktop_type())); |
920 new_browser = FindOneOtherBrowserForProfile(profile1, NULL); | 930 new_browser = FindOneOtherBrowserForProfile(profile1, NULL); |
921 ASSERT_TRUE(new_browser); | 931 ASSERT_TRUE(new_browser); |
922 TabStripModel* tab_strip = new_browser->tab_strip_model(); | 932 TabStripModel* tab_strip = new_browser->tab_strip_model(); |
923 ASSERT_EQ(1, tab_strip->count()); | 933 ASSERT_EQ(1, tab_strip->count()); |
924 EXPECT_EQ("/files/empty.html", | 934 EXPECT_EQ("/empty.html", tab_strip->GetWebContentsAt(0)->GetURL().path()); |
925 tab_strip->GetWebContentsAt(0)->GetURL().path()); | |
926 | 935 |
927 ASSERT_EQ(1u, chrome::GetBrowserCount(profile2, | 936 ASSERT_EQ(1u, chrome::GetBrowserCount(profile2, |
928 browser()->host_desktop_type())); | 937 browser()->host_desktop_type())); |
929 new_browser = FindOneOtherBrowserForProfile(profile2, NULL); | 938 new_browser = FindOneOtherBrowserForProfile(profile2, NULL); |
930 ASSERT_TRUE(new_browser); | 939 ASSERT_TRUE(new_browser); |
931 tab_strip = new_browser->tab_strip_model(); | 940 tab_strip = new_browser->tab_strip_model(); |
932 ASSERT_EQ(1, tab_strip->count()); | 941 ASSERT_EQ(1, tab_strip->count()); |
933 EXPECT_EQ("/files/form.html", | 942 EXPECT_EQ("/form.html", tab_strip->GetWebContentsAt(0)->GetURL().path()); |
934 tab_strip->GetWebContentsAt(0)->GetURL().path()); | |
935 } | 943 } |
936 | 944 |
937 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, | 945 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, |
938 ProfilesWithoutPagesNotLaunched) { | 946 ProfilesWithoutPagesNotLaunched) { |
939 #if defined(OS_WIN) && defined(USE_ASH) | 947 #if defined(OS_WIN) && defined(USE_ASH) |
940 // Disable this test in Metro+Ash for now (http://crbug.com/262796). | 948 // Disable this test in Metro+Ash for now (http://crbug.com/262796). |
941 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 949 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
942 switches::kAshBrowserTests)) | 950 switches::kAshBrowserTests)) |
943 return; | 951 return; |
944 #endif | 952 #endif |
| 953 embedded_test_server()->Start(); |
945 | 954 |
946 Profile* default_profile = browser()->profile(); | 955 Profile* default_profile = browser()->profile(); |
947 | 956 |
948 ProfileManager* profile_manager = g_browser_process->profile_manager(); | 957 ProfileManager* profile_manager = g_browser_process->profile_manager(); |
949 | 958 |
950 // Create 4 more profiles. | 959 // Create 4 more profiles. |
951 base::FilePath dest_path1 = profile_manager->user_data_dir().Append( | 960 base::FilePath dest_path1 = profile_manager->user_data_dir().Append( |
952 FILE_PATH_LITERAL("New Profile 1")); | 961 FILE_PATH_LITERAL("New Profile 1")); |
953 base::FilePath dest_path2 = profile_manager->user_data_dir().Append( | 962 base::FilePath dest_path2 = profile_manager->user_data_dir().Append( |
954 FILE_PATH_LITERAL("New Profile 2")); | 963 FILE_PATH_LITERAL("New Profile 2")); |
(...skipping 28 matching lines...) Expand all Loading... |
983 SessionStartupPref pref_urls(SessionStartupPref::URLS); | 992 SessionStartupPref pref_urls(SessionStartupPref::URLS); |
984 pref_urls.urls = urls; | 993 pref_urls.urls = urls; |
985 SessionStartupPref::SetStartupPref(profile_urls, pref_urls); | 994 SessionStartupPref::SetStartupPref(profile_urls, pref_urls); |
986 | 995 |
987 // Open a page with profile_last. | 996 // Open a page with profile_last. |
988 Browser* browser_last = new Browser( | 997 Browser* browser_last = new Browser( |
989 Browser::CreateParams(Browser::TYPE_TABBED, profile_last, | 998 Browser::CreateParams(Browser::TYPE_TABBED, profile_last, |
990 browser()->host_desktop_type())); | 999 browser()->host_desktop_type())); |
991 chrome::NewTab(browser_last); | 1000 chrome::NewTab(browser_last); |
992 ui_test_utils::NavigateToURL(browser_last, | 1001 ui_test_utils::NavigateToURL(browser_last, |
993 test_server()->GetURL("files/empty.html")); | 1002 embedded_test_server()->GetURL("/empty.html")); |
994 CloseBrowserAsynchronously(browser_last); | 1003 CloseBrowserAsynchronously(browser_last); |
995 | 1004 |
996 // Close the main browser. | 1005 // Close the main browser. |
997 chrome::HostDesktopType original_desktop_type = | 1006 chrome::HostDesktopType original_desktop_type = |
998 browser()->host_desktop_type(); | 1007 browser()->host_desktop_type(); |
999 CloseBrowserAsynchronously(browser()); | 1008 CloseBrowserAsynchronously(browser()); |
1000 | 1009 |
1001 // Do a simple non-process-startup browser launch. | 1010 // Do a simple non-process-startup browser launch. |
1002 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 1011 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
1003 | 1012 |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1046 tab_strip = new_browser->tab_strip_model(); | 1055 tab_strip = new_browser->tab_strip_model(); |
1047 ASSERT_EQ(1, tab_strip->count()); | 1056 ASSERT_EQ(1, tab_strip->count()); |
1048 EXPECT_EQ(urls[0], tab_strip->GetWebContentsAt(0)->GetURL()); | 1057 EXPECT_EQ(urls[0], tab_strip->GetWebContentsAt(0)->GetURL()); |
1049 | 1058 |
1050 // profile_last opened the last open pages. | 1059 // profile_last opened the last open pages. |
1051 ASSERT_EQ(1u, chrome::GetBrowserCount(profile_last, original_desktop_type)); | 1060 ASSERT_EQ(1u, chrome::GetBrowserCount(profile_last, original_desktop_type)); |
1052 new_browser = FindOneOtherBrowserForProfile(profile_last, NULL); | 1061 new_browser = FindOneOtherBrowserForProfile(profile_last, NULL); |
1053 ASSERT_TRUE(new_browser); | 1062 ASSERT_TRUE(new_browser); |
1054 tab_strip = new_browser->tab_strip_model(); | 1063 tab_strip = new_browser->tab_strip_model(); |
1055 ASSERT_EQ(1, tab_strip->count()); | 1064 ASSERT_EQ(1, tab_strip->count()); |
1056 EXPECT_EQ("/files/empty.html", | 1065 EXPECT_EQ("/empty.html", tab_strip->GetWebContentsAt(0)->GetURL().path()); |
1057 tab_strip->GetWebContentsAt(0)->GetURL().path()); | |
1058 | 1066 |
1059 // profile_home2 was not launched since it would've only opened the home page. | 1067 // profile_home2 was not launched since it would've only opened the home page. |
1060 ASSERT_EQ(0u, chrome::GetBrowserCount(profile_home2, original_desktop_type)); | 1068 ASSERT_EQ(0u, chrome::GetBrowserCount(profile_home2, original_desktop_type)); |
1061 } | 1069 } |
1062 | 1070 |
1063 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, ProfilesLaunchedAfterCrash) { | 1071 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorTest, ProfilesLaunchedAfterCrash) { |
1064 #if defined(OS_WIN) && defined(USE_ASH) | 1072 #if defined(OS_WIN) && defined(USE_ASH) |
1065 // Disable this test in Metro+Ash for now (http://crbug.com/262796). | 1073 // Disable this test in Metro+Ash for now (http://crbug.com/262796). |
1066 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 1074 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
1067 switches::kAshBrowserTests)) | 1075 switches::kAshBrowserTests)) |
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1410 #else | 1418 #else |
1411 #define MAYBE_FirstRunTabsPromoAllowed FirstRunTabsPromoAllowed | 1419 #define MAYBE_FirstRunTabsPromoAllowed FirstRunTabsPromoAllowed |
1412 #endif | 1420 #endif |
1413 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, | 1421 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, |
1414 MAYBE_FirstRunTabsPromoAllowed) { | 1422 MAYBE_FirstRunTabsPromoAllowed) { |
1415 if (!PlatformSupportsSyncPromo()) | 1423 if (!PlatformSupportsSyncPromo()) |
1416 return; | 1424 return; |
1417 // Simulate the following master_preferences: | 1425 // Simulate the following master_preferences: |
1418 // { | 1426 // { |
1419 // "first_run_tabs" : [ | 1427 // "first_run_tabs" : [ |
1420 // "files/title1.html" | 1428 // "/title1.html" |
1421 // ], | 1429 // ], |
1422 // "sync_promo": { | 1430 // "sync_promo": { |
1423 // "show_on_first_run_allowed": true | 1431 // "show_on_first_run_allowed": true |
1424 // } | 1432 // } |
1425 // } | 1433 // } |
| 1434 ASSERT_TRUE(embedded_test_server()->Start()); |
1426 StartupBrowserCreator browser_creator; | 1435 StartupBrowserCreator browser_creator; |
1427 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 1436 browser_creator.AddFirstRunTab( |
| 1437 embedded_test_server()->GetURL("/title1.html")); |
1428 browser()->profile()->GetPrefs()->SetBoolean( | 1438 browser()->profile()->GetPrefs()->SetBoolean( |
1429 prefs::kSignInPromoShowOnFirstRunAllowed, true); | 1439 prefs::kSignInPromoShowOnFirstRunAllowed, true); |
1430 | 1440 |
1431 // Do a process-startup browser launch. | 1441 // Do a process-startup browser launch. |
1432 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 1442 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
1433 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 1443 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
1434 chrome::startup::IS_FIRST_RUN); | 1444 chrome::startup::IS_FIRST_RUN); |
1435 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, | 1445 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, |
1436 browser()->host_desktop_type())); | 1446 browser()->host_desktop_type())); |
1437 | 1447 |
(...skipping 17 matching lines...) Expand all Loading... |
1455 #else | 1465 #else |
1456 #define MAYBE_FirstRunTabsContainSyncPromo FirstRunTabsContainSyncPromo | 1466 #define MAYBE_FirstRunTabsContainSyncPromo FirstRunTabsContainSyncPromo |
1457 #endif | 1467 #endif |
1458 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, | 1468 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, |
1459 MAYBE_FirstRunTabsContainSyncPromo) { | 1469 MAYBE_FirstRunTabsContainSyncPromo) { |
1460 if (!PlatformSupportsSyncPromo()) | 1470 if (!PlatformSupportsSyncPromo()) |
1461 return; | 1471 return; |
1462 // Simulate the following master_preferences: | 1472 // Simulate the following master_preferences: |
1463 // { | 1473 // { |
1464 // "first_run_tabs" : [ | 1474 // "first_run_tabs" : [ |
1465 // "files/title1.html", | 1475 // "/title1.html", |
1466 // "chrome://signin/?source=0&next_page=chrome%3A%2F%2Fnewtab%2F" | 1476 // "chrome://signin/?source=0&next_page=chrome%3A%2F%2Fnewtab%2F" |
1467 // ], | 1477 // ], |
1468 // "sync_promo": { | 1478 // "sync_promo": { |
1469 // "show_on_first_run_allowed": true | 1479 // "show_on_first_run_allowed": true |
1470 // } | 1480 // } |
1471 // } | 1481 // } |
1472 ASSERT_TRUE(test_server()->Start()); | 1482 ASSERT_TRUE(embedded_test_server()->Start()); |
1473 StartupBrowserCreator browser_creator; | 1483 StartupBrowserCreator browser_creator; |
1474 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 1484 browser_creator.AddFirstRunTab( |
| 1485 embedded_test_server()->GetURL("/title1.html")); |
1475 browser_creator.AddFirstRunTab( | 1486 browser_creator.AddFirstRunTab( |
1476 signin::GetPromoURL(signin_metrics::SOURCE_START_PAGE, false)); | 1487 signin::GetPromoURL(signin_metrics::SOURCE_START_PAGE, false)); |
1477 browser()->profile()->GetPrefs()->SetBoolean( | 1488 browser()->profile()->GetPrefs()->SetBoolean( |
1478 prefs::kSignInPromoShowOnFirstRunAllowed, true); | 1489 prefs::kSignInPromoShowOnFirstRunAllowed, true); |
1479 | 1490 |
1480 // Do a process-startup browser launch. | 1491 // Do a process-startup browser launch. |
1481 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 1492 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
1482 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 1493 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
1483 chrome::startup::IS_FIRST_RUN); | 1494 chrome::startup::IS_FIRST_RUN); |
1484 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, | 1495 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, |
(...skipping 22 matching lines...) Expand all Loading... |
1507 FirstRunTabsContainNTPSyncPromoAllowed | 1518 FirstRunTabsContainNTPSyncPromoAllowed |
1508 #endif | 1519 #endif |
1509 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, | 1520 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, |
1510 MAYBE_FirstRunTabsContainNTPSyncPromoAllowed) { | 1521 MAYBE_FirstRunTabsContainNTPSyncPromoAllowed) { |
1511 if (!PlatformSupportsSyncPromo()) | 1522 if (!PlatformSupportsSyncPromo()) |
1512 return; | 1523 return; |
1513 // Simulate the following master_preferences: | 1524 // Simulate the following master_preferences: |
1514 // { | 1525 // { |
1515 // "first_run_tabs" : [ | 1526 // "first_run_tabs" : [ |
1516 // "new_tab_page", | 1527 // "new_tab_page", |
1517 // "files/title1.html" | 1528 // "/title1.html" |
1518 // ], | 1529 // ], |
1519 // "sync_promo": { | 1530 // "sync_promo": { |
1520 // "show_on_first_run_allowed": true | 1531 // "show_on_first_run_allowed": true |
1521 // } | 1532 // } |
1522 // } | 1533 // } |
| 1534 ASSERT_TRUE(embedded_test_server()->Start()); |
1523 StartupBrowserCreator browser_creator; | 1535 StartupBrowserCreator browser_creator; |
1524 browser_creator.AddFirstRunTab(GURL("http://new_tab_page")); | 1536 browser_creator.AddFirstRunTab(GURL("http://new_tab_page")); |
1525 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 1537 browser_creator.AddFirstRunTab( |
| 1538 embedded_test_server()->GetURL("/title1.html")); |
1526 browser()->profile()->GetPrefs()->SetBoolean( | 1539 browser()->profile()->GetPrefs()->SetBoolean( |
1527 prefs::kSignInPromoShowOnFirstRunAllowed, true); | 1540 prefs::kSignInPromoShowOnFirstRunAllowed, true); |
1528 | 1541 |
1529 // Do a process-startup browser launch. | 1542 // Do a process-startup browser launch. |
1530 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 1543 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
1531 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 1544 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
1532 chrome::startup::IS_FIRST_RUN); | 1545 chrome::startup::IS_FIRST_RUN); |
1533 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, | 1546 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, |
1534 browser()->host_desktop_type())); | 1547 browser()->host_desktop_type())); |
1535 | 1548 |
(...skipping 20 matching lines...) Expand all Loading... |
1556 FirstRunTabsContainNTPSyncPromoForbidden | 1569 FirstRunTabsContainNTPSyncPromoForbidden |
1557 #endif | 1570 #endif |
1558 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, | 1571 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, |
1559 MAYBE_FirstRunTabsContainNTPSyncPromoForbidden) { | 1572 MAYBE_FirstRunTabsContainNTPSyncPromoForbidden) { |
1560 if (!PlatformSupportsSyncPromo()) | 1573 if (!PlatformSupportsSyncPromo()) |
1561 return; | 1574 return; |
1562 // Simulate the following master_preferences: | 1575 // Simulate the following master_preferences: |
1563 // { | 1576 // { |
1564 // "first_run_tabs" : [ | 1577 // "first_run_tabs" : [ |
1565 // "new_tab_page", | 1578 // "new_tab_page", |
1566 // "files/title1.html" | 1579 // "/title1.html" |
1567 // ], | 1580 // ], |
1568 // "sync_promo": { | 1581 // "sync_promo": { |
1569 // "show_on_first_run_allowed": false | 1582 // "show_on_first_run_allowed": false |
1570 // } | 1583 // } |
1571 // } | 1584 // } |
| 1585 ASSERT_TRUE(embedded_test_server()->Start()); |
1572 StartupBrowserCreator browser_creator; | 1586 StartupBrowserCreator browser_creator; |
1573 browser_creator.AddFirstRunTab(GURL("http://new_tab_page")); | 1587 browser_creator.AddFirstRunTab(GURL("http://new_tab_page")); |
1574 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 1588 browser_creator.AddFirstRunTab( |
| 1589 embedded_test_server()->GetURL("/title1.html")); |
1575 browser()->profile()->GetPrefs()->SetBoolean( | 1590 browser()->profile()->GetPrefs()->SetBoolean( |
1576 prefs::kSignInPromoShowOnFirstRunAllowed, false); | 1591 prefs::kSignInPromoShowOnFirstRunAllowed, false); |
1577 | 1592 |
1578 // Do a process-startup browser launch. | 1593 // Do a process-startup browser launch. |
1579 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 1594 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
1580 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 1595 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
1581 chrome::startup::IS_FIRST_RUN); | 1596 chrome::startup::IS_FIRST_RUN); |
1582 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, | 1597 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, |
1583 browser()->host_desktop_type())); | 1598 browser()->host_desktop_type())); |
1584 | 1599 |
(...skipping 18 matching lines...) Expand all Loading... |
1603 #else | 1618 #else |
1604 #define MAYBE_FirstRunTabsSyncPromoForbidden FirstRunTabsSyncPromoForbidden | 1619 #define MAYBE_FirstRunTabsSyncPromoForbidden FirstRunTabsSyncPromoForbidden |
1605 #endif | 1620 #endif |
1606 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, | 1621 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, |
1607 MAYBE_FirstRunTabsSyncPromoForbidden) { | 1622 MAYBE_FirstRunTabsSyncPromoForbidden) { |
1608 if (!PlatformSupportsSyncPromo()) | 1623 if (!PlatformSupportsSyncPromo()) |
1609 return; | 1624 return; |
1610 // Simulate the following master_preferences: | 1625 // Simulate the following master_preferences: |
1611 // { | 1626 // { |
1612 // "first_run_tabs" : [ | 1627 // "first_run_tabs" : [ |
1613 // "files/title1.html" | 1628 // "/title1.html" |
1614 // ], | 1629 // ], |
1615 // "sync_promo": { | 1630 // "sync_promo": { |
1616 // "show_on_first_run_allowed": false | 1631 // "show_on_first_run_allowed": false |
1617 // } | 1632 // } |
1618 // } | 1633 // } |
| 1634 ASSERT_TRUE(embedded_test_server()->Start()); |
1619 StartupBrowserCreator browser_creator; | 1635 StartupBrowserCreator browser_creator; |
1620 browser_creator.AddFirstRunTab(test_server()->GetURL("files/title1.html")); | 1636 browser_creator.AddFirstRunTab( |
| 1637 embedded_test_server()->GetURL("/title1.html")); |
1621 browser()->profile()->GetPrefs()->SetBoolean( | 1638 browser()->profile()->GetPrefs()->SetBoolean( |
1622 prefs::kSignInPromoShowOnFirstRunAllowed, false); | 1639 prefs::kSignInPromoShowOnFirstRunAllowed, false); |
1623 | 1640 |
1624 // Do a process-startup browser launch. | 1641 // Do a process-startup browser launch. |
1625 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 1642 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
1626 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 1643 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
1627 chrome::startup::IS_FIRST_RUN); | 1644 chrome::startup::IS_FIRST_RUN); |
1628 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, | 1645 ASSERT_TRUE(launch.Launch(browser()->profile(), std::vector<GURL>(), true, |
1629 browser()->host_desktop_type())); | 1646 browser()->host_desktop_type())); |
1630 | 1647 |
(...skipping 20 matching lines...) Expand all Loading... |
1651 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, | 1668 IN_PROC_BROWSER_TEST_F(StartupBrowserCreatorFirstRunTest, |
1652 MAYBE_RestoreOnStartupURLsPolicySpecified) { | 1669 MAYBE_RestoreOnStartupURLsPolicySpecified) { |
1653 if (!PlatformSupportsSyncPromo()) | 1670 if (!PlatformSupportsSyncPromo()) |
1654 return; | 1671 return; |
1655 // Simulate the following master_preferences: | 1672 // Simulate the following master_preferences: |
1656 // { | 1673 // { |
1657 // "sync_promo": { | 1674 // "sync_promo": { |
1658 // "show_on_first_run_allowed": true | 1675 // "show_on_first_run_allowed": true |
1659 // } | 1676 // } |
1660 // } | 1677 // } |
| 1678 ASSERT_TRUE(embedded_test_server()->Start()); |
1661 StartupBrowserCreator browser_creator; | 1679 StartupBrowserCreator browser_creator; |
1662 browser()->profile()->GetPrefs()->SetBoolean( | 1680 browser()->profile()->GetPrefs()->SetBoolean( |
1663 prefs::kSignInPromoShowOnFirstRunAllowed, true); | 1681 prefs::kSignInPromoShowOnFirstRunAllowed, true); |
1664 | 1682 |
1665 // Set the following user policies: | 1683 // Set the following user policies: |
1666 // * RestoreOnStartup = RestoreOnStartupIsURLs | 1684 // * RestoreOnStartup = RestoreOnStartupIsURLs |
1667 // * RestoreOnStartupURLs = [ "files/title1.html" ] | 1685 // * RestoreOnStartupURLs = [ "/title1.html" ] |
1668 policy_map_.Set( | 1686 policy_map_.Set( |
1669 policy::key::kRestoreOnStartup, | 1687 policy::key::kRestoreOnStartup, |
1670 policy::POLICY_LEVEL_MANDATORY, | 1688 policy::POLICY_LEVEL_MANDATORY, |
1671 policy::POLICY_SCOPE_USER, | 1689 policy::POLICY_SCOPE_USER, |
1672 policy::POLICY_SOURCE_CLOUD, | 1690 policy::POLICY_SOURCE_CLOUD, |
1673 new base::FundamentalValue(SessionStartupPref::kPrefValueURLs), | 1691 new base::FundamentalValue(SessionStartupPref::kPrefValueURLs), |
1674 NULL); | 1692 NULL); |
1675 base::ListValue startup_urls; | 1693 base::ListValue startup_urls; |
1676 startup_urls.Append( | 1694 startup_urls.Append(new base::StringValue( |
1677 new base::StringValue(test_server()->GetURL("files/title1.html").spec())); | 1695 embedded_test_server()->GetURL("/title1.html").spec())); |
1678 policy_map_.Set(policy::key::kRestoreOnStartupURLs, | 1696 policy_map_.Set(policy::key::kRestoreOnStartupURLs, |
1679 policy::POLICY_LEVEL_MANDATORY, policy::POLICY_SCOPE_USER, | 1697 policy::POLICY_LEVEL_MANDATORY, policy::POLICY_SCOPE_USER, |
1680 policy::POLICY_SOURCE_CLOUD, startup_urls.DeepCopy(), | 1698 policy::POLICY_SOURCE_CLOUD, startup_urls.DeepCopy(), |
1681 nullptr); | 1699 nullptr); |
1682 provider_.UpdateChromePolicy(policy_map_); | 1700 provider_.UpdateChromePolicy(policy_map_); |
1683 base::RunLoop().RunUntilIdle(); | 1701 base::RunLoop().RunUntilIdle(); |
1684 | 1702 |
1685 // Do a process-startup browser launch. | 1703 // Do a process-startup browser launch. |
1686 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); | 1704 base::CommandLine dummy(base::CommandLine::NO_PROGRAM); |
1687 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, | 1705 StartupBrowserCreatorImpl launch(base::FilePath(), dummy, &browser_creator, |
(...skipping 11 matching lines...) Expand all Loading... |
1699 ASSERT_EQ(1, tab_strip->count()); | 1717 ASSERT_EQ(1, tab_strip->count()); |
1700 EXPECT_EQ("title1.html", | 1718 EXPECT_EQ("title1.html", |
1701 tab_strip->GetWebContentsAt(0)->GetURL().ExtractFileName()); | 1719 tab_strip->GetWebContentsAt(0)->GetURL().ExtractFileName()); |
1702 } | 1720 } |
1703 #endif // defined(ENABLE_CONFIGURATION_POLICY) | 1721 #endif // defined(ENABLE_CONFIGURATION_POLICY) |
1704 | 1722 |
1705 #endif // !defined(OS_LINUX) || !defined(GOOGLE_CHROME_BUILD) || | 1723 #endif // !defined(OS_LINUX) || !defined(GOOGLE_CHROME_BUILD) || |
1706 // defined(ENABLE_CONFIGURATION_POLICY) | 1724 // defined(ENABLE_CONFIGURATION_POLICY) |
1707 | 1725 |
1708 #endif // !defined(OS_CHROMEOS) | 1726 #endif // !defined(OS_CHROMEOS) |
OLD | NEW |