Fixed issue of searching for text

Now the step calls is_text_present and is_text_not_present with a wait time of 5 seconds so that the page can be properly refreshed/reloaded if needed.
This also gets rid of an assert not
This commit is contained in:
JonahStanley
2013-05-31 15:33:56 -04:00
parent cb9da2cd03
commit 286fcece4a

View File

@@ -132,9 +132,9 @@ def should_have_link_with_id_and_text(step, link_id, text):
@step(r'should( not)? see "(.*)" (?:somewhere|anywhere) (?:in|on) (?:the|this) page')
def should_see_in_the_page(step, doesnt_appear, text):
if doesnt_appear:
assert world.browser.is_text_not_present(text)
assert world.browser.is_text_not_present(text, wait_time=5)
else:
assert_in(text, world.css_text('body'))
assert world.browser.is_text_present(text, wait_time=5)
@step('I am logged in$')