Skip to content

Commit 1f8a5d6

Browse files
committed
Review (jreback)
1 parent 0d8aa09 commit 1f8a5d6

File tree

1 file changed

+8
-12
lines changed

1 file changed

+8
-12
lines changed

pandas/tests/frame/test_arithmetic.py

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -126,18 +126,14 @@ def test_df_add_flex_filled_mixed_dtypes(self):
126126
'B': ser * 2})
127127
tm.assert_frame_equal(result, expected)
128128

129-
@pytest.mark.parametrize('op', ['add', 'sub', 'mul', 'div', 'truediv',
130-
'pow', 'floordiv', 'mod'])
131-
def test_arith_flex_frame(self, op, int_frame, mixed_int_frame,
132-
float_frame, mixed_float_frame):
133-
134-
if not PY3:
135-
aliases = {}
136-
else:
137-
aliases = {'div': 'truediv'}
138-
alias = aliases.get(op, op)
139-
140-
f = getattr(operator, alias)
129+
def test_arith_flex_frame(self, all_arithmetic_operators, int_frame,
130+
mixed_int_frame, float_frame, mixed_float_frame):
131+
132+
op = all_arithmetic_operators
133+
if op.startswith('__r'):
134+
pytest.skip('Reverse methods not available in operator library')
135+
136+
f = getattr(operator, op)
141137
result = getattr(float_frame, op)(2 * float_frame)
142138
exp = f(float_frame, 2 * float_frame)
143139
tm.assert_frame_equal(result, exp)

0 commit comments

Comments
 (0)