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

Side by Side Diff: chrome/test/functional/prefs.py

Issue 15822005: Remove omnibox_search_hint.(cc,h). (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: sync+rebase Created 7 years, 6 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 unified diff | Download patch
« no previous file with comments | « chrome/common/pref_names.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 import logging 6 import logging
7 import os 7 import os
8 import shutil 8 import shutil
9 9
10 import pyauto_functional # Must be imported before pyauto 10 import pyauto_functional # Must be imported before pyauto
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 'triggerGeoWithCallback(arguments[arguments.length - 1]);') 172 'triggerGeoWithCallback(arguments[arguments.length - 1]);')
173 self.assertEqual( 173 self.assertEqual(
174 behavior, Behaviors.BLOCK, 174 behavior, Behaviors.BLOCK,
175 msg='Behavior is "%s" when it should be BLOCKED.' % behavior) 175 msg='Behavior is "%s" when it should be BLOCKED.' % behavior)
176 176
177 def testUnderTheHoodPref(self): 177 def testUnderTheHoodPref(self):
178 """Verify the security preferences for Under the Hood. 178 """Verify the security preferences for Under the Hood.
179 The setting is enabled by default.""" 179 The setting is enabled by default."""
180 pref_list = [pyauto.kNetworkPredictionEnabled, pyauto.kSafeBrowsingEnabled, 180 pref_list = [pyauto.kNetworkPredictionEnabled, pyauto.kSafeBrowsingEnabled,
181 pyauto.kAlternateErrorPagesEnabled, 181 pyauto.kAlternateErrorPagesEnabled,
182 pyauto.kSearchSuggestEnabled, pyauto.kShowOmniboxSearchHint] 182 pyauto.kSearchSuggestEnabled]
183 for pref in pref_list: 183 for pref in pref_list:
184 # Verify the default value 184 # Verify the default value
185 self.assertEqual(self.GetPrefsInfo().Prefs(pref), True) 185 self.assertEqual(self.GetPrefsInfo().Prefs(pref), True)
186 self.SetPrefs(pref, False) 186 self.SetPrefs(pref, False)
187 self.RestartBrowser(clear_profile=False) 187 self.RestartBrowser(clear_profile=False)
188 for pref in pref_list: 188 for pref in pref_list:
189 self.assertEqual(self.GetPrefsInfo().Prefs(pref), False) 189 self.assertEqual(self.GetPrefsInfo().Prefs(pref), False)
190 190
191 def testJavaScriptEnableDisable(self): 191 def testJavaScriptEnableDisable(self):
192 """Verify enabling disabling javascript prefs work """ 192 """Verify enabling disabling javascript prefs work """
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
341 self.assertTrue( 341 self.assertTrue(
342 self._driver.execute_script( 342 self._driver.execute_script(
343 'return doesQueryConformsToProtocol("%s", "%s")' 343 'return doesQueryConformsToProtocol("%s", "%s")'
344 % (asked_handler_dict['query_key'], 344 % (asked_handler_dict['query_key'],
345 asked_handler_dict['query_value'])), 345 asked_handler_dict['query_value'])),
346 msg='Protocol did not register correctly.') 346 msg='Protocol did not register correctly.')
347 347
348 348
349 if __name__ == '__main__': 349 if __name__ == '__main__':
350 pyauto_functional.Main() 350 pyauto_functional.Main()
OLDNEW
« no previous file with comments | « chrome/common/pref_names.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698