fix: corrected stubbing errors in tests @W-21178947@#1288
Merged
jfeingold35 merged 2 commits intomainfrom Mar 4, 2026
Merged
Conversation
jfeingold35
commented
Mar 3, 2026
| it('shows no plugins installed', async () => { | ||
| it('when no plugins installed, says so', async () => { | ||
| const config = await Config.load(import.meta.url) | ||
| sinon.stub(config, 'getPluginsList').returns([]) |
Contributor
Author
There was a problem hiding this comment.
Stubbing an empty array didn't seem to actually do anything functionally, and was just causing the tests to explode, so I just got rid of it. All of the other tests include the existing plugin list anyway, so it follows that this one should do so as well.
jfeingold35
commented
Mar 4, 2026
| "husky": "^9.1.7", | ||
| "lint-staged": "^15.5.2", | ||
| "mocha": "^10.8.2", | ||
| "mocha": "^11", |
Contributor
Author
There was a problem hiding this comment.
The dependency on mocha@^10 causes tests to fail on node v25, because one of the libraries uses require instead of import and that's somehow a problem. Bumping to v11 resolves this.
iowillhoit
approved these changes
Mar 4, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This PR is necessary for us to be able to merge core PR #1549. The stubbing in some of the tests here was insufficient to mimic a plugin, in ways that were previously not a problem but are now a problem thanks to the changes made in the core PR. So in order for those tests to pass, these tests need to be updated.