mbanting / metalsmith-prismic

A Metalsmith.io plugin to pull in content from Prismic.io
MIT License
48 stars 19 forks source link

Update tests to pass again #39

Open mbanting opened 6 years ago

mbanting commented 6 years ago

The current test suite was written to test against Prismic's old "Les Bonne Choses" content repo. I liked the idea of testing against a live repo instead of local mocked data because the mocks could easily get out of date. Unfortunately, Prismic removed that repo over a year ago resulting in the tests to fail.

I've put in a request to resurrect the repo, but Prismic is suggesting switching to local mocks instead. Either way, I'll work on getting the tests to pass once again, before undertaking any serious refactoring in this package.

mbanting commented 6 years ago

As suggested by Prismic, I can mock the API response like their tests: https://github.com/prismicio/prismic-javascript/blob/master/test/api.js