mirror of
https://github.com/elk-zone/elk.git
synced 2024-11-10 19:09:58 +00:00
chore: simplify test for mock user
This commit is contained in:
parent
33b0f295f6
commit
8c82c91056
1 changed files with 2 additions and 2 deletions
|
@ -1,6 +1,6 @@
|
||||||
import { fileURLToPath } from 'node:url'
|
import { fileURLToPath } from 'node:url'
|
||||||
import Inspect from 'vite-plugin-inspect'
|
import Inspect from 'vite-plugin-inspect'
|
||||||
import { isCI, isDevelopment } from 'std-env'
|
import { isCI } from 'std-env'
|
||||||
import { i18n } from './config/i18n'
|
import { i18n } from './config/i18n'
|
||||||
|
|
||||||
const isPreview = process.env.PULL_REQUEST === 'true'
|
const isPreview = process.env.PULL_REQUEST === 'true'
|
||||||
|
@ -36,7 +36,7 @@ export default defineNuxtConfig({
|
||||||
'import.meta.env.__BUILD_TIME__': JSON.stringify(new Date().toISOString()),
|
'import.meta.env.__BUILD_TIME__': JSON.stringify(new Date().toISOString()),
|
||||||
'import.meta.env.__BUILD_COMMIT__': JSON.stringify(process.env.COMMIT_REF || ''),
|
'import.meta.env.__BUILD_COMMIT__': JSON.stringify(process.env.COMMIT_REF || ''),
|
||||||
'process.env.VSCODE_TEXTMATE_DEBUG': 'false',
|
'process.env.VSCODE_TEXTMATE_DEBUG': 'false',
|
||||||
'process.mock': ((isDevelopment || (isCI && process.env.PULL_REQUEST === 'true')) && process.env.MOCK_USER) || 'false',
|
'process.mock': ((!isCI || isPreview) && process.env.MOCK_USER) || 'false',
|
||||||
},
|
},
|
||||||
build: {
|
build: {
|
||||||
target: 'esnext',
|
target: 'esnext',
|
||||||
|
|
Loading…
Reference in a new issue