]> git.openstreetmap.org Git - osqa.git/blob - forum/skins/default/tests/users_page.py
resolves an issue with empty node bodies when unicode text is passed to Markdown
[osqa.git] / forum / skins / default / tests / users_page.py
1 from selenium import selenium
2 import unittest, time, re
3
4 class users_page(unittest.TestCase):
5     def setUp(self):
6         self.verificationErrors = []
7         self.selenium = selenium("localhost", 4444, "*chrome", "http://127.0.0.1:8000/")
8         self.selenium.start()
9     
10     def test_users_page(self):
11         sel = self.selenium
12         sel.open("/")
13         sel.click("nav_users")
14         sel.wait_for_page_to_load("30000")
15         try: self.failUnless(sel.is_text_present("Users"))
16         except AssertionError, e: self.verificationErrors.append(str(e))
17         sel.click("nav_users")
18         sel.wait_for_page_to_load("30000")
19         try: self.failUnless(sel.is_text_present("karma"))
20         except AssertionError, e: self.verificationErrors.append(str(e))
21         try: self.failUnless(sel.is_text_present("recent"))
22         except AssertionError, e: self.verificationErrors.append(str(e))
23         try: self.failUnless(sel.is_text_present("oldest"))
24         except AssertionError, e: self.verificationErrors.append(str(e))
25         try: self.failUnless(sel.is_text_present("by username"))
26         except AssertionError, e: self.verificationErrors.append(str(e))
27     
28     def tearDown(self):
29         self.selenium.stop()
30         self.assertEqual([], self.verificationErrors)
31
32 if __name__ == "__main__":
33     unittest.main()