diff --git a/test/parallel/test-whatwg-url-parsing.js b/test/parallel/test-whatwg-url-parsing.js index df2db4881374fd..00fedbde1b0c62 100644 --- a/test/parallel/test-whatwg-url-parsing.js +++ b/test/parallel/test-whatwg-url-parsing.js @@ -36,7 +36,7 @@ for (const test of failureTests) { return false; // The input could be processed, so we don't do strict matching here - const match = (error + '').match(/Invalid URL: (.*)$/); + const match = (`${error}`).match(/Invalid URL: (.*)$/); if (!match) { return false; }