Skip to content

Commit e73eb26

Browse files
committed
Fix tests
1 parent 6b16844 commit e73eb26

2 files changed

Lines changed: 8 additions & 33 deletions

File tree

tests/Backend/Workspaces/ReadOnlyUserTest.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,14 @@ public function testWorkspaceRestrictionsForReadOnlyUser(): void
1818

1919
$readOnlyWorkspaces = new Workspaces($readOnlyClient);
2020

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+
2129
try {
2230
$readOnlyWorkspaces->createWorkspace([], true);
2331
$this->fail('Workspace request should be restricted for readOnly user');

tests/Common/WorkspaceDetailTest.php

Lines changed: 0 additions & 33 deletions
This file was deleted.

0 commit comments

Comments
 (0)