_tests/test_http_status.py
changeset 233 c97120328e9c
parent 232 ec1bb552ce55
child 234 c6b169e9fca0
     1.1 --- a/_tests/test_http_status.py	Mon May 05 10:04:09 2014 +0200
     1.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 @@ -1,28 +0,0 @@
     1.4 -from selenium import webdriver
     1.5 -from selenium.common.exceptions import NoSuchElementException
     1.6 -import time
     1.7 -import unittest
     1.8 -
     1.9 -from sayings import get_saying
    1.10 -
    1.11 -class HTTPStatusTest(unittest.TestCase):
    1.12 -    def checkURL(self, url):
    1.13 -        self.browser.get(url)
    1.14 -        try:
    1.15 -            h1 = self.browser.find_element_by_xpath("//h1")
    1.16 -            self.assertNotEqual(h1.text, "Page Not Found")
    1.17 -        except NoSuchElementException:
    1.18 -            pass
    1.19 -
    1.20 -
    1.21 -    def runTest(self):
    1.22 -        self.browser = webdriver.Firefox()
    1.23 -        path = "http://127.0.0.1:5014/"
    1.24 -        urls = ["", "index", "competition", "task", "submission", "coursematerial",
    1.25 -                "imprint", "privacy"]
    1.26 -        for url in urls:
    1.27 -            self.checkURL(path + url)
    1.28 -
    1.29 -
    1.30 -if __name__ == "__main__":
    1.31 -    unittest.main()
Impressum Datenschutzerklärung