Skip to content

Commit bad377d

Browse files
committed
fixup
1 parent c6108ec commit bad377d

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

pandas/tests/arrays/integer/test_arithmetic.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -274,7 +274,7 @@ def test_cross_type_arithmetic():
274274

275275

276276
@pytest.mark.parametrize("op", ["mean"])
277-
def test_reduce_to_float(op):
277+
def test_reduce_to_float(op, using_python_scalars):
278278
# some reduce ops always return float, even if the result
279279
# is a rounded number
280280
df = pd.DataFrame(
@@ -287,7 +287,10 @@ def test_reduce_to_float(op):
287287

288288
# op
289289
result = getattr(df.C, op)()
290-
assert type(result) == float
290+
if using_python_scalars:
291+
assert type(result) == float
292+
else:
293+
assert isinstance(result, np.float64)
291294

292295
# groupby
293296
result = getattr(df.groupby("A"), op)()

0 commit comments

Comments
 (0)