Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/actions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@
"@celo/dev-utils": "workspace:^",
"@celo/typescript": "workspace:^",
"@size-limit/preset-small-lib": "^11.2.0",
"@vitest/coverage-v8": "^3.2.6",
"@vitest/coverage-v8": "^4.0.0",
"dotenv": "^8.2.0",
"size-limit": "^11.2.0",
"vitest": "^3.2.6"
"vitest": "^4.0.0"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Upgrade the matching Vitest coverage provider

When general_vi_test runs these workspaces with test --coverage (.github/workflows/ci.yml:232-241), each still installs @vitest/coverage-v8 3.2.6 while Vitest now resolves to 4.1.11. The lockfile shows that the provider requires exactly Vitest 3.2.6 (yarn.lock:6783-6802) and Vitest 4.1.11 requests provider 4.1.11 (yarn.lock:16120); Yarn consequently reports incompatible peer dependencies, and coverage execution loads an incompatible provider. Upgrade @vitest/coverage-v8 alongside Vitest in actions, core, and viem-account-ledger.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed in 32fc91c: @vitest/coverage-v8 moved to ^4.0.0 in actions, core and viem-account-ledger; yarn why shows a single 4.1.11 resolution next to vitest 4.1.11, and the fetchCache crash is gone. Leaving the thread for a human to resolve.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Restore all-source coverage after upgrading Vitest

When .github/workflows/ci.yml runs the actions, core, and viem-account-ledger workspaces with --coverage, Vitest 4 reports only files loaded during the test run when coverage.include is undefined because coverage.all and its all-files default were removed, as documented in the Vitest 4 migration guide. All three workspace configs specify only coverage.exclude, so unimported source files—for example, several contract modules in actions—now disappear from LCOV rather than appearing with zero coverage, inflating Codecov results and potentially allowing untested additions to bypass the patch-coverage check. Add an explicit source glob such as coverage.include: ['src/**/*.ts'] to each affected config as part of this upgrade.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed in 3ed763c: coverage.include: ["src/**/*.ts"] added to all three vitest configs. Verified locally that the LCOV file set equals the non-test src/**/*.ts set minus the existing data/tokens/test-utils excludes (21 files in actions, 5 in core, 7 in viem-account-ledger), matching what Vitest 3 reported. Leaving the thread for a human to resolve.

},
"engines": {
"node": ">=20"
Expand Down
1 change: 1 addition & 0 deletions packages/actions/vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ export default defineConfig({
// to hook into it, useful for testWithAnvil.
globals: true,
coverage: {
include: ['src/**/*.ts'],
reporter: ['json', 'clover', 'lcov'],
exclude: ['**/data**', '**/tokens**', '**/test-utils**', ...coverageConfigDefaults.exclude],
},
Expand Down
4 changes: 2 additions & 2 deletions packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@
"devDependencies": {
"@celo/typescript": "workspace:^",
"@size-limit/preset-small-lib": "^11.2.0",
"@vitest/coverage-v8": "^3.2.6",
"@vitest/coverage-v8": "^4.0.0",
"dotenv": "^8.2.0",
"size-limit": "^11.2.0",
"viem": "^2.33.2",
"vitest": "^3.2.6"
"vitest": "^4.0.0"
},
"engines": {
"node": ">=20"
Expand Down
1 change: 1 addition & 0 deletions packages/core/vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export default defineConfig({
sourcemap: false,
},
coverage: {
include: ['src/**/*.ts'],
reporter: ['json', 'clover', 'lcov'],
exclude: ['**/data**', '**/tokens**', '**/test-utils**', ...coverageConfigDefaults.exclude],
},
Expand Down
2 changes: 1 addition & 1 deletion packages/dev-utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
},
"peerDependencies": {
"jest": "^29.7.0",
"vitest": "^3.2.6"
"vitest": "^4.0.0"
},
"peerDependenciesMeta": {
"jest": {
Expand Down
4 changes: 2 additions & 2 deletions packages/viem-account-ledger/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,10 @@
"@ledgerhq/hw-transport-node-hid": "^6.29.5",
"@noble/curves": "^1.3.0",
"@types/semver": "^7.7.0",
"@vitest/coverage-v8": "^3.2.6",
"@vitest/coverage-v8": "^4.0.0",
"dotenv": "^8.2.0",
"viem": "^2.33.2",
"vitest": "^3.2.6"
"vitest": "^4.0.0"
},
"engines": {
"node": ">=20"
Expand Down
1 change: 1 addition & 0 deletions packages/viem-account-ledger/vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export default defineConfig({
sourcemap: process.env.CI ? false : true, // Disable sourcemaps in CI for performance
},
coverage: {
include: ['src/**/*.ts'],
reporter: ['json', 'clover', 'lcov'],
exclude: ['**/data**', '**/tokens**', '**/test-utils**', ...coverageConfigDefaults.exclude],
},
Expand Down
Loading
Loading