Some checks failed
CI / Lint & Typecheck (push) Has been cancelled
CI / Test (routes) (push) Has been cancelled
CI / Test (security) (push) Has been cancelled
CI / Test (services) (push) Has been cancelled
CI / Test (unit) (push) Has been cancelled
CI / Test (integration) (push) Has been cancelled
CI / Test Coverage (push) Has been cancelled
CI / Build (push) Has been cancelled
38 lines
940 B
TypeScript
38 lines
940 B
TypeScript
/**
|
|
* Unit Tests Configuration
|
|
*
|
|
* Fast, isolated tests for pure functions:
|
|
* - utils/* (crypto, jwt, password, parsing, http, errors)
|
|
* - schemas (Zod validation)
|
|
* - mediaServer parsers (Plex/Jellyfin response parsing)
|
|
*
|
|
* Run: pnpm test:unit
|
|
*/
|
|
|
|
import { defineConfig, mergeConfig } from 'vitest/config';
|
|
import { sharedConfig } from './vitest.shared.js';
|
|
|
|
export default mergeConfig(
|
|
sharedConfig,
|
|
defineConfig({
|
|
test: {
|
|
name: 'unit',
|
|
include: [
|
|
'src/utils/__tests__/*.test.ts',
|
|
'src/test/schemas.test.ts',
|
|
'src/services/mediaServer/__tests__/*.test.ts',
|
|
],
|
|
coverage: {
|
|
provider: 'v8',
|
|
reporter: ['text', 'json', 'json-summary'],
|
|
reportsDirectory: './coverage/unit',
|
|
include: [
|
|
'src/utils/**/*.ts',
|
|
'src/services/mediaServer/**/*.ts',
|
|
],
|
|
exclude: ['**/*.test.ts', '**/test/**'],
|
|
},
|
|
},
|
|
})
|
|
);
|