Skip to content

Commit 85c4560

Browse files
committed
Test float parsers with leading and trailing spaces
1 parent b0cf6c8 commit 85c4560

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

pandas/tests/io/parser/dtypes/test_dtypes_basic.py

+5
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,11 @@ def test_1000_sep_decimal_float_precision(
204204
# test decimal and thousand sep handling in across 'float_precision'
205205
# parsers
206206
decimal_number_check(c_parser_only, numeric_decimal, thousands, float_precision)
207+
text, value = numeric_decimal
208+
text = " " + text + " "
209+
if isinstance(value, str): # the negative cases (parse as text)
210+
value = " " + value + " "
211+
decimal_number_check(c_parser_only, (text, value), thousands, float_precision)
207212

208213

209214
def decimal_number_check(parser, numeric_decimal, thousands, float_precision):

0 commit comments

Comments
 (0)