Skip to content

Commit 6367f9a

Browse files
Extend tests in test_equals.py with different types
1 parent 8b26aec commit 6367f9a

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

pandas/tests/series/methods/test_equals.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,17 @@ def test_equals(arr, idx):
2424
assert not s1.equals(s2)
2525

2626

27-
def test_equals_list_array():
27+
@pytest.mark.parametrize(
28+
"val", [1, 1.1, 1 + 1j, True, "abc", [1, 2], (1, 2), {1, 2}, {"a": 1}, None]
29+
)
30+
def test_equals_list_array(val):
2831
# GH20676 Verify equals operator for list of Numpy arrays
2932
arr = np.array([1, 2])
3033
s1 = Series([arr, arr])
3134
s2 = s1.copy()
3235
assert s1.equals(s2)
3336

34-
s1[1] = 9
37+
s1[1] = val
3538
assert not s1.equals(s2)
3639

3740

0 commit comments

Comments
 (0)