feat: Publish test coverage summaries to PRs (#513)

This commit is contained in:
Allen Hutchison
2025-05-27 12:45:28 -07:00
committed by GitHub
parent 9595e98db8
commit 4e3c539f5e
7 changed files with 184 additions and 11 deletions

View File

@@ -0,0 +1,28 @@
/**
* @license
* Copyright 2025 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
import { defineConfig } from 'vitest/config';
export default defineConfig({
test: {
reporters: ['default', 'junit'],
outputFile: {
junit: 'junit.xml',
},
coverage: {
provider: 'v8',
reportsDirectory: './coverage',
reporter: [
['text', { file: 'full-text-summary.txt' }],
'html',
'json',
'lcov',
'cobertura',
['json-summary', { outputFile: 'coverage-summary.json' }],
],
},
},
});