Skip to content

Commit

Permalink
feat: update test
Browse files Browse the repository at this point in the history
Signed-off-by: SuZhou-Joe <[email protected]>
  • Loading branch information
SuZhou-Joe committed Sep 23, 2023
1 parent 58f995b commit cc4b3e3
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/plugins/workspace/server/integration_tests/routes.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,20 @@
import { WorkspaceAttribute } from 'src/core/types';
import { omit } from 'lodash';
import * as osdTestServer from '../../../../core/test_helpers/osd_server';
import { WorkspaceRoutePermissionItem } from '../types';
import { WorkspacePermissionMode } from '../../../../core/server';

const testWorkspace: WorkspaceAttribute = {
const testWorkspace: WorkspaceAttribute & {
permissions: WorkspaceRoutePermissionItem;
} = {
id: 'fake_id',
name: 'test_workspace',
description: 'test_workspace_description',
permissions: {
modes: [WorkspacePermissionMode.Management],
type: 'user',
userId: '*',
},
};

describe('workspace service', () => {
Expand Down Expand Up @@ -140,7 +149,7 @@ describe('workspace service', () => {
page: 1,
})
.expect(200);
expect(listResult.body.result.total).toEqual(1);
expect(listResult.body.result.total).toEqual(4);
});
});
});

0 comments on commit cc4b3e3

Please sign in to comment.