From 9615803109524a11e55bc426bb209da3468e1155 Mon Sep 17 00:00:00 2001 From: SuZhou-Joe Date: Thu, 21 Sep 2023 15:02:28 +0800 Subject: [PATCH] feat: enable workspace flag when run workspace related test Signed-off-by: SuZhou-Joe --- .../server/integration_tests/routes.test.ts | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/plugins/workspace/server/integration_tests/routes.test.ts b/src/plugins/workspace/server/integration_tests/routes.test.ts index bdb342e00ade..e4d29b86ac55 100644 --- a/src/plugins/workspace/server/integration_tests/routes.test.ts +++ b/src/plugins/workspace/server/integration_tests/routes.test.ts @@ -17,14 +17,19 @@ describe('workspace service', () => { let root: ReturnType; let opensearchServer: osdTestServer.TestOpenSearchUtils; beforeAll(async () => { - const { startOpenSearch } = osdTestServer.createTestServers({ + const { startOpenSearch, startOpenSearchDashboards } = osdTestServer.createTestServers({ adjustTimeout: (t: number) => jest.setTimeout(t), + settings: { + osd: { + workspace: { + enabled: true, + }, + }, + }, }); opensearchServer = await startOpenSearch(); - root = osdTestServer.createRootWithCorePlugins(); - - await root.setup(); - await root.start(); + const startOSDResp = await startOpenSearchDashboards(); + root = startOSDResp.root; }, 30000); afterAll(async () => { await root.shutdown();