Skip to content

Commit d338058

Browse files
committed
revert gl3d layout test
1 parent 5b24f51 commit d338058

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

src/plots/gl3d/layout/defaults.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ function handleGl3dDefaults(sceneLayoutIn, sceneLayoutOut, coerce, opts) {
115115

116116
if(!x || !y || !z) {
117117
enableTurnTable();
118-
} else if(z / Math.sqrt(x*x + y*y + z*z) > 0.999) {
118+
} else if(z / Math.sqrt(x * x + y * y + z * z) > 0.999) {
119119
enableTurnTable();
120120
}
121121
} else {

test/jasmine/tests/gl3dlayout_test.js

+8-8
Original file line numberDiff line numberDiff line change
@@ -168,33 +168,33 @@ describe('Test Gl3d layout defaults', function() {
168168
layoutIn = { scene: {} };
169169
supplyLayoutDefaults(layoutIn, layoutOut, fullData);
170170
expect(layoutOut.scene.dragmode)
171-
.toBe('orbit', 'to orbit by default');
171+
.toBe('turntable', 'to turntable by default');
172172

173-
layoutIn = { scene: { dragmode: 'turntable' } };
173+
layoutIn = { scene: { dragmode: 'orbit' } };
174174
supplyLayoutDefaults(layoutIn, layoutOut, fullData);
175175
expect(layoutOut.scene.dragmode)
176-
.toBe('turntable', 'to user val if valid');
176+
.toBe('orbit', 'to user val if valid');
177177

178-
layoutIn = { scene: {}, dragmode: 'turntable' };
178+
layoutIn = { scene: {}, dragmode: 'orbit' };
179179
supplyLayoutDefaults(layoutIn, layoutOut, fullData);
180180
expect(layoutOut.scene.dragmode)
181-
.toBe('turntable', 'to user layout val if valid and 3d only');
181+
.toBe('orbit', 'to user layout val if valid and 3d only');
182182

183183
layoutIn = { scene: {}, dragmode: 'invalid' };
184184
supplyLayoutDefaults(layoutIn, layoutOut, fullData);
185185
expect(layoutOut.scene.dragmode)
186-
.toBe('orbit', 'to orbit if invalid and 3d only');
186+
.toBe('turntable', 'to turntable if invalid and 3d only');
187187

188188
layoutIn = { scene: {}, dragmode: 'orbit' };
189189
layoutOut._basePlotModules.push({ name: 'cartesian' });
190190
supplyLayoutDefaults(layoutIn, layoutOut, fullData);
191191
expect(layoutOut.scene.dragmode)
192-
.toBe('orbit', 'to default if not 3d only');
192+
.toBe('turntable', 'to default if not 3d only');
193193

194194
layoutIn = { scene: {}, dragmode: 'not gonna work' };
195195
supplyLayoutDefaults(layoutIn, layoutOut, fullData);
196196
expect(layoutOut.scene.dragmode)
197-
.toBe('orbit', 'to default if not valid');
197+
.toBe('turntable', 'to default if not valid');
198198
});
199199

200200
it('should coerce hovermode', function() {

0 commit comments

Comments
 (0)