diff --git a/test/parallel/test-path-resolve.js b/test/parallel/test-path-resolve.js index 859b1d1e52489d..7fea7f56aae91e 100644 --- a/test/parallel/test-path-resolve.js +++ b/test/parallel/test-path-resolve.js @@ -12,7 +12,7 @@ const backslashRE = /\\/g; const posixyCwd = common.isWindows ? (() => { const _ = process.cwd() - .replace(new RegExp(`\\${path.sep}`, 'g'), path.posix.sep); + .replaceAll(path.sep, path.posix.sep); return _.substr(_.indexOf(path.posix.sep)); })() : process.cwd();