mirror of
https://github.com/enso-org/enso.git
synced 2024-12-22 12:11:31 +03:00
908f426cac
1. Bumped eslint and its plugins versions, and autofix new errors (mostly eslint disables which were no longer neccessary) 2. ~~Replace eslint with eslint-p which speed up linter a bit (at least on my machine)~~ - CI machines don't like it. 3. Fixed/worked around one problem with flacky selection _unit_ tests.
55 lines
1.3 KiB
TypeScript
55 lines
1.3 KiB
TypeScript
/** @file Vite configuration for dashboard e2e tests' server. */
|
|
import { fileURLToPath } from 'node:url'
|
|
|
|
import { defineConfig, mergeConfig } from 'vite'
|
|
|
|
import { loadTestEnvironmentVariables } from 'enso-common/src/appConfig'
|
|
|
|
// =====================
|
|
// === Configuration ===
|
|
// =====================
|
|
|
|
loadTestEnvironmentVariables()
|
|
|
|
// This configuration file is for dashboard tests only.
|
|
process.env.CLOUD_BUILD = 'true'
|
|
const CONFIG = (await import('./vite.config')).default
|
|
|
|
export default mergeConfig(
|
|
CONFIG,
|
|
defineConfig({
|
|
resolve: {
|
|
alias: {
|
|
'@stripe/stripe-js/pure': fileURLToPath(
|
|
new URL('./e2e/dashboard/mock/stripe.ts', import.meta.url),
|
|
),
|
|
'@stripe/react-stripe-js': fileURLToPath(
|
|
new URL('./e2e/dashboard/mock/react-stripe.tsx', import.meta.url),
|
|
),
|
|
},
|
|
extensions: [
|
|
'.mock.mjs',
|
|
'.mock.js',
|
|
'.mock.mts',
|
|
'.mock.ts',
|
|
'.mock.jsx',
|
|
'.mock.tsx',
|
|
'.mock.json',
|
|
'.mjs',
|
|
'.js',
|
|
'.mts',
|
|
'.ts',
|
|
'.jsx',
|
|
'.tsx',
|
|
'.json',
|
|
],
|
|
},
|
|
define: {
|
|
'process.env.IS_IN_PLAYWRIGHT_TEST': JSON.stringify(`${true}`),
|
|
},
|
|
build: {
|
|
outDir: fileURLToPath(new URL('./mockDist', import.meta.url)),
|
|
},
|
|
}),
|
|
)
|