Skip to content

Commit

Permalink
Merge pull request #5532 from mrpau/hotfix/5505-fix-bdd-tests
Browse files Browse the repository at this point in the history
Check HTTP Response for BDD tests
  • Loading branch information
benjaoming committed Nov 7, 2017
2 parents 7b2b4a2 + cc5203b commit 5b2bf2e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions kalite/testing/behave_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -415,10 +415,8 @@ def __init__(self):

def logout(context):
url = reverse("api_dispatch_list", kwargs={"resource_name": "user"}) + "logout/"
context.browser.get(build_url(context, url))
pre_element = find_css_with_wait(context, "pre")
json_response_text = pre_element.text
assert "success" in json_response_text and "true" in json_response_text
response = urllib.urlopen(build_url(context, url))
assert response.getcode() == 200


def post(context, url, data=""):
Expand Down

0 comments on commit 5b2bf2e

Please sign in to comment.