From: Jukka Kurkela Date: Tue, 21 Jan 2020 20:44:14 +0000 (+0200) Subject: Enable imports for tests (#6997) X-Git-Tag: v3.0.0-alpha~108 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=14df2c6722ea521a57ceceadb75dade7d100ae34;p=thirdparty%2FChart.js.git Enable imports for tests (#6997) --- diff --git a/karma.conf.js b/karma.conf.js index a89d3fba2..209470e0e 100644 --- a/karma.conf.js +++ b/karma.conf.js @@ -59,6 +59,7 @@ module.exports = function(karma) { ].concat((args.inputs || 'test/specs/**/*.js').split(';')), preprocessors: { + 'test/specs/**/*.js': ['rollup'], 'test/index.js': ['rollup'], 'src/index.js': ['sources'] }, diff --git a/test/specs/helpers.math.tests.js b/test/specs/helpers.math.tests.js index 66c00df63..1133a00e1 100644 --- a/test/specs/helpers.math.tests.js +++ b/test/specs/helpers.math.tests.js @@ -1,8 +1,8 @@ 'use strict'; +import * as math from '../../src/helpers/helpers.math'; describe('Chart.helpers.math', function() { - var math = Chart.helpers.math; var factorize = math._factorize; var decimalPlaces = math._decimalPlaces;