Skip to content

src: refactor coverage connection

src: refactor coverage connection

  • Refactor the C++ class to be resuable for other types of profiles
  • Move the try-catch block around coverage collection callback to be inside the callback to silence potential JSON or write errors.
  • Use Function::Call instead of MakeCallback to call the coverage message callback since it does not actually need async hook handling. This way we no longer needs to disable the async hooks when writing the coverage results.
  • Renames lib/internal/coverage-gen/with_profiler.js to lib/internal/profiler.js because it is now the only way to generate coverage.

test: show stderr on v8 coverage test failures

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

Merge request reports

Loading