Skip to content

Commit 3929828

Browse files
committed
simpify tests
1 parent 5271d60 commit 3929828

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pandas/tests/extension/base/interface.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,14 @@ def test_contains(self, data):
3737

3838
na_value = data.dtype.na_value
3939
other_na_value_types = {None, np.nan, pd.NA, pd.NaT}.difference({na_value})
40+
4041
if data.isna().any():
4142
assert na_value in data
42-
for na_value_type in other_na_value_types:
43-
assert na_value_type not in data
4443
else:
4544
assert na_value not in data
46-
for na_value_type in other_na_value_types:
47-
assert na_value_type not in data
45+
46+
for na_value_type in other_na_value_types:
47+
assert na_value_type not in data
4848

4949
def test_memory_usage(self, data):
5050
s = pd.Series(data)

0 commit comments

Comments
 (0)