[build] Use test-suite integration tests from mapbox-gl-js

This commit is contained in:
John Firebaugh
2017-01-09 15:32:03 -08:00
parent f6f82d15ab
commit 9f9e820540
7 changed files with 8 additions and 6 deletions

View File

@@ -14,6 +14,9 @@ if(NOT EXISTS "mapbox-gl-js/package.json")
execute_process(
COMMAND git submodule update --init mapbox-gl-js
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})
execute_process(
COMMAND npm install
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/mapbox-gl-js)
endif()
include(.mason/mason.cmake)

View File

@@ -23,7 +23,6 @@
"express": "^4.11.1",
"lodash": "^4.16.4",
"mapbox-gl-style-spec": "mapbox/mapbox-gl-style-spec#49e8b407bdbbe6f7c92dbcb56d3d51f425fc2653",
"mapbox-gl-test-suite": "mapbox/mapbox-gl-test-suite#9ab19437e6a5272f1dfd7aaf12a7b5bbec208895",
"mkdirp": "^0.5.1",
"node-cmake": "^1.2.1",
"pixelmatch": "^4.0.2",

View File

@@ -6,7 +6,7 @@ set -o pipefail
JOB=$1
if [ ! -z "${AWS_ACCESS_KEY_ID}" ] && [ ! -z "${AWS_SECRET_ACCESS_KEY}" ] ; then
gzip --stdout node_modules/mapbox-gl-test-suite/render-tests/index.html | \
gzip --stdout mapbox-gl-js/test/integration/render-tests/index.html | \
aws s3 cp --acl public-read --content-encoding gzip --content-type text/html \
- s3://mapbox/mapbox-gl-native/render-tests/$JOB/index.html

View File

@@ -1,6 +1,6 @@
'use strict';
var suite = require('mapbox-gl-test-suite').query;
var suite = require('../../../mapbox-gl-js/test/integration').query;
var suiteImplementation = require('./suite_implementation');
var tests;

View File

@@ -1,6 +1,6 @@
'use strict';
var suite = require('mapbox-gl-test-suite').render;
var suite = require('../../../mapbox-gl-js/test/integration').render;
var suiteImplementation = require('./suite_implementation');
var tests;

View File

@@ -69,7 +69,7 @@ module.exports = function (style, options, callback) {
});
} else if (operation[0] === 'addImage') {
var img = PNG.sync.read(fs.readFileSync(path.join(__dirname, '../../../node_modules', 'mapbox-gl-test-suite', operation[2])));
var img = PNG.sync.read(fs.readFileSync(path.join(__dirname, '../../../mapbox-gl-js/test/integration', operation[2])));
map.addImage(operation[1], img.data, {
height: img.height,