json-schema-ref-parser icon indicating copy to clipboard operation
json-schema-ref-parser copied to clipboard

Replace deprecated resolve function

Open neosat55 opened this issue 4 years ago • 3 comments

Fix for #239

neosat55 avatar Jul 06 '21 13:07 neosat55

Thank you for this pull request! If this has solved the casing issue mentioned in the issue, could you add a test case providing that?

philsturgeon avatar Aug 01 '21 06:08 philsturgeon

HI, thanks for your response! I had to rewrite some tests in resolvers module for work with uppercase symbols, and i added new one, that check is file.url returned as it's written

neosat55 avatar Aug 14 '21 16:08 neosat55

We've got an error happening here:

   File names with special characters
    1) should parse successfully


  0 passing (9ms)
  1 failing

  1) File names with special characters
       should parse successfully:
     TypeError [ERR_INVALID_URL]: Invalid URL: specs/__(%7B%5B%20%25%20&%20$%20%23%20@%20%60%20~%20,)%7D%5D__/__(%7B%5B%20%25%20&%20$%20%23%20@%20%60%20~%20,)%7D%5D__.yaml
      at onParseError (internal/url.js:258:9)
      at new URL (internal/url.js:334:5)
      at Object.resolve (lib\util\url.js:8:136)
      at $RefParser.parse (lib\index.js:46:39)
      at Context.<anonymous> (test\specs\__({[ % & $ # @ ` ~ ,)}]__\special-characters.spec.js:13:33)
      at processImmediate (internal/timers.js:461:21)


If its not connected to your test is there any chance you can take a swing at it anyway? 😇

philsturgeon avatar May 10 '22 22:05 philsturgeon