Scope project user payloads to visible users #42

Merged
Twyco merged 4 commits from koda/pr37-visible-users into codex/api-application-access 2026-04-22 08:57:57 +00:00
Showing only changes of commit 3f4c8f49d9 - Show all commits
+8 -6
View File
@@ -175,16 +175,18 @@ class SettingsApiTest extends TestCase
$this->actingAs($user)
->getJson(route('api.projects.backlog', $project))
->assertOk()
->assertJsonPath('data.users.0.name', 'Team Viewer')
->assertJsonPath('data.users.1.name', 'Visible User')
->assertJsonCount(2, 'data.users');
->assertJsonPath('data.users.0.name', $user->name)
->assertJsonPath('data.users.1.name', 'Team Viewer')
->assertJsonPath('data.users.2.name', 'Visible User')
->assertJsonCount(3, 'data.users');
$this->actingAs($user)
->getJson(route('api.projects.tickets.show', [$project, $ticket]))
->assertOk()
->assertJsonPath('data.users.0.name', 'Team Viewer')
->assertJsonPath('data.users.1.name', 'Visible User')
->assertJsonCount(2, 'data.users');
->assertJsonPath('data.users.0.name', $user->name)
->assertJsonPath('data.users.1.name', 'Team Viewer')
->assertJsonPath('data.users.2.name', 'Visible User')
->assertJsonCount(3, 'data.users');
}
public function test_project_repositories_and_user_git_connections_are_available(): void