We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6b16844 commit e73eb26Copy full SHA for e73eb26
2 files changed
tests/Backend/Workspaces/ReadOnlyUserTest.php
@@ -18,6 +18,14 @@ public function testWorkspaceRestrictionsForReadOnlyUser(): void
18
19
$readOnlyWorkspaces = new Workspaces($readOnlyClient);
20
21
+ // Try to get workspace detail
22
+ $workspaceDetail = $readOnlyWorkspaces->getWorkspace($workspace['id']);
23
+
24
+ // Assert that workspace detail is returned and does not contain sensitive info
25
+ $this->assertArrayHasKey('id', $workspaceDetail);
26
+ $this->assertEquals($workspace['id'], $workspaceDetail['id']);
27
+ $this->assertArrayNotHasKey('password', $workspaceDetail['connection']);
28
29
try {
30
$readOnlyWorkspaces->createWorkspace([], true);
31
$this->fail('Workspace request should be restricted for readOnly user');
tests/Common/WorkspaceDetailTest.php
0 commit comments