From 69512631772e8de27dbb8e0856b7d0696bafbb84 Mon Sep 17 00:00:00 2001 From: Antoine du Hamel Date: Sat, 15 Oct 2022 16:27:17 -0500 Subject: [PATCH] test: skip test depending on `overlapped-checker` when not available PR-URL: https://github.com/nodejs/node/pull/45015 Reviewed-By: Rafael Gonzaga Reviewed-By: Yagiz Nizipli Reviewed-By: Colin Ihrig Reviewed-By: Luigi Pinca --- test/parallel/test-child-process-stdio-overlapped.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/parallel/test-child-process-stdio-overlapped.js b/test/parallel/test-child-process-stdio-overlapped.js index 70a6454ff8fc9a..5c48e7ee105792 100644 --- a/test/parallel/test-child-process-stdio-overlapped.js +++ b/test/parallel/test-child-process-stdio-overlapped.js @@ -33,6 +33,10 @@ const exeExtension = process.platform === 'win32' ? '.exe' : ''; const exe = 'overlapped-checker' + exeExtension; const exePath = path.join(path.dirname(process.execPath), exe); +if (!require('fs').existsSync(exePath)) { + common.skip(exe + ' binary is not available'); +} + const child = child_process.spawn(exePath, [], { stdio: ['overlapped', 'pipe', 'pipe'] });