def wait_shown_selector(self, elem_selector, max = 5): not_shown = lambda: not self.browser.find_element_by_css_selector(elem_selector).is_displayed() wait_while(not_shown, max) return self.assert_shown_selector(elem_selector)
def wait_shown(self, elem_id, max = 5): not_shown = lambda: not self.browser.find_element_by_id(elem_id).is_displayed() wait_while(not_shown, max) return self.assert_shown(elem_id)