ft-interactive / visual-vocabulary-templates

Library of chart templates based on the visual vocabulary
http://ft-interactive.github.io/visual-vocabulary-templates/
77 stars 11 forks source link

Fixes #130, adds automated regression testing #131

Closed aendra-rininsland closed 6 years ago

aendra-rininsland commented 6 years ago

After I broke five charts with replacing parseData.fromCSV with parseData.load (which this PR fixes), I figured it wouldn't be the worst idea to add some very light regression testing to ensure that templates don't throw exceptions out of the gate.

The test running sets up a mini server and then uses headless Chrome to load each template in serial, waits until no further requests are being made by the browser, then passes if no resource or JS errors are thrown. This only gets run by CircleCI, meaning we get little badges telling us whether it passed or not, and we can investigate when PRs fail.