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

Unified Diff: chrome/test/live_sync/two_client_live_preferences_sync_test.cc

Issue 6688045: Add tests for ChromeOS prefs: kAccessibilityEnabled, kEnableScreenLock and kTapToClickEnabled. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Automation for ChromeOS specific preferences. Created 9 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/live_sync/two_client_live_preferences_sync_test.cc
diff --git a/chrome/test/live_sync/two_client_live_preferences_sync_test.cc b/chrome/test/live_sync/two_client_live_preferences_sync_test.cc
index 3c5ec02985309216db2b08b61b988956ccac99e0..e6d1bdae9a1b0a0137fea280e17ff27fc46ae83f 100644
--- a/chrome/test/live_sync/two_client_live_preferences_sync_test.cc
+++ b/chrome/test/live_sync/two_client_live_preferences_sync_test.cc
@@ -727,6 +727,7 @@ IN_PROC_BROWSER_TEST_F(TwoClientLivePreferencesSyncTest,
ASSERT_FALSE(translate_client1_prefs.IsSiteBlacklisted(host));
}
+// TCM ID - 6515252.
IN_PROC_BROWSER_TEST_F(TwoClientLivePreferencesSyncTest,
kExtensionsUIDeveloperMode) {
ASSERT_TRUE(SetupSync()) << "SetupSync() failed.";
@@ -747,3 +748,104 @@ IN_PROC_BROWSER_TEST_F(TwoClientLivePreferencesSyncTest,
ASSERT_EQ(GetVerifierPrefs()->GetBoolean(prefs::kExtensionsUIDeveloperMode),
GetPrefs(1)->GetBoolean(prefs::kExtensionsUIDeveloperMode));
}
+
+// TCM ID - 6473347.
+#if defined(OS_CHROMEOS)
+IN_PROC_BROWSER_TEST_F(TwoClientLivePreferencesSyncTest,
+ kTapToClickEnabled) {
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
anna 2011/03/21 21:19:40 We do not have strict indentation style rules on t
anna 2011/03/21 21:19:40 Done.
+ ASSERT_TRUE(SetupSync()) << "SetupSync() failed.";
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kTapToClickEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kTapToClickEnabled));
+
+ bool new_kAccessibilityEnabled = !GetPrefs0()->
Raghu Simha 2011/03/21 19:32:47 Wrong variable name here. This won't compile on Ch
anna 2011/03/21 21:19:40 Done.
+ GetBoolean(prefs::kTapToClickEnabled);
+ GetVerifierPrefs()->SetBoolean(prefs::kTapToClickEnabled,
+ new_kTapToClickEnabled);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ GetPrefs(0)->SetBoolean(prefs::kTapToClickEnabled,
+ new_kTapToClickEnabled);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ ASSERT_TRUE(GetClient(0)->AwaitMutualSyncCycleCompletion(GetClient(1)));
+
+ ASSERT_EQ(GetVerifierPrefs()->GetBoolean(prefs::kTapToClickEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kTapToClickEnabled ));
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kTapToClickEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kTapToClickEnabled));
+
+ GetVerifierPrefs()->SetBoolean(prefs::kTapToClickEnabled,
+ !new_kTapToClickEnabledd);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ GetPrefs(0)->SetBoolean(prefs::kTapToClickEnabled,
+ !new_kTapToClickEnabled);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ ASSERT_TRUE(GetClient(0)->AwaitMutualSyncCycleCompletion(GetClient(1)));
+
+ ASSERT_EQ(GetVerifierPrefs()->GetBoolean(prefs::kTapToClickEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kTapToClickEnabled ));
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kTapToClickEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kTapToClickEnabled));
+}
+#endif // OS_CHROMEOS
+
+// TCM ID - 6461774.
+#if defined(OS_CHROMEOS)
+IN_PROC_BROWSER_TEST_F(TwoClientLivePreferencesSyncTest,
+ kAccessibilityEnabled) {
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ ASSERT_TRUE(SetupSync()) << "SetupSync() failed.";
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kAccessibilityEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kAccessibilityEnabled));
+
+ bool new_kAccessibilityEnabled = !GetPrefs0()->
+ GetBoolean(prefs::kAccessibilityEnabled);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ GetVerifierPrefs()->SetBoolean(prefs::kAccessibilityEnabled,
+ new_kAccessibilityEnabled);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ GetPrefs(0)->SetBoolean(prefs::kAccessibilityEnabled,
+ new_kAccessibilityEnabled);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ ASSERT_TRUE(GetClient(0)->AwaitMutualSyncCycleCompletion(GetClient(1)));
+
+ ASSERT_EQ(GetVerifierPrefs()->GetBoolean(prefs::kAccessibilityEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kAccessibilityEnabled ));
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kAccessibilityEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kAccessibilityEnabled));
+
+ GetVerifierPrefs()->SetBoolean(prefs::kAccessibilityEnabled,
+ !new_kAccessibilityEnabled);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ GetPrefs(0)->SetBoolean(prefs::kAccessibilityEnabled,
+ !new_kAccessibilityEnabled);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ ASSERT_TRUE(GetClient(0)->AwaitMutualSyncCycleCompletion(GetClient(1)));
+
+ ASSERT_EQ(GetVerifierPrefs()->GetBoolean(prefs::kAccessibilityEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kAccessibilityEnabled ));
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kAccessibilityEnabled),
+ GetPrefs(1)->GetBoolean(prefs::kAccessibilityEnabled));
+}
+#endif // OS_CHROMEOS
+
+// TCM ID - 6458824.
+#if defined(OS_CHROMEOS)
+IN_PROC_BROWSER_TEST_F(TwoClientLivePreferencesSyncTest,
+ kEnableScreenLock) {
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ ASSERT_TRUE(SetupSync()) << "SetupSync() failed.";
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kEnableScreenLock),
+ GetPrefs(1)->GetBoolean(prefs::kEnableScreenLock));
+
+ bool new_kAccessibilityEnabled = !GetPrefs0()->
Raghu Simha 2011/03/21 19:32:47 Wrong variable name here. This won't compile on Ch
anna 2011/03/21 21:19:40 Done.
+ GetBoolean(prefs::kEnableScreenLock);
+ GetVerifierPrefs()->SetBoolean(prefs::kEnableScreenLock,
+ new_kEnableScreenLock);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ GetPrefs(0)->SetBoolean(prefs::kEnableScreenLock, new_kEnableScreenLock);
+ ASSERT_TRUE(GetClient(0)->AwaitMutualSyncCycleCompletion(GetClient(1)));
+
+ ASSERT_EQ(GetVerifierPrefs()->GetBoolean(prefs::kEnableScreenLock),
+ GetPrefs(1)->GetBoolean(prefs::kEnableScreenLock ));
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kEnableScreenLock),
+ GetPrefs(1)->GetBoolean(prefs::kEnableScreenLock));
+
+ GetVerifierPrefs()->SetBoolean(prefs::kEnableScreenLock,
+ !new_kEnableScreenLock);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ GetPrefs(0)->SetBoolean(prefs::kEnableScreenLock,
+ !new_kEnableScreenLock);
Raghu Simha 2011/03/21 19:32:47 nit: Adjust indentation to align with the line abo
anna 2011/03/21 21:19:40 Done.
+ ASSERT_TRUE(GetClient(0)->AwaitMutualSyncCycleCompletion(GetClient(1)));
+
+ ASSERT_EQ(GetVerifierPrefs()->GetBoolean(prefs::kEnableScreenLock),
+ GetPrefs(1)->GetBoolean(prefs::kEnableScreenLock ));
+ ASSERT_EQ(GetPrefs(0)->GetBoolean(prefs::kEnableScreenLock),
+ GetPrefs(1)->GetBoolean(prefs::kEnableScreenLock));
+}
+#endif // OS_CHROMEOS
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698