-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Fixes #4665. make "-r <dir>" work with new import-first loading #4668
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@giltayar could there be more cases |
@juergba I can check, but this is only for test files and |
juergba
added
type: bug
a defect, confirmed by a maintainer
area: node.js
command-line-or-Node.js-specific
semver-patch
implementation requires increase of "patch" version number; "bug fixes"
labels
Jun 26, 2021
4 tasks
juergba
reviewed
Jun 26, 2021
test/integration/fixtures/esm/test-that-uses-dir-cjs-require.fixture.js/index.js
Show resolved
Hide resolved
juergba
added
the
run-browser-test
run browser tests on forked PR if code is safe
label
Jun 28, 2021
github-actions
bot
removed
the
run-browser-test
run browser tests on forked PR if code is safe
label
Jun 28, 2021
juergba
approved these changes
Jun 28, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area: node.js
command-line-or-Node.js-specific
semver-patch
implementation requires increase of "patch" version number; "bug fixes"
type: bug
a defect, confirmed by a maintainer
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of the Change
When falling back on CJS when loading test files, ensure that
ERR_UNSUPPORTED_DIR_IMPORT
is supported so that-r <cjs-package>/dir
will work. See #4665 for a more detailed description.Benefits
This is a bug fix to return support to what was before enabled.
Possible Drawbacks
None
Applicable issues
#4665
Mocha follows semantic versioning: http://semver.org
Is this a breaking change (major release)? No
Is it an enhancement (minor release)? No
Is it a bug fix, or does it not impact production code (patch release)? Yes