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'))
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'))
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']))