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 "chrome/browser/chromeos/accessibility/accessibility_manager.h" | 5 #include "chrome/browser/chromeos/accessibility/accessibility_manager.h" |
6 | 6 |
7 #include "ash/accessibility_types.h" | 7 #include "ash/accessibility_types.h" |
8 #include "ash/magnifier/magnification_controller.h" | 8 #include "ash/magnifier/magnification_controller.h" |
9 #include "ash/shell.h" | 9 #include "ash/shell.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
153 | 153 |
154 void SetMonoAudioEnabled(bool enabled) { | 154 void SetMonoAudioEnabled(bool enabled) { |
155 return AccessibilityManager::Get()->EnableMonoAudio(enabled); | 155 return AccessibilityManager::Get()->EnableMonoAudio(enabled); |
156 } | 156 } |
157 | 157 |
158 bool IsMonoAudioEnabled() { | 158 bool IsMonoAudioEnabled() { |
159 return AccessibilityManager::Get()->IsMonoAudioEnabled(); | 159 return AccessibilityManager::Get()->IsMonoAudioEnabled(); |
160 } | 160 } |
161 | 161 |
162 Profile* GetProfile() { | 162 Profile* GetProfile() { |
163 Profile* profile = ProfileManager::GetActiveUserProfile(); | 163 // ProfileManager::GetActiveUserProfile() does not load user profile |
164 // implicitly any more. Use GetProfile() to do an explicit load. | |
165 Profile* profile = g_browser_process->profile_manager()->GetProfile( | |
emaxx
2017/06/06 12:11:23
This construction - loading the profile for the ac
xiyuan
2017/06/06 20:29:39
Explicit user profile loading should be banned in
| |
166 ProfileHelper::Get()->GetProfilePathByUserIdHash( | |
167 user_manager::UserManager::Get()->GetActiveUser()->username_hash())); | |
168 | |
164 DCHECK(profile); | 169 DCHECK(profile); |
165 return profile; | 170 return profile; |
166 } | 171 } |
167 | 172 |
168 PrefService* GetPrefs() { | 173 PrefService* GetPrefs() { |
169 return GetProfile()->GetPrefs(); | 174 return GetProfile()->GetPrefs(); |
170 } | 175 } |
171 | 176 |
177 // Simulates how UserSessionManager starts a user session by loading user | |
178 // profile and mark session as started. | |
179 void StartUserSession(const AccountId& account_id) { | |
180 g_browser_process->profile_manager()->GetProfile( | |
181 ProfileHelper::Get()->GetProfilePathByUserIdHash( | |
emaxx
2017/06/06 12:11:23
Is it really fine to pass UserEmail to this functi
xiyuan
2017/06/06 20:29:39
This is because the tests are using the email as h
| |
182 account_id.GetUserEmail())); | |
183 | |
184 session_manager::SessionManager::Get()->SessionStarted(); | |
185 } | |
186 | |
172 void SetLargeCursorEnabledPref(bool enabled) { | 187 void SetLargeCursorEnabledPref(bool enabled) { |
173 GetPrefs()->SetBoolean(prefs::kAccessibilityLargeCursorEnabled, enabled); | 188 GetPrefs()->SetBoolean(prefs::kAccessibilityLargeCursorEnabled, enabled); |
174 } | 189 } |
175 | 190 |
176 void SetHighContrastEnabledPref(bool enabled) { | 191 void SetHighContrastEnabledPref(bool enabled) { |
177 GetPrefs()->SetBoolean(prefs::kAccessibilityHighContrastEnabled, enabled); | 192 GetPrefs()->SetBoolean(prefs::kAccessibilityHighContrastEnabled, enabled); |
178 } | 193 } |
179 | 194 |
180 void SetSpokenFeedbackEnabledPref(bool enabled) { | 195 void SetSpokenFeedbackEnabledPref(bool enabled) { |
181 GetPrefs()->SetBoolean(prefs::kAccessibilitySpokenFeedbackEnabled, enabled); | 196 GetPrefs()->SetBoolean(prefs::kAccessibilitySpokenFeedbackEnabled, enabled); |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
232 return true; | 247 return true; |
233 } | 248 } |
234 return false; | 249 return false; |
235 } | 250 } |
236 | 251 |
237 bool IsBrailleImeCurrent() { | 252 bool IsBrailleImeCurrent() { |
238 InputMethodManager* imm = InputMethodManager::Get(); | 253 InputMethodManager* imm = InputMethodManager::Get(); |
239 return imm->GetActiveIMEState()->GetCurrentInputMethod().id() == | 254 return imm->GetActiveIMEState()->GetCurrentInputMethod().id() == |
240 extension_ime_util::kBrailleImeEngineId; | 255 extension_ime_util::kBrailleImeEngineId; |
241 } | 256 } |
257 | |
242 } // anonymous namespace | 258 } // anonymous namespace |
243 | 259 |
244 class AccessibilityManagerTest : public InProcessBrowserTest { | 260 class AccessibilityManagerTest : public InProcessBrowserTest { |
245 protected: | 261 protected: |
246 AccessibilityManagerTest() : default_autoclick_delay_(0) {} | 262 AccessibilityManagerTest() : default_autoclick_delay_(0) {} |
247 ~AccessibilityManagerTest() override {} | 263 ~AccessibilityManagerTest() override {} |
248 | 264 |
249 void SetUpCommandLine(base::CommandLine* command_line) override { | 265 void SetUpCommandLine(base::CommandLine* command_line) override { |
250 command_line->AppendSwitch(chromeos::switches::kLoginManager); | 266 command_line->AppendSwitch(chromeos::switches::kLoginManager); |
251 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, | 267 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
302 | 318 |
303 // Confirms that the features still disabled just after login. | 319 // Confirms that the features still disabled just after login. |
304 EXPECT_FALSE(IsLargeCursorEnabled()); | 320 EXPECT_FALSE(IsLargeCursorEnabled()); |
305 EXPECT_FALSE(IsSpokenFeedbackEnabled()); | 321 EXPECT_FALSE(IsSpokenFeedbackEnabled()); |
306 EXPECT_FALSE(IsHighContrastEnabled()); | 322 EXPECT_FALSE(IsHighContrastEnabled()); |
307 EXPECT_FALSE(IsAutoclickEnabled()); | 323 EXPECT_FALSE(IsAutoclickEnabled()); |
308 EXPECT_FALSE(IsVirtualKeyboardEnabled()); | 324 EXPECT_FALSE(IsVirtualKeyboardEnabled()); |
309 EXPECT_FALSE(IsMonoAudioEnabled()); | 325 EXPECT_FALSE(IsMonoAudioEnabled()); |
310 EXPECT_EQ(default_autoclick_delay(), GetAutoclickDelay()); | 326 EXPECT_EQ(default_autoclick_delay(), GetAutoclickDelay()); |
311 | 327 |
312 session_manager->SessionStarted(); | 328 StartUserSession(test_account_id_); |
313 | 329 |
314 // Confirms that the features are still disabled just after login. | 330 // Confirms that the features are still disabled just after login. |
315 EXPECT_FALSE(IsLargeCursorEnabled()); | 331 EXPECT_FALSE(IsLargeCursorEnabled()); |
316 EXPECT_FALSE(IsSpokenFeedbackEnabled()); | 332 EXPECT_FALSE(IsSpokenFeedbackEnabled()); |
317 EXPECT_FALSE(IsHighContrastEnabled()); | 333 EXPECT_FALSE(IsHighContrastEnabled()); |
318 EXPECT_FALSE(IsAutoclickEnabled()); | 334 EXPECT_FALSE(IsAutoclickEnabled()); |
319 EXPECT_FALSE(IsVirtualKeyboardEnabled()); | 335 EXPECT_FALSE(IsVirtualKeyboardEnabled()); |
320 EXPECT_FALSE(IsMonoAudioEnabled()); | 336 EXPECT_FALSE(IsMonoAudioEnabled()); |
321 EXPECT_EQ(default_autoclick_delay(), GetAutoclickDelay()); | 337 EXPECT_EQ(default_autoclick_delay(), GetAutoclickDelay()); |
322 | 338 |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
361 // Signal the accessibility manager that a braille display was connected. | 377 // Signal the accessibility manager that a braille display was connected. |
362 SetBrailleDisplayAvailability(true); | 378 SetBrailleDisplayAvailability(true); |
363 // Confirms that the spoken feedback is enabled. | 379 // Confirms that the spoken feedback is enabled. |
364 EXPECT_TRUE(IsSpokenFeedbackEnabled()); | 380 EXPECT_TRUE(IsSpokenFeedbackEnabled()); |
365 } | 381 } |
366 | 382 |
367 IN_PROC_BROWSER_TEST_F(AccessibilityManagerTest, TypePref) { | 383 IN_PROC_BROWSER_TEST_F(AccessibilityManagerTest, TypePref) { |
368 // Logs in. | 384 // Logs in. |
369 auto* session_manager = session_manager::SessionManager::Get(); | 385 auto* session_manager = session_manager::SessionManager::Get(); |
370 session_manager->CreateSession(test_account_id_, kTestUserName); | 386 session_manager->CreateSession(test_account_id_, kTestUserName); |
371 session_manager->SessionStarted(); | 387 StartUserSession(test_account_id_); |
372 | 388 |
373 // Confirms that the features are disabled just after login. | 389 // Confirms that the features are disabled just after login. |
374 EXPECT_FALSE(IsLargeCursorEnabled()); | 390 EXPECT_FALSE(IsLargeCursorEnabled()); |
375 EXPECT_FALSE(IsSpokenFeedbackEnabled()); | 391 EXPECT_FALSE(IsSpokenFeedbackEnabled()); |
376 EXPECT_FALSE(IsHighContrastEnabled()); | 392 EXPECT_FALSE(IsHighContrastEnabled()); |
377 EXPECT_FALSE(IsAutoclickEnabled()); | 393 EXPECT_FALSE(IsAutoclickEnabled()); |
378 EXPECT_EQ(default_autoclick_delay(), GetAutoclickDelay()); | 394 EXPECT_EQ(default_autoclick_delay(), GetAutoclickDelay()); |
379 EXPECT_FALSE(IsVirtualKeyboardEnabled()); | 395 EXPECT_FALSE(IsVirtualKeyboardEnabled()); |
380 EXPECT_FALSE(IsMonoAudioEnabled()); | 396 EXPECT_FALSE(IsMonoAudioEnabled()); |
381 | 397 |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
461 | 477 |
462 // Sets the pref to enable the on-screen keyboard before login. | 478 // Sets the pref to enable the on-screen keyboard before login. |
463 SetVirtualKeyboardEnabledPref(true); | 479 SetVirtualKeyboardEnabledPref(true); |
464 EXPECT_FALSE(IsVirtualKeyboardEnabled()); | 480 EXPECT_FALSE(IsVirtualKeyboardEnabled()); |
465 | 481 |
466 // Sets the pref to enable mono audio output before login. | 482 // Sets the pref to enable mono audio output before login. |
467 SetMonoAudioEnabledPref(true); | 483 SetMonoAudioEnabledPref(true); |
468 EXPECT_FALSE(IsMonoAudioEnabled()); | 484 EXPECT_FALSE(IsMonoAudioEnabled()); |
469 | 485 |
470 // Logs in. | 486 // Logs in. |
471 session_manager->SessionStarted(); | 487 StartUserSession(test_account_id_); |
472 | 488 |
473 // Confirms that features are enabled by restoring from pref just after login. | 489 // Confirms that features are enabled by restoring from pref just after login. |
474 EXPECT_TRUE(IsLargeCursorEnabled()); | 490 EXPECT_TRUE(IsLargeCursorEnabled()); |
475 EXPECT_TRUE(IsSpokenFeedbackEnabled()); | 491 EXPECT_TRUE(IsSpokenFeedbackEnabled()); |
476 EXPECT_TRUE(IsHighContrastEnabled()); | 492 EXPECT_TRUE(IsHighContrastEnabled()); |
477 EXPECT_TRUE(IsAutoclickEnabled()); | 493 EXPECT_TRUE(IsAutoclickEnabled()); |
478 EXPECT_EQ(kTestAutoclickDelayMs, GetAutoclickDelay()); | 494 EXPECT_EQ(kTestAutoclickDelayMs, GetAutoclickDelay()); |
479 EXPECT_TRUE(IsVirtualKeyboardEnabled()); | 495 EXPECT_TRUE(IsVirtualKeyboardEnabled()); |
480 EXPECT_TRUE(IsMonoAudioEnabled()); | 496 EXPECT_TRUE(IsMonoAudioEnabled()); |
481 } | 497 } |
482 | 498 |
483 IN_PROC_BROWSER_TEST_F(AccessibilityManagerTest, | 499 IN_PROC_BROWSER_TEST_F(AccessibilityManagerTest, |
484 ChangingTypeInvokesNotification) { | 500 ChangingTypeInvokesNotification) { |
485 MockAccessibilityObserver observer; | 501 MockAccessibilityObserver observer; |
486 | 502 |
487 // Logs in. | 503 // Logs in. |
488 auto* session_manager = session_manager::SessionManager::Get(); | 504 auto* session_manager = session_manager::SessionManager::Get(); |
489 session_manager->CreateSession(test_account_id_, kTestUserName); | 505 session_manager->CreateSession(test_account_id_, kTestUserName); |
490 session_manager->SessionStarted(); | 506 StartUserSession(test_account_id_); |
491 | 507 |
492 EXPECT_FALSE(observer.observed()); | 508 EXPECT_FALSE(observer.observed()); |
493 observer.reset(); | 509 observer.reset(); |
494 | 510 |
495 SetSpokenFeedbackEnabled(true); | 511 SetSpokenFeedbackEnabled(true); |
496 EXPECT_TRUE(observer.observed()); | 512 EXPECT_TRUE(observer.observed()); |
497 EXPECT_TRUE(observer.observed_enabled()); | 513 EXPECT_TRUE(observer.observed_enabled()); |
498 EXPECT_EQ(observer.observed_type(), | 514 EXPECT_EQ(observer.observed_type(), |
499 ACCESSIBILITY_TOGGLE_SPOKEN_FEEDBACK); | 515 ACCESSIBILITY_TOGGLE_SPOKEN_FEEDBACK); |
500 EXPECT_TRUE(IsSpokenFeedbackEnabled()); | 516 EXPECT_TRUE(IsSpokenFeedbackEnabled()); |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
556 EXPECT_FALSE(IsMonoAudioEnabled()); | 572 EXPECT_FALSE(IsMonoAudioEnabled()); |
557 } | 573 } |
558 | 574 |
559 IN_PROC_BROWSER_TEST_F(AccessibilityManagerTest, | 575 IN_PROC_BROWSER_TEST_F(AccessibilityManagerTest, |
560 ChangingTypePrefInvokesNotification) { | 576 ChangingTypePrefInvokesNotification) { |
561 MockAccessibilityObserver observer; | 577 MockAccessibilityObserver observer; |
562 | 578 |
563 // Logs in. | 579 // Logs in. |
564 auto* session_manager = session_manager::SessionManager::Get(); | 580 auto* session_manager = session_manager::SessionManager::Get(); |
565 session_manager->CreateSession(test_account_id_, kTestUserName); | 581 session_manager->CreateSession(test_account_id_, kTestUserName); |
566 session_manager->SessionStarted(); | 582 StartUserSession(test_account_id_); |
567 | 583 |
568 EXPECT_FALSE(observer.observed()); | 584 EXPECT_FALSE(observer.observed()); |
569 observer.reset(); | 585 observer.reset(); |
570 | 586 |
571 SetSpokenFeedbackEnabledPref(true); | 587 SetSpokenFeedbackEnabledPref(true); |
572 EXPECT_TRUE(observer.observed()); | 588 EXPECT_TRUE(observer.observed()); |
573 EXPECT_TRUE(observer.observed_enabled()); | 589 EXPECT_TRUE(observer.observed_enabled()); |
574 EXPECT_EQ(observer.observed_type(), | 590 EXPECT_EQ(observer.observed_type(), |
575 ACCESSIBILITY_TOGGLE_SPOKEN_FEEDBACK); | 591 ACCESSIBILITY_TOGGLE_SPOKEN_FEEDBACK); |
576 EXPECT_TRUE(IsSpokenFeedbackEnabled()); | 592 EXPECT_TRUE(IsSpokenFeedbackEnabled()); |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
677 session_manager->CreateSession(account_id, account_id.GetUserEmail()); | 693 session_manager->CreateSession(account_id, account_id.GetUserEmail()); |
678 | 694 |
679 // Confirms that the features are still enabled just after login. | 695 // Confirms that the features are still enabled just after login. |
680 EXPECT_TRUE(IsLargeCursorEnabled()); | 696 EXPECT_TRUE(IsLargeCursorEnabled()); |
681 EXPECT_TRUE(IsSpokenFeedbackEnabled()); | 697 EXPECT_TRUE(IsSpokenFeedbackEnabled()); |
682 EXPECT_TRUE(IsHighContrastEnabled()); | 698 EXPECT_TRUE(IsHighContrastEnabled()); |
683 EXPECT_TRUE(IsAutoclickEnabled()); | 699 EXPECT_TRUE(IsAutoclickEnabled()); |
684 EXPECT_EQ(kTestAutoclickDelayMs, GetAutoclickDelay()); | 700 EXPECT_EQ(kTestAutoclickDelayMs, GetAutoclickDelay()); |
685 EXPECT_TRUE(IsMonoAudioEnabled()); | 701 EXPECT_TRUE(IsMonoAudioEnabled()); |
686 | 702 |
687 session_manager->SessionStarted(); | 703 StartUserSession(account_id); |
688 | 704 |
689 // Confirms that the features keep enabled after session starts. | 705 // Confirms that the features keep enabled after session starts. |
690 EXPECT_TRUE(IsLargeCursorEnabled()); | 706 EXPECT_TRUE(IsLargeCursorEnabled()); |
691 EXPECT_TRUE(IsSpokenFeedbackEnabled()); | 707 EXPECT_TRUE(IsSpokenFeedbackEnabled()); |
692 EXPECT_TRUE(IsHighContrastEnabled()); | 708 EXPECT_TRUE(IsHighContrastEnabled()); |
693 EXPECT_TRUE(IsAutoclickEnabled()); | 709 EXPECT_TRUE(IsAutoclickEnabled()); |
694 EXPECT_EQ(kTestAutoclickDelayMs, GetAutoclickDelay()); | 710 EXPECT_EQ(kTestAutoclickDelayMs, GetAutoclickDelay()); |
695 EXPECT_TRUE(IsMonoAudioEnabled()); | 711 EXPECT_TRUE(IsMonoAudioEnabled()); |
696 | 712 |
697 // Confirms that the prefs have been copied to the user's profile. | 713 // Confirms that the prefs have been copied to the user's profile. |
698 EXPECT_TRUE(GetLargeCursorEnabledFromPref()); | 714 EXPECT_TRUE(GetLargeCursorEnabledFromPref()); |
699 EXPECT_TRUE(GetSpokenFeedbackEnabledFromPref()); | 715 EXPECT_TRUE(GetSpokenFeedbackEnabledFromPref()); |
700 EXPECT_TRUE(GetHighContrastEnabledFromPref()); | 716 EXPECT_TRUE(GetHighContrastEnabledFromPref()); |
701 EXPECT_TRUE(GetAutoclickEnabledFromPref()); | 717 EXPECT_TRUE(GetAutoclickEnabledFromPref()); |
702 EXPECT_EQ(kTestAutoclickDelayMs, GetAutoclickDelayFromPref()); | 718 EXPECT_EQ(kTestAutoclickDelayMs, GetAutoclickDelayFromPref()); |
703 EXPECT_TRUE(GetMonoAudioEnabledFromPref()); | 719 EXPECT_TRUE(GetMonoAudioEnabledFromPref()); |
704 } | 720 } |
705 | 721 |
706 IN_PROC_BROWSER_TEST_P(AccessibilityManagerUserTypeTest, BrailleWhenLoggedIn) { | 722 IN_PROC_BROWSER_TEST_P(AccessibilityManagerUserTypeTest, BrailleWhenLoggedIn) { |
707 // Logs in. | 723 // Logs in. |
708 const AccountId account_id = AccountId::FromUserEmail(GetParam()); | 724 const AccountId account_id = AccountId::FromUserEmail(GetParam()); |
709 auto* session_manager = session_manager::SessionManager::Get(); | 725 auto* session_manager = session_manager::SessionManager::Get(); |
710 session_manager->CreateSession(account_id, account_id.GetUserEmail()); | 726 session_manager->CreateSession(account_id, account_id.GetUserEmail()); |
711 session_manager->SessionStarted(); | 727 StartUserSession(account_id); |
712 // This object watches for IME preference changes and reflects those in | 728 // This object watches for IME preference changes and reflects those in |
713 // the IME framework state. | 729 // the IME framework state. |
714 chromeos::Preferences prefs; | 730 chromeos::Preferences prefs; |
715 prefs.InitUserPrefsForTesting( | 731 prefs.InitUserPrefsForTesting( |
716 PrefServiceSyncableFromProfile(GetProfile()), | 732 PrefServiceSyncableFromProfile(GetProfile()), |
717 user_manager::UserManager::Get()->GetActiveUser(), | 733 user_manager::UserManager::Get()->GetActiveUser(), |
718 UserSessionManager::GetInstance()->GetDefaultIMEState(GetProfile())); | 734 UserSessionManager::GetInstance()->GetDefaultIMEState(GetProfile())); |
719 | 735 |
720 // Make sure we start in the expected state. | 736 // Make sure we start in the expected state. |
721 EXPECT_FALSE(IsBrailleImeActive()); | 737 EXPECT_FALSE(IsBrailleImeActive()); |
(...skipping 25 matching lines...) Expand all Loading... | |
747 // the Braille IME. | 763 // the Braille IME. |
748 SetBrailleDisplayAvailability(true); | 764 SetBrailleDisplayAvailability(true); |
749 EXPECT_TRUE(IsSpokenFeedbackEnabled()); | 765 EXPECT_TRUE(IsSpokenFeedbackEnabled()); |
750 EXPECT_TRUE(IsBrailleImeActive()); | 766 EXPECT_TRUE(IsBrailleImeActive()); |
751 } | 767 } |
752 | 768 |
753 IN_PROC_BROWSER_TEST_F(AccessibilityManagerTest, AccessibilityMenuVisibility) { | 769 IN_PROC_BROWSER_TEST_F(AccessibilityManagerTest, AccessibilityMenuVisibility) { |
754 // Log in. | 770 // Log in. |
755 auto* session_manager = session_manager::SessionManager::Get(); | 771 auto* session_manager = session_manager::SessionManager::Get(); |
756 session_manager->CreateSession(test_account_id_, kTestUserName); | 772 session_manager->CreateSession(test_account_id_, kTestUserName); |
757 session_manager->SessionStarted(); | 773 StartUserSession(test_account_id_); |
758 | 774 |
759 // Confirms that the features are disabled. | 775 // Confirms that the features are disabled. |
760 EXPECT_FALSE(IsLargeCursorEnabled()); | 776 EXPECT_FALSE(IsLargeCursorEnabled()); |
761 EXPECT_FALSE(IsSpokenFeedbackEnabled()); | 777 EXPECT_FALSE(IsSpokenFeedbackEnabled()); |
762 EXPECT_FALSE(IsHighContrastEnabled()); | 778 EXPECT_FALSE(IsHighContrastEnabled()); |
763 EXPECT_FALSE(IsAutoclickEnabled()); | 779 EXPECT_FALSE(IsAutoclickEnabled()); |
764 EXPECT_FALSE(ShouldShowAccessibilityMenu()); | 780 EXPECT_FALSE(ShouldShowAccessibilityMenu()); |
765 EXPECT_FALSE(IsVirtualKeyboardEnabled()); | 781 EXPECT_FALSE(IsVirtualKeyboardEnabled()); |
766 EXPECT_FALSE(IsMonoAudioEnabled()); | 782 EXPECT_FALSE(IsMonoAudioEnabled()); |
767 | 783 |
(...skipping 28 matching lines...) Expand all Loading... | |
796 EXPECT_FALSE(ShouldShowAccessibilityMenu()); | 812 EXPECT_FALSE(ShouldShowAccessibilityMenu()); |
797 | 813 |
798 // Check mono audio output. | 814 // Check mono audio output. |
799 SetMonoAudioEnabled(true); | 815 SetMonoAudioEnabled(true); |
800 EXPECT_TRUE(ShouldShowAccessibilityMenu()); | 816 EXPECT_TRUE(ShouldShowAccessibilityMenu()); |
801 SetMonoAudioEnabled(false); | 817 SetMonoAudioEnabled(false); |
802 EXPECT_FALSE(ShouldShowAccessibilityMenu()); | 818 EXPECT_FALSE(ShouldShowAccessibilityMenu()); |
803 } | 819 } |
804 | 820 |
805 } // namespace chromeos | 821 } // namespace chromeos |
OLD | NEW |