chore: improve assertion with expected path#4474
Merged
baileympearson merged 7 commits intomainfrom Mar 19, 2025
Merged
Conversation
1541409 to
30a4d63
Compare
72b19a7 to
4bf1384
Compare
baileympearson
suggested changes
Mar 19, 2025
Contributor
baileympearson
left a comment
There was a problem hiding this comment.
assertion is much more actionable:
AssertionError: Expected actual ({ _id: 1, time: 2019-03-18T22:53:50.482Z }) to be an array at: events[2].commandStartedEvent.command.documents[0]: expected { _id: 1, time: 2019-03-18T22:53:50.482Z } to satisfy [Function]
baileympearson
approved these changes
Mar 19, 2025
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.
Description
What is changing?
Is there new documentation needed for these changes?
What is the motivation for this change?
A test failed and it isn't clear what part of the expectation wasn't an object.
https://spruce.mongodb.com/task/mongo_node_driver_next_rhel80_large_Node20_test_7.0_sharded_cluster_91d235221cc42a49bcfa85e428f83d8e6ba258d0_75c01e57abc470e785838d3c6dd0a8c0_25_03_18_15_22_09/logs?execution=0&sortBy=STATUS&sortDir=ASC
Double check the following
npm run check:lintscripttype(NODE-xxxx)[!]: descriptionfeat(NODE-1234)!: rewriting everything in coffeescript