Exemplo n.º 1
0
 def test_video_srcs_are_valid(self, base_url, selenium):
     page = Mission(base_url, selenium).open()
     bad_srcs = []
     for src in page.video_sources_list:
         response_code = page.get_response_code(src)
         if response_code != requests.codes.ok:
             bad_srcs.append('%s is not a valid url - status code: %s.' % (src, response_code))
     assert [] == bad_srcs
Exemplo n.º 2
0
 def test_video_srcs_are_valid(self, mozwebqa):
     mission_page = Mission(mozwebqa)
     mission_page.go_to_page()
     bad_srcs = []
     for src in mission_page.video_sources_list:
         response_code = mission_page.get_response_code(src)
         if response_code != requests.codes.ok:
             bad_srcs.append('%s is not a valid url - status code: %s.' % (src, response_code))
     Assert.equal(0, len(bad_srcs), '%s bad urls found: ' % len(bad_srcs) + ', '.join(bad_srcs))
Exemplo n.º 3
0
 def test_video_srcs_are_valid(self, mozwebqa):
     mission_page = Mission(mozwebqa)
     mission_page.go_to_page()
     bad_srcs = []
     for src in mission_page.video_sources_list:
         response_code = mission_page.get_response_code(src)
         if response_code != requests.codes.ok:
             bad_srcs.append('%s is not a valid url - status code: %s.' % (src, response_code))
     assert [] == bad_srcs
Exemplo n.º 4
0
 def test_major_link_urls_are_valid(self, base_url, selenium):
     page = Mission(base_url, selenium).open()
     bad_urls = []
     for link in page.major_links_list:
         url = page.link_destination(link.get('locator'))
         response_code = page.get_response_code(url)
         if response_code != requests.codes.ok:
             bad_urls.append('%s is not a valid url - status code: %s.' % (url, response_code))
     assert [] == bad_urls
Exemplo n.º 5
0
 def test_video_srcs_are_valid(self, base_url, selenium):
     page = Mission(base_url, selenium).open()
     bad_srcs = []
     for src in page.video_sources_list:
         response_code = page.get_response_code(src)
         if response_code != requests.codes.ok:
             bad_srcs.append('%s is not a valid url - status code: %s.' %
                             (src, response_code))
     assert [] == bad_srcs
Exemplo n.º 6
0
 def test_major_link_urls_are_valid(self, mozwebqa):
     mission_page = Mission(mozwebqa)
     mission_page.go_to_page()
     bad_urls = []
     for link in mission_page.major_links_list:
         url = mission_page.link_destination(link.get('locator'))
         response_code = mission_page.get_response_code(url)
         if response_code != requests.codes.ok:
             bad_urls.append('%s is not a valid url - status code: %s.' % (url, response_code))
     Assert.equal(0, len(bad_urls), '%s bad urls found: ' % len(bad_urls) + ', '.join(bad_urls))
Exemplo n.º 7
0
 def test_major_link_urls_are_valid(self, mozwebqa):
     mission_page = Mission(mozwebqa)
     mission_page.go_to_page()
     bad_urls = []
     for link in mission_page.major_links_list:
         url = mission_page.link_destination(link.get('locator'))
         response_code = mission_page.get_response_code(url)
         if response_code != requests.codes.ok:
             bad_urls.append('%s is not a valid url - status code: %s.' % (url, response_code))
     assert [] == bad_urls
Exemplo n.º 8
0
 def test_major_link_urls_are_valid(self, base_url, selenium):
     page = Mission(base_url, selenium).open()
     bad_urls = []
     for link in page.major_links_list:
         url = page.link_destination(link.get('locator'))
         response_code = page.get_response_code(url)
         if response_code != requests.codes.ok:
             bad_urls.append('%s is not a valid url - status code: %s.' %
                             (url, response_code))
     assert [] == bad_urls
Exemplo n.º 9
0
 def test_video_srcs_are_valid(self, mozwebqa):
     mission_page = Mission(mozwebqa)
     mission_page.go_to_page()
     bad_srcs = []
     for src in mission_page.video_sources_list:
         response_code = mission_page.get_response_code(src)
         if response_code != requests.codes.ok:
             bad_srcs.append('%s is not a valid url - status code: %s.' %
                             (src, response_code))
     Assert.equal(
         0, len(bad_srcs),
         '%s bad urls found: ' % len(bad_srcs) + ', '.join(bad_srcs))