diff options
author | Frederick Muriuki Muriithi | 2024-06-20 15:34:02 -0500 |
---|---|---|
committer | Frederick Muriuki Muriithi | 2024-06-20 15:34:02 -0500 |
commit | c0f5b9d646487e035f2d2e5370041b317b81baf6 (patch) | |
tree | e1cce317553a2379aa1717d700ded55ca9418440 /gn_auth/auth/authorisation/resources/groups | |
parent | 8e460b05da4d419aa1b53b1c639d3e370143de4f (diff) | |
download | gn-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 'gn_auth/auth/authorisation/resources/groups')
-rw-r--r-- | gn_auth/auth/authorisation/resources/groups/models.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gn_auth/auth/authorisation/resources/groups/models.py b/gn_auth/auth/authorisation/resources/groups/models.py index 03a93b6..ee77654 100644 --- a/gn_auth/auth/authorisation/resources/groups/models.py +++ b/gn_auth/auth/authorisation/resources/groups/models.py @@ -72,7 +72,7 @@ def user_membership(conn: db.DbConnection, user: User) -> Sequence[Group]: "WHERE group_users.user_id=?") with db.cursor(conn) as cursor: cursor.execute(query, (str(user.user_id),)) - groups = tuple(Group(row[0], row[1], json.loads(row[2])) + groups = tuple(Group(row[0], row[1], json.loads(row[2] or "{}")) for row in cursor.fetchall()) return groups |