Skip to content

NYC -> C8 - #4221

Open
MicahMaphet wants to merge 1 commit into
bitpay:masterfrom
MicahMaphet:c8
Open

NYC -> C8#4221
MicahMaphet wants to merge 1 commit into
bitpay:masterfrom
MicahMaphet:c8

Conversation

@MicahMaphet

@MicahMaphet MicahMaphet commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Description

Migrate from nyc to c8.

Motivation

nyc doesn't support ES modules while c8 does

Changelog

  • Replace nyc with c8
  • Convert all .nycrc.yml files to .c8rc.json
  • Convert all .mocharc.yml files to .mocharc.json; add recursive: true and extension: ".test.js"
  • Simplify test scripts from glob patterns (nyc mocha 'ts_build/test/**/*.test.js') to directory specs (c8 mocha ts_build/test)
  • Update bitcore-build gulp test:node task from nyc to c8
  • Move crypto-rpc's inline c8 config from package.json into .c8rc.json
  • bitcore-client: run compiled JavaScript instead of TyepScript via tsx
  • bitcore-client: convert bitcore-node imports in wallet.test.ts to require() with paths corrected for the compiled location (ts_build/test/unit). Importing does type checking on bitcore-node which breaks.

Testing Notes

Run all tests and compare coverage

c8 counts every line

C8:
image

NYC:
image


Checklist

  • I have read CONTRIBUTING.md and verified that this PR follows the guidelines and requirements outlined in it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant