summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authornirnimesh@chromium.org <nirnimesh@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-10 21:09:59 +0000
committernirnimesh@chromium.org <nirnimesh@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-10 21:09:59 +0000
commit910a33b1559cd06f43737c3af51c62a0aec44327 (patch)
treef7bb0b67e754c829886b2e92711ec92e25eca224 /chrome
parent183cf7bb84e90ae93966608ea764182d89103a6c (diff)
downloadchromium_src-910a33b1559cd06f43737c3af51c62a0aec44327.zip
chromium_src-910a33b1559cd06f43737c3af51c62a0aec44327.tar.gz
chromium_src-910a33b1559cd06f43737c3af51c62a0aec44327.tar.bz2
Two Testcases on verifying the content of pages.
TEST=None Bug=None 1. Verify content on https page - https://www.google.com. Verify in regular, incognito window 2. Verify that chrome works with some top websites. Browse a list of urls, each time verify some key strings. This test will verify that chrome is not getting blocked by user-agent test by those websites. Review URL: http://codereview.chromium.org/5726001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@68886 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/test/functional/content.py23
1 files changed, 23 insertions, 0 deletions
diff --git a/chrome/test/functional/content.py b/chrome/test/functional/content.py
index 8765cb8..f231050 100644
--- a/chrome/test/functional/content.py
+++ b/chrome/test/functional/content.py
@@ -87,6 +87,29 @@ class ContentTest(pyauto.PyUITest):
['User Agent', 'Command Line'],
['odmomfodfm disfnodugdzuoufgbn ifdnf fif'])
+ def testHttpsPage(self):
+ """Test content in https://www.google.com"""
+ url = 'https://www.google.com'
+ self.NavigateToURL(url)
+ html_regular = self.GetTabContents()
+ self.assertTrue('Google Search' in html_regular)
+ self.assertTrue('I&#39;m Feeling Lucky' in html_regular)
+ self.RunCommand(pyauto.IDC_NEW_INCOGNITO_WINDOW)
+ self.NavigateToURL(url, 1, 0)
+ html_incognito = self.GetTabContents(0, 1)
+ self.assertTrue('Google Search' in html_incognito)
+ self.assertTrue('I&#39;m Feeling Lucky' in html_incognito)
+
+ def testTopSitesContent(self):
+ """Test content in TopSites and Verify chrome is not getting blocked by
+ user-agent test by those websites."""
+ topsites_file = os.path.join(self.DataDir(), 'content', 'topsites_content')
+ topsites = self.EvalDataFrom(topsites_file)
+ for (url, name) in topsites.iteritems():
+ self.NavigateToURL(url)
+ html = self.GetTabContents()
+ self.assertTrue(name in html)
+
if __name__ == '__main__':
pyauto_functional.Main()