Skip to content

Commit 4c8ca52

Browse files
committed
Use constants in ES5 test
1 parent 069437f commit 4c8ca52

File tree

1 file changed

+3
-13
lines changed

1 file changed

+3
-13
lines changed

tasks/test_syntax.js

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -202,20 +202,10 @@ function assertES5() {
202202
}
203203
});
204204

205-
// Filter out min and plotly-geo-assets.js since one is unnecessary
206-
// and the other is super slow:
207-
var files = fs.readdirSync(path.join(__dirname, '../dist'));
208-
var validFiles = [];
209-
for(var i = 0; i < files.length; i++) {
210-
var f = files[i];
211-
var isMin = !/[^(min)]\.js$/.test(f);
212-
var isGeo = /geo-assets/.test(f);
213-
if(!isMin && !isGeo) {
214-
validFiles.push(path.join(__dirname, '../dist', f));
215-
}
216-
}
205+
var files = constants.partialBundlePaths.map(function(f) { return f.dist; });
206+
files.unshift(constants.pathToPlotlyDist);
217207

218-
var report = cli.executeOnFiles(validFiles);
208+
var report = cli.executeOnFiles(files);
219209
var formatter = cli.getFormatter();
220210

221211
var errors = [];

0 commit comments

Comments
 (0)