@@ -16,7 +16,7 @@ if (!process.env.HAS_STARTED_WORKER) {
16
16
// Normalize the current working dir to also work with the root folder.
17
17
process . chdir ( __dirname ) ;
18
18
19
- assert ( ! process . cwd . toString ( ) . includes ( 'Atomics.load' ) ) ;
19
+ assert . doesNotMatch ( process . cwd . toString ( ) , / A t o m i c s L o a d / ) ;
20
20
21
21
// 1. Start the first worker.
22
22
const w = new Worker ( __filename ) ;
@@ -32,7 +32,7 @@ if (!process.env.HAS_STARTED_WORKER) {
32
32
// 2. Save the current cwd and verify that `process.cwd` includes the
33
33
// Atomics.load call and spawn a new worker.
34
34
const cwd = process . cwd ( ) ;
35
- assert ( process . cwd . toString ( ) . includes ( 'Atomics.load' ) ) ;
35
+ assert . match ( process . cwd . toString ( ) , / A t o m i c s L o a d / ) ;
36
36
37
37
const w = new Worker ( __filename ) ;
38
38
w . once ( 'message' , common . mustCall ( ( message ) => {
@@ -56,7 +56,7 @@ if (!process.env.HAS_STARTED_WORKER) {
56
56
const cwd = process . cwd ( ) ;
57
57
// Send the current cwd to the parent.
58
58
parentPort . postMessage ( cwd ) ;
59
- assert ( process . cwd . toString ( ) . includes ( 'Atomics.load' ) ) ;
59
+ assert . match ( process . cwd . toString ( ) , / A t o m i c s L o a d / ) ;
60
60
61
61
parentPort . once ( 'message' , common . mustCall ( ( message ) => {
62
62
// 7. Verify that the current cwd is identical to the received one but
0 commit comments