Skip to content

Conversation

jonasongg
Copy link
Contributor

fixes #15077

Copy link

linux-foundation-easycla bot commented Feb 20, 2025

CLA Signed

The committers listed above are authorized under a signed CLA.

Copy link

netlify bot commented Feb 20, 2025

Deploy Preview for jestjs ready!

Name Link
🔨 Latest commit c71a8c9
🔍 Latest deploy log https://app.netlify.com/sites/jestjs/deploys/67b82be52288a8000893497d
😎 Deploy Preview https://deploy-preview-15517--jestjs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@SimenB
Copy link
Member

SimenB commented Feb 20, 2025

Thanks for the PR! Mind adding a test that covers the bug as well?

@jonasongg jonasongg changed the title fix: refactor _importCoreModel so required core module is consistent fix: refactor _importCoreModule so required core module is consistent Feb 20, 2025
@jonasongg
Copy link
Contributor Author

@SimenB Given the original bug's flakiness, is it a good idea to test the private method _importCoreModule? Apologies for my unfamiliarity with the codebase - if you could point me in a general direction to go ahead with the testing?

Copy link
Member

@SimenB SimenB left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was thinking we could do an integration test where we add a property to a node core module while it's loading, but I think it'd be fiddly as we cache the module, so we'd have to do something in parallel and somehow time it right. Doesn't sound like a stable test at all, so let's ship this as-is 👍

@SimenB SimenB merged commit f4246f3 into jestjs:main Feb 21, 2025
5 checks passed
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 24, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: ReferenceError: Export 'emit' is not defined in module from Jest internals during suite setup.
2 participants