Skip to content

Commit 200c485

Browse files
committed
Changed test to use compat.builtins
1 parent a9b9a7f commit 200c485

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

.pytest_cache/v/cache/lastfailed

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{}

pandas/tests/groupby/test_groupby.py

+1-6
Original file line numberDiff line numberDiff line change
@@ -2129,13 +2129,8 @@ def interweave(list_obj):
21292129
def test_groupby_bool_aggs(self, agg_func, skipna, vals):
21302130
df = DataFrame({'key': ['a'] * 3 + ['b'] * 3, 'val': vals * 2})
21312131

2132-
if compat.PY3:
2133-
import builtins as bltins
2134-
else:
2135-
import __builtins__ as bltins
2136-
21372132
# Figure out expectation using Python builtin
2138-
exp = getattr(bltins, agg_func)(vals)
2133+
exp = getattr(compat.builtins, agg_func)(vals)
21392134

21402135
# edge case for missing data with skipna and 'any'
21412136
if skipna and all(isna(vals)) and agg_func == 'any':

0 commit comments

Comments
 (0)