test: skip test depending on overlapped-checker when not available

PR-URL: https://github.com/nodejs/node/pull/45015
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
Antoine du Hamel authored and Danielle Adams committed 2023-01-03 08:38:11 -05:00
1 parent 5544c55600
commit d103d779d3
1 file changed
+4
@@ -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']
});