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

Unified Diff: functional/instant.py

Issue 6352003: Added one testcases to Instant. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/chrome/test/
Patch Set: '' Created 9 years, 11 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: functional/instant.py
===================================================================
--- functional/instant.py (revision 71508)
+++ functional/instant.py (working copy)
@@ -63,6 +63,27 @@
self.assertFalse(self.GetInstantInfo()['active'],
'Instant enabled for javascript URL.')
+ def testPornNavigation(self):
Nirnimesh 2011/01/15 00:14:34 Yeah baby!
+ """Test that instant does not navigate porn sites until
+ user presses Enter key."""
+ self.SetOmniboxText('porn')
+ self.assertTrue(self.WaitUntil(self._DoneLoading))
+ self.assertTrue(self.GetInstantInfo()['active'],
+ 'Press Enter to search')
Nirnimesh 2011/01/15 00:14:34 This error mesg is unclear
+ self.SetOmniboxText('xxx')
Nirnimesh 2011/01/15 00:14:34 Instead of repeating these 3 lines (which's basica
+ self.assertTrue(self.WaitUntil(self._DoneLoading))
+ self.assertTrue(self.GetInstantInfo()['active'],
+ 'Press Enter to search')
+
+ def testFindInCanDismissInstant(self):
+ """Test that instant previvew is dismissed by find-in-page."""
Nirnimesh 2011/01/15 00:14:34 s/previvew/preview/
+ self.SetOmniboxText('google.com')
+ self.assertTrue(self.WaitUntil(self._DoneLoading))
+ location = self.GetInstantInfo()['location']
+ self.assertTrue('google.com' in location,
+ msg='No google.com in %s' % location)
+ self.OpenFindInPage()
+ self.assertEqual(self.GetActiveTabTitle(), '')
if __name__ == '__main__':
pyauto_functional.Main()
« 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