Skip to content

Commit

Permalink
adjusted changes in nc_py_api cloud-py-api/nc_py_api/pull/145
Browse files Browse the repository at this point in the history
  • Loading branch information
bigcat88 committed Oct 14, 2023
1 parent 244a337 commit 0505742
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/app_version_higher.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@
nc_client.users.create("second_admin", password="2Very3Strong4", groups=["admin"])

nc_application = NextcloudApp(user="admin")
assert nc_application.users.get_details() # OCS call works
assert nc_application.users.get_user() # OCS call works
assert not nc_application.notifications.get_all() # there are no notifications
nc_application._session.adapter.headers.update({"EX-APP-VERSION": "99.0.0"}) # change ExApp version
with pytest.raises(NextcloudException) as exc_info:
nc_application.users.get_details() # this call should be rejected by AppAPI
nc_application.users.get_user() # this call should be rejected by AppAPI
assert exc_info.value.status_code == 401

assert nc_client.apps.ex_app_is_disabled("nc_py_api") is True
Expand Down

0 comments on commit 0505742

Please sign in to comment.