chore(vscode-ide-companion): add testing infrastructure and improve config files

添加测试基础设施和改进配置文件:
- 添加 vitest.config.js 用于单元测试配置
- 配置测试覆盖率报告(v8 provider)
- 修复 postcss.config.js 的 eslint 警告
- 设置测试环境为 Node.js
This commit is contained in:
yiliang114
2025-11-24 20:34:49 +08:00
parent 795e7fa2c5
commit 36af718616
2 changed files with 18 additions and 2 deletions

View File

@@ -1,6 +1,7 @@
/* eslint-disable no-undef */
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {},
}
}
},
};

View File

@@ -0,0 +1,15 @@
import { defineConfig } from 'vitest/config';
export default defineConfig({
test: {
globals: true,
environment: 'node',
include: ['src/**/*.test.ts'],
coverage: {
provider: 'v8',
reporter: ['text', 'json', 'html', 'clover'],
include: ['src/**/*.ts'],
exclude: ['src/**/*.test.ts', 'src/**/*.d.ts'],
},
},
});
//# sourceMappingURL=vitest.config.js.map