puppetlabs-stdlib icon indicating copy to clipboard operation
puppetlabs-stdlib copied to clipboard

Rewrite loadjson to use the modern function API

Open ekohl opened this issue 2 years ago • 0 comments

Summary

This also resolves a bug where JSON.parse returned a StringIO. To properly catch this, the tests are rewritten to avoid mocking where possible. Exceptions are with external URLs and where a failure is expected.

Related Issues (if any)

Fixes #1414

Checklist

  • [x] 🟢 Spec tests.
  • [ ] 🟢 Acceptance tests.
  • [ ] Manually verified. (For example puppet apply)

ekohl avatar Dec 23 '23 18:12 ekohl