feat: update status codes and navigation structure in calculations and reports routes
This commit is contained in:
@@ -90,9 +90,9 @@ class TestAuthenticationRequirements:
|
||||
|
||||
def test_ui_project_list_requires_login(self, client, auth_session_context):
|
||||
with auth_session_context(None):
|
||||
response = client.get("/projects/ui")
|
||||
|
||||
assert response.status_code == status.HTTP_401_UNAUTHORIZED
|
||||
response = client.get("/projects/ui", follow_redirects=False)
|
||||
assert response.status_code == status.HTTP_303_SEE_OTHER
|
||||
assert response.headers["location"].endswith("/login")
|
||||
|
||||
|
||||
class TestRoleRestrictions:
|
||||
@@ -194,7 +194,7 @@ class TestRoleRestrictions:
|
||||
|
||||
assert response.status_code == status.HTTP_403_FORBIDDEN
|
||||
assert response.json()[
|
||||
"detail"] == "Insufficient role permissions for this action."
|
||||
"detail"] == "Insufficient permissions for this action."
|
||||
|
||||
def test_ui_project_edit_accessible_to_manager(
|
||||
self,
|
||||
|
||||
Reference in New Issue
Block a user