Skip to content

Commit

Permalink
Add "Assert text not visible" to Behave-BDD steps
Browse files Browse the repository at this point in the history
  • Loading branch information
mdmintz committed Jun 17, 2022
1 parent 2cba0c8 commit d525aaa
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions sbase/steps.py
Original file line number Diff line number Diff line change
Expand Up @@ -586,3 +586,21 @@ def deferred_assert_exact_text(context, text, selector):
def process_deferred_asserts(context):
sb = context.sb
sb.process_deferred_asserts()


@step("Assert text not visible '{text}' in '{selector}'")
@step('Assert text not visible "{text}" in "{selector}"')
@step("Assert text not visible '{text}' in \"{selector}\"")
@step('Assert text not visible "{text}" in \'{selector}\'')
def assert_text_not_visible_in_element(context, text, selector):
sb = context.sb
text = normalize_text(text)
sb.assert_text_not_visible(text, selector)


@step("Assert text not visible '{text}'")
@step('Assert text not visible "{text}"')
def assert_text_not_visible(context, text):
sb = context.sb
text = normalize_text(text)
sb.assert_text_not_visible(text)

0 comments on commit d525aaa

Please sign in to comment.