Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for *.js test fixture config #5777

Merged
merged 1 commit into from Oct 20, 2018

Conversation

2 participants
@simonbrunel
Copy link
Member

simonbrunel commented Oct 19, 2018

JSON doesn't support functions which are needed to create scriptable options, so implement a very basic method to load a JavaScript file exporting the config in module.exports. Also rename test sources (remove the jasmine. prefix), cleanup karma.conf.js and add an example .js fixture config (bubble radius option).

This is similar to what we have in the chartjs-plugin-datalabels repository, except that we don't rely on es6 modules.

Add support for *.js test fixture config
JSON doesn't support functions which are needed to create scriptable options, so implement a very basic method to load a JavaScript file exporting the config in `module.exports`. Also rename test sources (remove the `jasmine.` prefix), cleanup `karma.conf.js` and add an example .js fixture config (bubble radius option).

@simonbrunel simonbrunel added this to the Version 2.8 milestone Oct 19, 2018

@simonbrunel simonbrunel requested review from benmccann and etimberg Oct 19, 2018

@etimberg

This comment has been minimized.

Copy link
Member

etimberg commented Oct 19, 2018

We should make sure to get back to this once we have ES6 modules in so that we can improve it

@simonbrunel simonbrunel merged commit 2dbf1cd into chartjs:master Oct 20, 2018

3 checks passed

codeclimate All good!
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
coverage/coveralls Coverage remained the same at 95.289%
Details

@simonbrunel simonbrunel deleted the simonbrunel:chore/js-test-fixture branch Oct 20, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.