diff --git a/devtools/test_dashboard/server.js b/devtools/test_dashboard/server.js index 5fae32d1ddb..9dfba98dad7 100644 --- a/devtools/test_dashboard/server.js +++ b/devtools/test_dashboard/server.js @@ -74,7 +74,9 @@ function readFiles(files) { function createMocksList(files) { // eliminate pollutants (e.g .DS_Store) that can accumulate in the mock directory - var jsonFiles = files.filter(function(file) {return file.extname === '.json';}); + var jsonFiles = files.filter(function(file) { + return file.name.substr(-5) === '.json'; + }); var mocksList = jsonFiles.map(function(file) { var contents = JSON.parse(file.contents);