aboutsummaryrefslogtreecommitdiff
path: root/tests/unit/auth/test_privileges.py
diff options
context:
space:
mode:
authorFrederick Muriuki Muriithi2024-06-20 15:34:02 -0500
committerFrederick Muriuki Muriithi2024-06-20 15:34:02 -0500
commitc0f5b9d646487e035f2d2e5370041b317b81baf6 (patch)
treee1cce317553a2379aa1717d700ded55ca9418440 /tests/unit/auth/test_privileges.py
parent8e460b05da4d419aa1b53b1c639d3e370143de4f (diff)
downloadgn-auth-c0f5b9d646487e035f2d2e5370041b317b81baf6.tar.gz
Reorganise test fixtures. Fix tests and issues caught.
Reorganise test fixtures to more closely follow the design of the auth system. Fix the broken tests due to refactors and fix all issues caught by the running tests.
Diffstat (limited to 'tests/unit/auth/test_privileges.py')
-rw-r--r--tests/unit/auth/test_privileges.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/unit/auth/test_privileges.py b/tests/unit/auth/test_privileges.py
index a225369..619ccc1 100644
--- a/tests/unit/auth/test_privileges.py
+++ b/tests/unit/auth/test_privileges.py
@@ -11,8 +11,7 @@ def sort_key_privileges(priv):
return priv.privilege_id
PRIVILEGES = sorted(
- (Privilege("system:group:create-group", "Create a group"),
- Privilege("system:group:view-group", "View the details of a group"),
+ (Privilege("system:group:view-group", "View the details of a group"),
Privilege("system:group:edit-group", "Edit the details of a group"),
Privilege("system:user:list", "List users in the system"),
Privilege("system:group:delete-group", "Delete a group"),
@@ -32,7 +31,7 @@ PRIVILEGES = sorted(
@pytest.mark.parametrize(
"user,expected", tuple(zip(
conftest.TEST_USERS, (PRIVILEGES, [], [], [], []))))
-def test_user_privileges(auth_testdb_path, fxtr_users, user, expected):# pylint: disable=[unused-argument]
+def test_user_privileges(auth_testdb_path, fxtr_setup_group_leaders, user, expected):# pylint: disable=[unused-argument]
"""
GIVEN: A user
WHEN: An attempt is made to fetch the user's privileges