diff options
author | Lauren Budorick <lauren@mapbox.com> | 2017-08-23 18:21:05 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-08-23 18:21:05 -0700 |
commit | 57d87e8ef2ad2d1f594468e5e204cfc21c536327 (patch) | |
tree | a36d8019e587c0331a76ae08d4a06f46da7777b2 /platform/node/test/suite_implementation.js | |
parent | f2c9f2bf3695fc30579a40978ebda9d87e4b4bcd (diff) | |
download | qtlocation-mapboxgl-57d87e8ef2ad2d1f594468e5e204cfc21c536327.tar.gz |
Update ignores + suite_implementation
Diffstat (limited to 'platform/node/test/suite_implementation.js')
-rw-r--r-- | platform/node/test/suite_implementation.js | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/platform/node/test/suite_implementation.js b/platform/node/test/suite_implementation.js index b717ecd2b2..261de632e7 100644 --- a/platform/node/test/suite_implementation.js +++ b/platform/node/test/suite_implementation.js @@ -72,12 +72,16 @@ module.exports = function (style, options, callback) { } else if (operation[0] === 'addImage' || operation[0] === 'updateImage') { var img = PNG.sync.read(fs.readFileSync(path.join(__dirname, '../../../mapbox-gl-js/test/integration', operation[2]))); + const testOpts = (operation.length > 3) ? operation[3] : {}; - map.addImage(operation[1], img.data, { + const options = { height: img.height, width: img.width, - pixelRatio: operation[3] || 1 - }); + pixelRatio: testOpts.pixelRatio || 1, + sdf: testOpts.sdf || false + } + + map.addImage(operation[1], img.data, options); applyOperations(operations.slice(1), callback); |