Backend tests: - CPU, memory, disk, network collector tests (existing) - Added temperature, processes, system, AMD GPU collector tests - All tests use mock filesystem data Frontend tests: - Added Vitest with jsdom environment - Tests for formatters (formatBytes, formatUptime, etc.) - Tests for theme store 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
19 lines
405 B
TypeScript
19 lines
405 B
TypeScript
import { defineConfig } from 'vitest/config';
|
|
import { svelte } from '@sveltejs/vite-plugin-svelte';
|
|
|
|
export default defineConfig({
|
|
plugins: [svelte({ hot: !process.env.VITEST })],
|
|
test: {
|
|
include: ['src/**/*.{test,spec}.{js,ts}'],
|
|
environment: 'jsdom',
|
|
globals: true,
|
|
setupFiles: ['src/tests/setup.ts']
|
|
},
|
|
resolve: {
|
|
alias: {
|
|
$lib: '/src/lib',
|
|
$app: '/src/tests/mocks/app'
|
|
}
|
|
}
|
|
});
|