diff --git a/test/wasi/test-return-on-exit.js b/test/wasi/test-return-on-exit.js index 362d13b490a96f..e61f4174c3d4ee 100644 --- a/test/wasi/test-return-on-exit.js +++ b/test/wasi/test-return-on-exit.js @@ -21,7 +21,8 @@ const buffer = fs.readFileSync(modulePath); // Verify that if a WASI application throws an exception, Node rethrows it // properly. const wasi = new WASI({ returnOnExit: true }); - wasi.wasiImport.proc_exit = () => { throw new Error('test error'); }; + const patchedExit = () => { throw new Error('test error'); }; + wasi.wasiImport.proc_exit = patchedExit.bind(wasi.wasiImport); const importObject = { wasi_snapshot_preview1: wasi.wasiImport }; const { instance } = await WebAssembly.instantiate(buffer, importObject); diff --git a/test/wasi/wasi.status b/test/wasi/wasi.status index 0968d131cdf2f1..12212e8f72822b 100644 --- a/test/wasi/wasi.status +++ b/test/wasi/wasi.status @@ -5,7 +5,3 @@ prefix wasi # sample-test : PASS,FLAKY [true] # This section applies to all platforms - -[$system==win32] -# https://github.com/nodejs/node/pull/36139 -test-return-on-exit: PASS,FLAKY