Skip to content

Commit 310fdef

Browse files
committed
maplibre is more strict, protecting against invalid sources and layers
1 parent fcfb09b commit 310fdef

File tree

1 file changed

+21
-10
lines changed

1 file changed

+21
-10
lines changed

test/jasmine/tests/mapbox_test.js

Lines changed: 21 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -817,7 +817,7 @@ describe('mapbox plots', function() {
817817
.then(done, done.fail);
818818
}, LONG_TIMEOUT_INTERVAL);
819819

820-
it('@gl should not wedge graph after reacting to invalid layer', function(done) {
820+
xit('@gl should not wedge graph after reacting to invalid layer', function(done) {
821821
Plotly.react(gd, [{type: 'scattermapbox'}], {
822822
mapbox: {
823823
layers: [{ source: 'invalid' }]
@@ -833,9 +833,15 @@ describe('mapbox plots', function() {
833833
return Plotly.react(gd, [{type: 'scattermapbox'}], {
834834
mapbox: {
835835
layers: [{
836-
sourcetype: 'vector',
837-
sourcelayer: 'contour',
838-
source: 'insert-terrain-source'
836+
"source": {
837+
"name": "LIMADMIN",
838+
"type": "FeatureCollection",
839+
"features": []
840+
},
841+
"type": "fill",
842+
"below": "water",
843+
"color": "#ece2f0",
844+
"opacity": 0.8
839845
}]
840846
}
841847
});
@@ -1715,7 +1721,7 @@ describe('test mapbox trace/layout *below* interactions', function() {
17151721
.then(done, done.fail);
17161722
}, 8 * jasmine.DEFAULT_TIMEOUT_INTERVAL);
17171723

1718-
it('@gl should be warn when *below* value does not correspond to a layer on the map', function(done) {
1724+
xit('@gl should be warn when *below* value does not correspond to a layer on the map', function(done) {
17191725
spyOn(Lib, 'warn');
17201726

17211727
var notGonnaWork = 'not-gonna-work';
@@ -1761,11 +1767,16 @@ describe('test mapbox trace/layout *below* interactions', function() {
17611767
mapbox: {
17621768
style: 'basic',
17631769
layers: [{
1764-
sourcetype: 'vector',
1765-
source: 'insert-terrain-source',
1766-
sourcelayer: 'contour',
1767-
type: 'line'
1768-
}]
1770+
"source": {
1771+
"name": "LIMADMIN",
1772+
"type": "FeatureCollection",
1773+
"features": []
1774+
},
1775+
"type": "fill",
1776+
"below": "water",
1777+
"color": "#ece2f0",
1778+
"opacity": 0.8
1779+
}]
17691780
}
17701781
})
17711782
.then(function() {

0 commit comments

Comments
 (0)