Skip to content

TST: Fixturize series/test_arithmetic.py #22771

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions pandas/tests/series/test_arithmetic.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,12 @@ def test_ser_flex_cmp_return_dtypes(self, opname):
tm.assert_series_equal(result, Series([1], ['bool']))

@pytest.mark.parametrize('opname', ['eq', 'ne', 'gt', 'lt', 'ge', 'le'])
def test_ser_flex_cmp_return_dtypes_empty(self, opname):
def test_ser_flex_cmp_return_dtypes_empty(self, opname, empty_series):
# GH#15115 empty Series case
ser = Series([1, 3, 2], index=range(3))
empty = ser.iloc[:0]
const = 2

result = getattr(empty, opname)(const).get_dtype_counts()
result = getattr(empty_series, opname)(const).get_dtype_counts()
tm.assert_series_equal(result, Series([1], ['bool']))

@pytest.mark.parametrize('op', [operator.eq, operator.ne,
Expand Down