@@ -171,7 +171,7 @@ describe('Bar.supplyDefaults', function() {
171171 } ) ;
172172} ) ;
173173
174- describe ( 'bar calc / setPositions' , function ( ) {
174+ describe ( 'bar calc / crossTraceCalc (formally known as setPositions) ' , function ( ) {
175175 'use strict' ;
176176
177177 it ( 'should fill in calc pt fields (stack case)' , function ( ) {
@@ -337,7 +337,7 @@ describe('Bar.calc', function() {
337337 } ) ;
338338} ) ;
339339
340- describe ( 'Bar.setPositions' , function ( ) {
340+ describe ( 'Bar.crossTraceCalc (formally known as setPositions) ' , function ( ) {
341341 'use strict' ;
342342
343343 it ( 'should guard against invalid offset items' , function ( ) {
@@ -1347,9 +1347,9 @@ describe('bar visibility toggling:', function() {
13471347 expect ( fullLayout . xaxis . range ) . toBeCloseToArray ( xrng , 2 , msg + ' xrng' ) ;
13481348 expect ( fullLayout . yaxis . range ) . toBeCloseToArray ( yrng , 2 , msg + ' yrng' ) ;
13491349
1350- var setPositions = gd . _fullData [ 0 ] . _module . setPositions ;
1351- expect ( setPositions ) . toHaveBeenCalledTimes ( calls ) ;
1352- setPositions . calls . reset ( ) ;
1350+ var crossTraceCalc = gd . _fullData [ 0 ] . _module . crossTraceCalc ;
1351+ expect ( crossTraceCalc ) . toHaveBeenCalledTimes ( calls ) ;
1352+ crossTraceCalc . calls . reset ( ) ;
13531353 }
13541354
13551355 it ( 'should update axis range according to visible edits (group case)' , function ( done ) {
@@ -1358,7 +1358,7 @@ describe('bar visibility toggling:', function() {
13581358 { type : 'bar' , x : [ 1 , 2 , 3 ] , y : [ - 1 , - 2 , - 1 ] }
13591359 ] )
13601360 . then ( function ( ) {
1361- spyOn ( gd . _fullData [ 0 ] . _module , 'setPositions ' ) . and . callThrough ( ) ;
1361+ spyOn ( gd . _fullData [ 0 ] . _module , 'crossTraceCalc ' ) . and . callThrough ( ) ;
13621362
13631363 _assert ( 'base' , [ 0.5 , 3.5 ] , [ - 2.222 , 2.222 ] , 0 ) ;
13641364 return Plotly . restyle ( gd , 'visible' , false , [ 1 ] ) ;
@@ -1388,7 +1388,7 @@ describe('bar visibility toggling:', function() {
13881388 { type : 'bar' , x : [ 1 , 2 , 3 ] , y : [ 2 , 3 , 2 ] }
13891389 ] , { barmode : 'stack' } )
13901390 . then ( function ( ) {
1391- spyOn ( gd . _fullData [ 0 ] . _module , 'setPositions ' ) . and . callThrough ( ) ;
1391+ spyOn ( gd . _fullData [ 0 ] . _module , 'crossTraceCalc ' ) . and . callThrough ( ) ;
13921392
13931393 _assert ( 'base' , [ 0.5 , 3.5 ] , [ 0 , 5.263 ] , 0 ) ;
13941394 return Plotly . restyle ( gd , 'visible' , false , [ 1 ] ) ;
@@ -1806,8 +1806,8 @@ function mockBarPlot(dataWithoutTraceType, layout) {
18061806 yaxis : gd . _fullLayout . yaxis
18071807 } ;
18081808
1809- // call Bar.setPositions
1810- Bar . setPositions ( gd , plotinfo ) ;
1809+ // call Bar.crossTraceCalc
1810+ Bar . crossTraceCalc ( gd , plotinfo ) ;
18111811
18121812 return gd ;
18131813}
0 commit comments