test(node): Fix flaky worker thread integration test#20588
Conversation
| const threadValues = event.threads?.values ?? []; | ||
| expect(threadValues).toHaveLength(2); | ||
| // Any order is fine, we just check that both are present | ||
| expect(threadValues).toContainEqual( |
There was a problem hiding this comment.
q: Is there a specific reason why this one got outsourced into its own expect? expect.objectContaining would have worked above as well if I'm not mistaken
There was a problem hiding this comment.
I personally don't like how these nested contains things are visualized when they fail - I always have a hard time finding out what is actually not matching. I find this easier to parse when it fails, but this is more a personal preference :D functionally that also worked fine, yes!
size-limit report 📦
|
Fixes #20571