示例#1
0
 def test_list_creation(self):
     name = ''.join(random.choice(
         string.ascii_lowercase + string.digits) for x in range(15))
     h = HomePage(self.driver)
     h.open_default_url()
     assert(h.create_list(name))
     self.driver.find_element_by_link_text('Find gifts now').click()
     assert(self.driver.current_url.endswith('/shops'))
示例#2
0
 def test_slide_nav(self):
     h = HomePage(self.driver)
     h.open_default_url()
     assert(h.is_slide_visible('slide 1'))
     h.go_to_next_slide()
     assert(h.is_slide_visible('slide 2'))
     h.go_to_next_slide()
     assert(h.is_slide_visible('slide 3'))
     h.go_to_prev_slide()
     assert(h.is_slide_visible('slide 2'))
     h.go_to_prev_slide()
     assert(h.is_slide_visible('slide 1'))
示例#3
0
 def test_images_present(self):
     h = HomePage(self.driver)
     h.open_default_url()
     assert(h.is_element_available(h.locators['specials btn']))
     assert(h.is_element_available(h.locators['list textbox']))
     assert(h.is_element_available(h.locators['list btn']))