Skip to content

Commit

Permalink
test_runner: expose lcov reporter as newable function
Browse files Browse the repository at this point in the history
This commit exposes the lcov reporter as a newable function, so that it
can be used in the same way as the other reporters.
This will allow passing in the options to the reporter as well.
This breaks the current behavior of the lcov reporter, which exposes an
instance of the reporter.

Fixes: #52385
Ref: #49184
PR-URL: #52403
Refs: #49184
Reviewed-By: Benjamin Gruenbaum <[email protected]>
Reviewed-By: Moshe Atlow <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
  • Loading branch information
atlowChemi authored and aduh95 committed Apr 30, 2024
1 parent 8e4fd28 commit df1080e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/test/reporters.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ ObjectDefineProperties(module.exports, {
__proto__: null,
configurable: true,
enumerable: true,
get() {
value: function value() {
lcov ??= require('internal/test_runner/reporter/lcov');
return ReflectConstruct(lcov, arguments);
},
Expand Down

0 comments on commit df1080e

Please sign in to comment.