@@ -84,7 +84,10 @@ describe('Test histogram', function() {
84
84
85
85
} ) ;
86
86
87
- it ( 'should set autobinx to false if xbins is supplied and true if not' , function ( ) {
87
+ // coercing bin attributes got moved to calc because it needs
88
+ // axis type - so here we just test that it's NOT happening
89
+
90
+ it ( 'should not coerce autobinx regardless of xbins' , function ( ) {
88
91
traceIn = {
89
92
x : [ 1 , 2 , 2 ] ,
90
93
xbins : {
@@ -94,16 +97,16 @@ describe('Test histogram', function() {
94
97
}
95
98
} ;
96
99
supplyDefaults ( traceIn , traceOut ) ;
97
- expect ( traceOut . autobinx ) . toBe ( false ) ;
100
+ expect ( traceOut . autobinx ) . toBeUndefined ( ) ;
98
101
99
102
traceIn = {
100
103
x : [ 1 , 2 , 2 ]
101
104
} ;
102
105
supplyDefaults ( traceIn , traceOut ) ;
103
- expect ( traceOut . autobinx ) . toBe ( true ) ;
106
+ expect ( traceOut . autobinx ) . toBeUndefined ( ) ;
104
107
} ) ;
105
108
106
- it ( 'should set autobiny to false if ybins is supplied and true if not ' , function ( ) {
109
+ it ( 'should not coerce autobiny regardless of ybins' , function ( ) {
107
110
traceIn = {
108
111
y : [ 1 , 2 , 2 ] ,
109
112
ybins : {
@@ -113,13 +116,13 @@ describe('Test histogram', function() {
113
116
}
114
117
} ;
115
118
supplyDefaults ( traceIn , traceOut ) ;
116
- expect ( traceOut . autobiny ) . toBe ( false ) ;
119
+ expect ( traceOut . autobiny ) . toBeUndefined ( ) ;
117
120
118
121
traceIn = {
119
122
y : [ 1 , 2 , 2 ]
120
123
} ;
121
124
supplyDefaults ( traceIn , traceOut ) ;
122
- expect ( traceOut . autobiny ) . toBe ( true ) ;
125
+ expect ( traceOut . autobiny ) . toBeUndefined ( ) ;
123
126
} ) ;
124
127
125
128
} ) ;
0 commit comments