Skip to content

Commit d2c1b01

Browse files
committed
Initialize inside func
1 parent 9da0d4b commit d2c1b01

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pandas/tests/arrays/sparse/test_arithmetics.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -471,14 +471,14 @@ def test_mismatched_length_cmp_op(cons):
471471
@pytest.mark.parametrize(
472472
"a, b",
473473
[
474-
(SparseArray([0, 1, 2], fill_value=0), np.array([0, 1, 2, 3])),
475-
(SparseArray([0, 1, 2, 3], fill_value=0), np.array([0, 1, 2])),
474+
([0, 1, 2], [0, 1, 2, 3]),
475+
([0, 1, 2, 3], [0, 1, 2]),
476476
],
477477
)
478478
def test_mismatched_length_arith_op(a, b, all_arithmetic_functions):
479479
op = all_arithmetic_functions
480480
with pytest.raises(AssertionError, match=f"length mismatch: {len(a)} vs. {len(b)}"):
481-
op(a, b)
481+
op(SparseArray(a, fill_value=0), np.array(b))
482482

483483

484484
@pytest.mark.parametrize("op", ["add", "sub", "mul", "truediv", "floordiv", "pow"])

0 commit comments

Comments
 (0)