Skip to content

Commit

Permalink
flake8
Browse files Browse the repository at this point in the history
  • Loading branch information
baszoetekouw committed May 30, 2023
1 parent 826f833 commit 93bfc2a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion server/api/aup.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def agreed_aup():
session["user"] = {**session["user"], **{"user_accepted_aup": True}}

_, location = get_redirect(current_app.app_config, user_accepted_aup=True,
second_factor_confirmed=session["user"]["second_factor_confirmed"])
second_factor_confirmed=session["user"]["second_factor_confirmed"])

ctx_logger("redirect").debug(f"Redirecting user {user_id} to {location}")

Expand Down
4 changes: 2 additions & 2 deletions server/test/api/test_mfa.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def test_ssid_scenario(self):
self.assertEqual(302, res.status_code)
self.assertEqual("https://foo.bar", res.location)

def test_ssid_new_user(self):
def test_ssid_scenario_new_user(self):
# initiate proxy_authz call to provision user and initialize 2fa
res = self.post("/api/users/proxy_authz", response_status_code=200,
body={"user_id": "urn:new_user", "service_id": self.app.app_config.oidc.sram_service_entity_id,
Expand Down Expand Up @@ -88,7 +88,7 @@ def test_ssid_new_user(self):
content_type="application/x-www-form-urlencoded")

self.assertEqual(302, res.status_code)
self.assertEqual(self.app.app_config.base_url+"/aup", res.location)
self.assertEqual(self.app.app_config.base_url + "/aup", res.location)

res = self.post("/api/aup/agree", with_basic_auth=False)
self.assertEqual("https://foo.bar", res["location"])
Expand Down

0 comments on commit 93bfc2a

Please sign in to comment.