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

Unified Diff: chrome/browser/chromeos/events/event_rewriter_unittest.cc

Issue 2459823002: [Sync] Rename syncable_prefs to sync_preferences. (Closed)
Patch Set: Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/events/event_rewriter_unittest.cc
diff --git a/chrome/browser/chromeos/events/event_rewriter_unittest.cc b/chrome/browser/chromeos/events/event_rewriter_unittest.cc
index cb51678a9152d734fd6762d6dcbb40fad88b2e58..f2750f364040a178cab7fa0bb1d3b04a7fdbbab4 100644
--- a/chrome/browser/chromeos/events/event_rewriter_unittest.cc
+++ b/chrome/browser/chromeos/events/event_rewriter_unittest.cc
@@ -22,7 +22,7 @@
#include "chrome/common/pref_names.h"
#include "chromeos/chromeos_switches.h"
#include "components/prefs/pref_member.h"
-#include "components/syncable_prefs/testing_pref_service_syncable.h"
+#include "components/sync_preferences/testing_pref_service_syncable.h"
#include "components/user_manager/fake_user_manager.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/aura/window.h"
@@ -159,7 +159,7 @@ class EventRewriterTest : public ash::test::AshTestBase {
TEST_F(EventRewriterTest, TestRewriteCommandToControl) {
// First, test with a PC keyboard.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
EventRewriter rewriter(NULL);
rewriter.KeyboardDeviceAddedForTesting(kKeyboardDeviceId, "PC Keyboard");
rewriter.set_last_keyboard_device_id_for_testing(kKeyboardDeviceId);
@@ -255,7 +255,7 @@ TEST_F(EventRewriterTest, TestRewriteCommandToControl) {
// For crbug.com/133896.
TEST_F(EventRewriterTest, TestRewriteCommandToControlWithControlRemapped) {
// Remap Control to Alt.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember control;
control.Init(prefs::kLanguageRemapControlKeyTo, &prefs);
@@ -307,7 +307,7 @@ TEST_F(EventRewriterTest, TestRewriteCommandToControlWithControlRemapped) {
}
void EventRewriterTest::TestRewriteNumPadKeys() {
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
EventRewriter rewriter(NULL);
rewriter.KeyboardDeviceAddedForTesting(kKeyboardDeviceId, "PC Keyboard");
rewriter.set_last_keyboard_device_id_for_testing(kKeyboardDeviceId);
@@ -496,7 +496,7 @@ TEST_F(EventRewriterTest, TestRewriteNumPadKeysWithDiamondKeyFlag) {
// Tests if the rewriter can handle a Command + Num Pad event.
void EventRewriterTest::TestRewriteNumPadKeysOnAppleKeyboard() {
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
EventRewriter rewriter(NULL);
rewriter.KeyboardDeviceAddedForTesting(kKeyboardDeviceId, "Apple Keyboard");
rewriter.set_last_keyboard_device_id_for_testing(kKeyboardDeviceId);
@@ -541,7 +541,7 @@ TEST_F(EventRewriterTest,
}
TEST_F(EventRewriterTest, TestRewriteModifiersNoRemap) {
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
EventRewriter rewriter(NULL);
rewriter.KeyboardDeviceAddedForTesting(kKeyboardDeviceId, "PC Keyboard");
rewriter.set_pref_service_for_testing(&prefs);
@@ -592,7 +592,7 @@ TEST_F(EventRewriterTest, TestRewriteModifiersNoRemap) {
}
TEST_F(EventRewriterTest, TestRewriteModifiersNoRemapMultipleKeys) {
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
EventRewriter rewriter(NULL);
rewriter.KeyboardDeviceAddedForTesting(kKeyboardDeviceId, "PC Keyboard");
rewriter.set_pref_service_for_testing(&prefs);
@@ -656,7 +656,7 @@ TEST_F(EventRewriterTest, TestRewriteModifiersNoRemapMultipleKeys) {
TEST_F(EventRewriterTest, TestRewriteModifiersDisableSome) {
// Disable Search, Control and Escape keys.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember search;
search.Init(prefs::kLanguageRemapSearchKeyTo, &prefs);
@@ -758,7 +758,7 @@ TEST_F(EventRewriterTest, TestRewriteModifiersDisableSome) {
TEST_F(EventRewriterTest, TestRewriteModifiersRemapToControl) {
// Remap Search to Control.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember search;
search.Init(prefs::kLanguageRemapSearchKeyTo, &prefs);
@@ -836,7 +836,7 @@ TEST_F(EventRewriterTest, TestRewriteModifiersRemapToControl) {
TEST_F(EventRewriterTest, TestRewriteModifiersRemapToEscape) {
// Remap Search to Escape.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember search;
search.Init(prefs::kLanguageRemapSearchKeyTo, &prefs);
@@ -861,7 +861,7 @@ TEST_F(EventRewriterTest, TestRewriteModifiersRemapToEscape) {
TEST_F(EventRewriterTest, TestRewriteModifiersRemapMany) {
// Remap Escape to Alt.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember escape;
escape.Init(prefs::kLanguageRemapEscapeKeyTo, &prefs);
@@ -1012,7 +1012,7 @@ TEST_F(EventRewriterTest, TestRewriteModifiersRemapMany) {
TEST_F(EventRewriterTest, TestRewriteModifiersRemapToCapsLock) {
// Remap Search to Caps Lock.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember search;
search.Init(prefs::kLanguageRemapSearchKeyTo, &prefs);
@@ -1102,7 +1102,7 @@ TEST_F(EventRewriterTest, TestRewriteModifiersRemapToCapsLock) {
}
TEST_F(EventRewriterTest, TestRewriteCapsLock) {
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
chromeos::input_method::FakeImeKeyboard ime_keyboard;
@@ -1123,7 +1123,7 @@ TEST_F(EventRewriterTest, TestRewriteCapsLock) {
}
TEST_F(EventRewriterTest, TestRewriteDiamondKey) {
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
chromeos::input_method::FakeImeKeyboard ime_keyboard;
@@ -1164,7 +1164,7 @@ TEST_F(EventRewriterTest, TestRewriteDiamondKeyWithFlag) {
base::CommandLine::ForCurrentProcess()->AppendSwitchASCII(
chromeos::switches::kHasChromeOSDiamondKey, "");
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
chromeos::input_method::FakeImeKeyboard ime_keyboard;
@@ -1316,7 +1316,7 @@ TEST_F(EventRewriterTest, TestRewriteDiamondKeyWithFlag) {
TEST_F(EventRewriterTest, TestRewriteCapsLockToControl) {
// Remap CapsLock to Control.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember control;
control.Init(prefs::kLanguageRemapCapsLockKeyTo, &prefs);
@@ -1359,7 +1359,7 @@ TEST_F(EventRewriterTest, TestRewriteCapsLockToControl) {
TEST_F(EventRewriterTest, TestRewriteCapsLockMod3InUse) {
// Remap CapsLock to Control.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember control;
control.Init(prefs::kLanguageRemapCapsLockKeyTo, &prefs);
@@ -1383,7 +1383,7 @@ TEST_F(EventRewriterTest, TestRewriteCapsLockMod3InUse) {
}
TEST_F(EventRewriterTest, TestRewriteExtendedKeys) {
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
EventRewriter rewriter(NULL);
rewriter.KeyboardDeviceAddedForTesting(kKeyboardDeviceId, "PC Keyboard");
@@ -1529,7 +1529,7 @@ TEST_F(EventRewriterTest, TestRewriteExtendedKeys) {
}
TEST_F(EventRewriterTest, TestRewriteFunctionKeys) {
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
EventRewriter rewriter(NULL);
rewriter.KeyboardDeviceAddedForTesting(kKeyboardDeviceId, "PC Keyboard");
@@ -1845,7 +1845,7 @@ TEST_F(EventRewriterTest, TestRewriteFunctionKeys) {
TEST_F(EventRewriterTest, TestRewriteExtendedKeysWithSearchRemapped) {
// Remap Search to Control.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember search;
search.Init(prefs::kLanguageRemapSearchKeyTo, &prefs);
@@ -1877,7 +1877,7 @@ TEST_F(EventRewriterTest, TestRewriteExtendedKeysWithSearchRemapped) {
TEST_F(EventRewriterTest, TestRewriteKeyEventSentByXSendEvent) {
// Remap Control to Alt.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember control;
control.Init(prefs::kLanguageRemapControlKeyTo, &prefs);
@@ -1919,7 +1919,7 @@ TEST_F(EventRewriterTest, TestRewriteKeyEventSentByXSendEvent) {
TEST_F(EventRewriterTest, TestRewriteNonNativeEvent) {
// Remap Control to Alt.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember control;
control.Init(prefs::kLanguageRemapControlKeyTo, &prefs);
@@ -2019,7 +2019,7 @@ class EventRewriterAshTest : public ash::test::AshTestBase {
}
protected:
- syncable_prefs::TestingPrefServiceSyncable* prefs() { return &prefs_; }
+ sync_preferences::TestingPrefServiceSyncable* prefs() { return &prefs_; }
void PopEvents(ScopedVector<ui::Event>* events) { buffer_.PopEvents(events); }
@@ -2053,7 +2053,7 @@ class EventRewriterAshTest : public ash::test::AshTestBase {
user_manager::FakeUserManager* fake_user_manager_; // Not owned.
chromeos::ScopedUserManagerEnabler user_manager_enabler_;
- syncable_prefs::TestingPrefServiceSyncable prefs_;
+ sync_preferences::TestingPrefServiceSyncable prefs_;
DISALLOW_COPY_AND_ASSIGN(EventRewriterAshTest);
};
@@ -2102,7 +2102,7 @@ TEST_F(EventRewriterTest, TestRewrittenModifierClick) {
ui::TouchFactory::GetInstance()->SetPointerDeviceForTest(device_list);
// Remap Control to Alt.
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
chromeos::Preferences::RegisterProfilePrefs(prefs.registry());
IntegerPrefMember control;
control.Init(prefs::kLanguageRemapControlKeyTo, &prefs);
@@ -2141,7 +2141,7 @@ TEST_F(EventRewriterTest, DontRewriteIfNotRewritten) {
device_list.push_back(11);
ui::TouchFactory::GetInstance()->SetPointerDeviceForTest(device_list);
#endif
- syncable_prefs::TestingPrefServiceSyncable prefs;
+ sync_preferences::TestingPrefServiceSyncable prefs;
EventRewriter rewriter(NULL);
rewriter.set_pref_service_for_testing(&prefs);
const int kLeftAndAltFlag = ui::EF_LEFT_MOUSE_BUTTON | ui::EF_ALT_DOWN;

Powered by Google App Engine
This is Rietveld 408576698