OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/basictypes.h" | 5 #include "base/basictypes.h" |
6 #include "base/compiler_specific.h" | 6 #include "base/compiler_specific.h" |
7 #include "base/prefs/pref_service.h" | 7 #include "base/prefs/pref_service.h" |
8 #include "base/strings/stringprintf.h" | 8 #include "base/strings/stringprintf.h" |
9 #include "chrome/browser/chromeos/login/login_manager_test.h" | 9 #include "chrome/browser/chromeos/login/login_manager_test.h" |
10 #include "chrome/browser/chromeos/login/startup_utils.h" | 10 #include "chrome/browser/chromeos/login/startup_utils.h" |
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
291 RegisterUser(kTestOwner); | 291 RegisterUser(kTestOwner); |
292 RegisterUser(kTestNonOwner); | 292 RegisterUser(kTestNonOwner); |
293 StartupUtils::MarkOobeCompleted(); | 293 StartupUtils::MarkOobeCompleted(); |
294 } | 294 } |
295 | 295 |
296 // Tests the shared setting indicator for the primary user's auto-lock setting | 296 // Tests the shared setting indicator for the primary user's auto-lock setting |
297 // when the secondary user has enabled or disabled their preference. | 297 // when the secondary user has enabled or disabled their preference. |
298 // (The checkbox is unset if the current user's preference is false, but if any | 298 // (The checkbox is unset if the current user's preference is false, but if any |
299 // other signed-in user has enabled this preference, the shared setting | 299 // other signed-in user has enabled this preference, the shared setting |
300 // indicator explains this.) | 300 // indicator explains this.) |
301 IN_PROC_BROWSER_TEST_F(SharedOptionsTest, ScreenLockPreferencePrimary) { | 301 // Disabled due to flaky timeouts. https://crbug.com/423053 |
| 302 IN_PROC_BROWSER_TEST_F(SharedOptionsTest, |
| 303 DISABLED_ScreenLockPreferencePrimary) { |
302 LoginUser(kTestOwner); | 304 LoginUser(kTestOwner); |
303 UserAddingScreen::Get()->Start(); | 305 UserAddingScreen::Get()->Start(); |
304 content::RunAllPendingInMessageLoop(); | 306 content::RunAllPendingInMessageLoop(); |
305 AddUser(kTestNonOwner); | 307 AddUser(kTestNonOwner); |
306 | 308 |
307 user_manager::UserManager* manager = user_manager::UserManager::Get(); | 309 user_manager::UserManager* manager = user_manager::UserManager::Get(); |
308 const user_manager::User* user1 = manager->FindUser(kTestOwner); | 310 const user_manager::User* user1 = manager->FindUser(kTestOwner); |
309 const user_manager::User* user2 = manager->FindUser(kTestNonOwner); | 311 const user_manager::User* user2 = manager->FindUser(kTestNonOwner); |
310 | 312 |
311 PrefService* prefs1 = | 313 PrefService* prefs1 = |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
424 content::WaitForLoadStop(contents); | 426 content::WaitForLoadStop(contents); |
425 { | 427 { |
426 SCOPED_TRACE("Screen lock false for both users"); | 428 SCOPED_TRACE("Screen lock false for both users"); |
427 expected_value = false; | 429 expected_value = false; |
428 CheckBooleanPreference(contents, prefs::kEnableAutoScreenLock, disabled, | 430 CheckBooleanPreference(contents, prefs::kEnableAutoScreenLock, disabled, |
429 empty_controlled, expected_value); | 431 empty_controlled, expected_value); |
430 } | 432 } |
431 } | 433 } |
432 | 434 |
433 } // namespace chromeos | 435 } // namespace chromeos |
OLD | NEW |