We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 89d16de commit 0e23045Copy full SHA for 0e23045
test/jasmine/tests/mapbox_test.js
@@ -55,6 +55,24 @@ describe('mapbox defaults', function() {
55
expect(layoutOut.mapbox._input).toBe(mapbox);
56
});
57
58
+ it('should accept both string and object style', function() {
59
+ var mapboxStyleJSON = {
60
+ id: 'cdsa213wqdsa',
61
+ owner: 'johnny'
62
+ };
63
+
64
+ layoutIn = {
65
+ mapbox: { style: 'light' },
66
+ mapbox2: { style: mapboxStyleJSON }
67
68
69
+ fullData.push({ type: 'scattermapbox', subplot: 'mapbox2' });
70
71
+ supplyLayoutDefaults(layoutIn, layoutOut, fullData);
72
+ expect(layoutOut.mapbox.style).toEqual('light');
73
+ expect(layoutOut.mapbox2.style).toBe(mapboxStyleJSON);
74
+ });
75
76
it('should fill layer containers', function() {
77
layoutIn = {
78
mapbox: {
0 commit comments