diff --git a/pandas/tests/extension/base/ops.py b/pandas/tests/extension/base/ops.py index c52f20255eb81..1d3d736ca7ee2 100644 --- a/pandas/tests/extension/base/ops.py +++ b/pandas/tests/extension/base/ops.py @@ -162,13 +162,12 @@ def test_compare_array(self, data, comparison_op): other = pd.Series([data[0]] * len(data)) self._compare_other(ser, data, comparison_op, other) - def test_direct_arith_with_ndframe_returns_not_implemented( - self, data, frame_or_series - ): + @pytest.mark.parametrize("box", [pd.Series, pd.DataFrame]) + def test_direct_arith_with_ndframe_returns_not_implemented(self, data, box): # EAs should return NotImplemented for ops with Series/DataFrame # Pandas takes care of unboxing the series and calling the EA's op. other = pd.Series(data) - if frame_or_series is pd.DataFrame: + if box is pd.DataFrame: other = other.to_frame() if hasattr(data, "__eq__"):