File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
packages/python/plotly/plotly
tests/test_core/test_subplots Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -640,7 +640,7 @@ def _checks(item, defaults):
640
640
# Check to see that number of rows and columns does not conflict with
641
641
# requested vertical_spacing and horizontal_spacing
642
642
def _check_row_col_spacing (n , spacing ):
643
- if (n > 1 ) and (spacing > (1 / (n - 1 ))):
643
+ if (n > 1 ) and (spacing > (1.0 / (n - 1 ))):
644
644
return False
645
645
return True
646
646
Original file line number Diff line number Diff line change @@ -116,15 +116,15 @@ def test_row_width_not_list_of_correct_numbers(self):
116
116
117
117
def test_bad_row_spacing (self ):
118
118
with self .assertRaises (ValueError ) as cm :
119
- tls .make_subplots (rows = 3 , vertical_spacing = 1 / 2 + 1e-6 )
119
+ tls .make_subplots (rows = 3 , vertical_spacing = 1.0 / 2.0 + 1e-6 )
120
120
assert (
121
121
cm .exception .args [0 ]
122
122
== "Vertical spacing must be less than or equal to 1 / (rows - 1)."
123
123
)
124
124
125
125
def test_bad_col_spacing (self ):
126
126
with self .assertRaises (ValueError ) as cm :
127
- tls .make_subplots (cols = 3 , horizontal_spacing = 1 / 2 + 1e-6 )
127
+ tls .make_subplots (cols = 3 , horizontal_spacing = 1.0 / 2.0 + 1e-6 )
128
128
assert (
129
129
cm .exception .args [0 ]
130
130
== "Horizontal spacing must be less than or equal to 1 / (cols - 1)."
You can’t perform that action at this time.
0 commit comments