We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ef2fda8 commit 6a5d92cCopy full SHA for 6a5d92c
pandas/tests/frame/indexing/test_indexing.py
@@ -832,13 +832,8 @@ def test_setitem_single_column_mixed_datetime(self):
832
tm.assert_series_equal(result, expected)
833
834
# GH#16674 iNaT is treated as an integer when given by the user
835
- with tm.assert_produces_warning(
836
- FutureWarning, match="Setting an item of incompatible dtype"
837
- ):
+ with pytest.raises(TypeError, match="Invalid value"):
838
df.loc["b", "timestamp"] = iNaT
839
- assert not isna(df.loc["b", "timestamp"])
840
- assert df["timestamp"].dtype == np.object_
841
- assert df.loc["b", "timestamp"] == iNaT
842
843
# allow this syntax (as of GH#3216)
844
df.loc["c", "timestamp"] = np.nan
0 commit comments