Skip to content
Snippets Groups Projects

Resolve "Add tests for remember me button"

Merged Mark requested to merge 46-add-tests-for-remember-me-button into master
All threads resolved!
2 files
+ 13
12
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -30,20 +30,21 @@ def step_impl(context, element, variable):
value = context.oauth[variable]
assert value in elem.text
@then(u'I expect that the "{variable}" in the json output is the same as oauth variable "{value}"')
def step_impl(context, variable, value)
assert context.oauth[value] == get_value_from_json_body(context, variable)
@then(u'I expect that the "{variable}" in the json output is "{value}"')
def step_impl(context, variable, value):
if value in context.oauth:
assert context.oauth[value] == get_value_from_json_body(context, variable)
else:
assert value == get_value_from_json_body(context, variable)
assert value == get_value_from_json_body(context, variable)
@then(u'I expect that the "{variable}" in the json output contains the value of oauth variable "{value}"')
def step_impl(context, variable, value):
assert context.oauth[value] in get_value_from_json_body(context, variable)
@then(u'I expect that the "{variable}" in the json output contains "{value}"')
def step_impl(context, variable, value):
if value in context.oauth:
assert context.oauth[value] in get_value_from_json_body(context, variable)
else:
assert value in get_value_from_json_body(context, variable)
assert value in get_value_from_json_body(context, variable)
def get_value_from_json_body(context, key):
obj_serialized = context.behave_driver.get_element("body").text
Loading