debian-image-builder-frontend/vitest.config.ts
regexowl d8c3a49c19 vitest.config: Inline @monaco-editor
`@monaco-editor` needs to be inlined in order to run the tests smoothly without any errors.

Note: dependencies include both `@monaco-editor` and `monaco-editor`, only the `@` one needs to be inlined in test dependencies.
2024-10-01 12:34:30 +02:00

34 lines
649 B
TypeScript

import react from '@vitejs/plugin-react';
const config = {
plugins: [react()],
test: {
globals: true,
environment: 'jsdom',
setupFiles: ['./src/test/setup.ts'],
coverage: {
provider: 'v8',
},
server: {
deps: {
inline: ['vitest-canvas-mock', '@patternfly', '@monaco-editor'],
},
},
testTimeout: 10000,
fileParallelism: false,
},
reporters: ['default', 'junit'],
outputFile: {
junit: './coverage/junit.xml',
},
resolve: {
mainFields: ['module'],
},
esbuild: {
loader: 'tsx',
include: /src\/.*\.[tj]sx?$/,
exclude: [],
},
};
export default config;