-
-
Notifications
You must be signed in to change notification settings - Fork 33.7k
test_runner: expose reporter for use in run api #47238
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test_runner: expose reporter for use in run api #47238
Conversation
|
Review requested:
|
|
Isn't this going to reintroduce the same problem as #46061 (comment) |
|
@cjihrig so would the addition of any core modules; see #46061 (comment) and #46061 (comment) |
benjamingr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code lgtm. All anonrig's suggestions look good to me too.
yeah but as @ljharb mentioned this is desired and will require fixing |
| let spec; | ||
| let tap; | ||
|
|
||
| ObjectDefineProperties(module.exports, { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are we sure that cjs-module-lexer will be able to pick up this pattern as named exports?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it is a pretty common pattern in node's built-in modules, so it probably does:
Line 340 in 9dbb162
| ObjectDefineProperties(module.exports, { |
Line 1392 in 9dbb162
| ObjectDefineProperties(module.exports, { |
Line 345 in 9dbb162
| ObjectDefineProperties(module.exports, { |
Line 399 in 9dbb162
| ObjectDefineProperties(module.exports, { |
Line 926 in 9dbb162
| ObjectDefineProperties(module.exports, { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It probably doesn’t but we don’t use cjs-module-lexer for core modules, because core modules are not CJS (or at least, not regular CJS) and the use of named imports for core modules predates the introduction of cjs-module-lexer.
|
Landed in 29d7aec |
Fixes: #47231