ci: Enable Codecov Test Analytics and update badge token

Add JUnit XML reporting to the test-coverage job and upload results
via codecov/test-results-action. This enables Test Analytics features
(test run times, failure rates, flaky test detection, and PR comments
with failed test summaries).

Also update the README Codecov badge URL to include the graph token,
following Codecov's new recommended badge format.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Kazuki Yamada
2026-04-11 19:38:21 +09:00
parent 5a011342d4
commit 7116490789
3 changed files with 9 additions and 2 deletions
+7 -1
View File
@@ -136,7 +136,7 @@ jobs:
node-version-file: .tool-versions
cache: npm
- run: npm ci
- run: npm run test-coverage -- --reporter=verbose
- run: npm run test-coverage -- --reporter=verbose --reporter=junit --outputFile.junit=./test-report.junit.xml
env:
CI_OS: ${{ runner.os }}
- uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
@@ -149,6 +149,12 @@ jobs:
directory: ./coverage
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- uses: codecov/test-results-action@0fa95f0e1eeaafde2c782583b36b28ad0d8c77d3 # v1.2.1
if: ${{ !cancelled() }}
with:
files: ./test-report.junit.xml
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
build-and-run:
name: Build and run
+1
View File
@@ -20,6 +20,7 @@ website/server/.compile-cache/
# Test coverage
coverage/
test-report.junit.xml
# Temporary files
*.tmp
+1 -1
View File
@@ -40,7 +40,7 @@
[![npm](https://img.shields.io/npm/v/repomix.svg?maxAge=1000)](https://www.npmjs.com/package/repomix)
[![npm](https://img.shields.io/npm/d18m/repomix)](https://www.npmjs.com/package/repomix)
[![Actions Status](https://github.com/yamadashy/repomix/actions/workflows/ci.yml/badge.svg)](https://github.com/yamadashy/repomix/actions?query=workflow%3A"ci")
[![codecov](https://codecov.io/github/yamadashy/repomix/graph/badge.svg)](https://codecov.io/github/yamadashy/repomix)
[![codecov](https://codecov.io/github/yamadashy/repomix/graph/badge.svg?token=PYQHD2SSHX)](https://codecov.io/github/yamadashy/repomix)
[![Sponsors](https://img.shields.io/github/sponsors/yamadashy?logo=github)](https://github.com/sponsors/yamadashy)
[![Discord](https://badgen.net/discord/online-members/wNYzTwZFku?icon=discord&label=discord)](https://discord.gg/wNYzTwZFku)