mirror of
https://github.com/chartjs/Chart.js.git
synced 2026-03-14 04:06:49 +01:00
Make test Context an ES6 module (#7142)
* Make test Context an ES6 module * Address comments
This commit is contained in:
@@ -68,7 +68,7 @@ module.exports = function(karma) {
|
||||
plugins: [
|
||||
resolve(),
|
||||
babel({exclude: 'node_modules/**'}), // use babel since we have ES proposal features
|
||||
commonjs()
|
||||
commonjs({exclude: ['src/**', 'test/**']})
|
||||
],
|
||||
output: {
|
||||
name: 'test',
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Code from https://stackoverflow.com/questions/4406864/html-canvas-unit-testing
|
||||
var Context = function() {
|
||||
const Context = function() {
|
||||
this._calls = []; // names/args of recorded calls
|
||||
this._initMethods();
|
||||
|
||||
@@ -136,4 +136,4 @@ Context.prototype.resetCalls = function() {
|
||||
this._calls = [];
|
||||
};
|
||||
|
||||
module.exports = Context;
|
||||
export default Context;
|
||||
|
||||
Reference in New Issue
Block a user