@@ -1317,20 +1317,23 @@ class TestTeamMemberAssignmentsAPIView(ViewTestMixin):
13171317 lib:Org3:LIB3 → admin_3 (library_admin), regular_5 (library_admin), regular_6 (library_author),
13181318 regular_7 (library_contributor), regular_8 (library_user)
13191319
1320- URL: /authz/v1/users/<username>/assignments
1320+ URL: /api/ authz/v1/users/<username>/assignments/
13211321 Response fields per item: is_superadmin, role, org, scope, permission_count
13221322
13231323 Superadmin entry:
1324- admin_1..3 are staff/superusers. Querying any of them adds one entry
1324+ admin_1..3 are staff/superusers. Querying any of them always adds one
13251325 SuperAdminAssignmentData entry: role="django.superuser" (or "django.staff"),
13261326 org="*", scope="*", permission_count=None, is_superadmin=True.
13271327 This entry is always included regardless of org/role filters, since those
13281328 filters are applied only to the role assignments, not to the superadmin entry.
13291329
13301330 Visibility via filter_allowed_assignments:
1331- - Staff/superuser: sees all assignments for any user
1332- - regular_1 (library_user in Org1:LIB1): sees only Org1:LIB1 assignments
1333- - regular_9 (no assignments): sees nothing for any user
1331+ - Staff/superuser: sees all role assignments for any user, plus the superadmin
1332+ entry when the target is a superadmin.
1333+ - regular_1 (library_user in Org1:LIB1): sees only Org1:LIB1 role assignments,
1334+ plus the superadmin entry when the target is a superadmin.
1335+ - regular_9 (no assignments): sees no role assignments for any user, but still
1336+ sees the superadmin entry when the target is a superadmin.
13341337 """
13351338
13361339 def setUp (self ):
0 commit comments