diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2017-07-19 13:28:42 -0700 |
---|---|---|
committer | John Firebaugh <john.firebaugh@gmail.com> | 2017-07-24 15:19:15 -0700 |
commit | ed29dfce436cb68c91fa2a1bdaa995124121c218 (patch) | |
tree | 89ed6373bb60bf24e23e8f50ab59ae3a593714f0 /platform/node/test/mockfs.js | |
parent | 5ee05a7781396004cb617002b6cbe8b7402616a6 (diff) | |
download | qtlocation-mapboxgl-ed29dfce436cb68c91fa2a1bdaa995124121c218.tar.gz |
[node] Rewrite request tests
Diffstat (limited to 'platform/node/test/mockfs.js')
-rw-r--r-- | platform/node/test/mockfs.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/platform/node/test/mockfs.js b/platform/node/test/mockfs.js index dfa5a425e3..2d27f3bbbe 100644 --- a/platform/node/test/mockfs.js +++ b/platform/node/test/mockfs.js @@ -5,7 +5,7 @@ var path = require('path'); function readFixture(file) { return fs.readFileSync(path.join('test/fixtures/resources', file)); -}; +} var style_raster = readFixture('style_raster.json').toString('utf8'); var style_vector = readFixture('style_vector.json').toString('utf8'); @@ -18,7 +18,7 @@ var tile_raster = readFixture('raster.tile'); var tile_vector = readFixture('vector.tile'); function dataForRequest(req) { - if (req.url == null) { + if (req.url === null) { return null; } else if (req.url.indexOf('sprite') > -1 && req.url.endsWith('json')) { return sprite_json; @@ -37,7 +37,7 @@ function dataForRequest(req) { } else { return null; } -}; +} module.exports = { dataForRequest: dataForRequest, |