Skip to content

Commit 6aee7ce

Browse files
This avoids failure to_datetime when value passed is None. This fix is pandas versions > 0.24.
Closes pandas-dev#30011
2 parents 7157af5 + d6297b2 commit 6aee7ce

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pandas/tests/indexes/datetimes/test_tools.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,8 @@ def test_to_datetime_format_YYYYMMDD_with_none(self, input_s):
114114
# GH 30011
115115
# format='%Y%m%d'
116116
# with None
117-
expected = Series([Timestamp("19801222"), Timestamp(None), Timestamp("20010112")])
117+
expected = Series([Timestamp("19801222"), Timestamp(None),
118+
Timestamp("20010112")])
118119
result = pd.to_datetime(input_s, format="%Y%m%d")
119120
tm.assert_series_equal(result, expected)
120121

0 commit comments

Comments
 (0)