Skip to content

Commit

Permalink
test: deflake test-trace-atomics-wait
Browse files Browse the repository at this point in the history
Add possible outcome to the `expectedTimelines` array.

Fixes: nodejs#41010

PR-URL: nodejs#41018
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
lpinca authored and Linkgoron committed Jan 31, 2022
1 parent e281fa3 commit cb0f974
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/parallel/test-trace-atomics-wait.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,12 @@ values mismatched
[Thread 1] Atomics.wait(<address> + 4, -1, inf) started
[Thread 1] Atomics.wait(<address> + 4, -1, inf) did not wait because the \
values mismatched`,
`${begin}
[Thread 1] Atomics.wait(<address> + 4, -1, inf) started
[Thread 0] Atomics.wait(<address> + 4, 0, inf) started
[Thread 0] Atomics.wait(<address> + 4, 0, inf) did not wait because the \
values mismatched
[Thread 1] Atomics.wait(<address> + 4, -1, inf) was woken up by another thread`,
];

assert(expectedTimelines.includes(actualTimeline));

0 comments on commit cb0f974

Please sign in to comment.