From add9e31d8dfe49bab053e39c56929f653575699f Mon Sep 17 00:00:00 2001 From: Felicio Mununga Date: Tue, 23 Aug 2022 20:37:50 +0200 Subject: [PATCH] use `process.env.VITEST` --- packages/status-js/vite.config.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/status-js/vite.config.ts b/packages/status-js/vite.config.ts index 01a77a86..f97ac9eb 100644 --- a/packages/status-js/vite.config.ts +++ b/packages/status-js/vite.config.ts @@ -14,7 +14,7 @@ const external = [ export default defineConfig(({ mode }) => { const alias: Alias[] = [] - if (mode === 'test') { + if (process.env.VITEST === 'true' || mode === 'test') { alias.push({ /** * Note: `happy-dom` nor `jsdom` have Crypto implemented (@see https://github.com/jsdom/jsdom/issues/1612)