OLD | NEW |
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 "base/run_loop.h" | 5 #include "base/run_loop.h" |
6 #include "chrome/browser/chromeos/cros/network_library.h" | 6 #include "chrome/browser/chromeos/cros/network_library.h" |
7 #include "chrome/browser/chromeos/login/merge_session_load_page.h" | 7 #include "chrome/browser/chromeos/login/merge_session_load_page.h" |
8 #include "chrome/browser/chromeos/login/user_manager.h" | 8 #include "chrome/browser/chromeos/login/user_manager.h" |
9 #include "chrome/browser/chromeos/settings/cros_settings.h" | 9 #include "chrome/browser/chromeos/settings/cros_settings.h" |
10 #include "chrome/browser/chromeos/settings/device_settings_service.h" | 10 #include "chrome/browser/chromeos/settings/device_settings_service.h" |
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
117 InterstitialPage* interstitial = GetMergeSessionLoadPage(); | 117 InterstitialPage* interstitial = GetMergeSessionLoadPage(); |
118 ASSERT_TRUE(interstitial); | 118 ASSERT_TRUE(interstitial); |
119 base::RunLoop().RunUntilIdle(); | 119 base::RunLoop().RunUntilIdle(); |
120 | 120 |
121 // Simulate merge session completion. | 121 // Simulate merge session completion. |
122 UserManager::Get()->SetMergeSessionState( | 122 UserManager::Get()->SetMergeSessionState( |
123 UserManager::MERGE_STATUS_DONE); | 123 UserManager::MERGE_STATUS_DONE); |
124 base::RunLoop().RunUntilIdle(); | 124 base::RunLoop().RunUntilIdle(); |
125 | 125 |
126 // The URL remains to be URL2. | 126 // The URL remains to be URL2. |
127 EXPECT_EQ(kURL2, web_contents()->GetURL().spec()); | 127 EXPECT_EQ(kURL2, web_contents()->GetVisibleURL().spec()); |
128 | 128 |
129 // Commit navigation and the interstitial page is gone. | 129 // Commit navigation and the interstitial page is gone. |
130 Navigate(kURL2, 2); | 130 Navigate(kURL2, 2); |
131 EXPECT_FALSE(GetMergeSessionLoadPage()); | 131 EXPECT_FALSE(GetMergeSessionLoadPage()); |
132 } | 132 } |
133 | 133 |
134 } // namespace chromeos | 134 } // namespace chromeos |
OLD | NEW |