Skip to content

Commit

Permalink
test: improve knora test
Browse files Browse the repository at this point in the history
  • Loading branch information
subotic committed Oct 11, 2019
1 parent 16844d8 commit 5f41ac5
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions tests/test_knora.py
Expand Up @@ -60,11 +60,15 @@ def test_create_user(con):

print(user_iri)

# check that the created user exists
res = connection.get_user_by_iri(user_iri)

assert (res["username"] == "testtest")
assert (res["email"] == "testtest@example.com")

# try to login
# logout
connection.logout()
assert (connection.get_token() is None)

# login
connection.login(res["email"], "test")
assert (connection.get_token() is not None)

0 comments on commit 5f41ac5

Please sign in to comment.