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

simonbrunel
Copy link
Member

@simonbrunel 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.

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).
@etimberg
Copy link
Member

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
@simonbrunel simonbrunel deleted the chore/js-test-fixture branch October 20, 2018 09:38
exwm pushed a commit to exwm/Chart.js that referenced this pull request Apr 30, 2021
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).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants