mirror of
https://github.com/spartan-ng/spartan.git
synced 2026-09-22 16:41:38 +08:00
16ecd13eab
Add reporters: ['default'] to the mcp, cli, tools, registry and cli-smoke vite configs (brain and helm already had it). Without a default reporter the @nx/vitest NxReporter is the only one attached, so these projects printed no summary in CI - which is how mcp's silently-undiscovered specs stayed invisible. The counts are now shown so test execution is verifiable at a glance.
31 lines
1.0 KiB
TypeScript
31 lines
1.0 KiB
TypeScript
/// <reference types="vitest" />
|
|
|
|
import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin';
|
|
import { defineConfig } from 'vite';
|
|
|
|
// https://vitejs.dev/config/
|
|
export default defineConfig({
|
|
root: __dirname,
|
|
plugins: [nxViteTsPaths()],
|
|
test: {
|
|
globals: true,
|
|
// Emit the default summary so CI logs show the test counts; a terse reporter previously let
|
|
// a project's specs go silently undiscovered.
|
|
reporters: ['default'],
|
|
environment: 'node',
|
|
include: ['src/**/*.spec.ts'],
|
|
// Stands up a local npm registry and publishes the spartan packages before the matrix runs.
|
|
globalSetup: ['src/support/global-setup.ts'],
|
|
// Each matrix cell scaffolds a workspace, installs dependencies and runs a real build, so the
|
|
// suite is slow and must not run in parallel (a single local registry is shared).
|
|
testTimeout: 900_000,
|
|
hookTimeout: 900_000,
|
|
fileParallelism: false,
|
|
pool: 'forks',
|
|
poolOptions: {
|
|
forks: { singleFork: true },
|
|
},
|
|
},
|
|
cacheDir: '../../node_modules/.vitest/cli-smoke',
|
|
});
|