Skip to content

Commit 75e040f

Browse files
mark plugin: remove python 2.5 compat code
1 parent 0352092 commit 75e040f

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

_pytest/mark/evalexpr.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -57,11 +57,7 @@ def istrue(self):
5757

5858
def _getglobals(self):
5959
d = {'os': os, 'sys': sys, 'config': self.item.config}
60-
func = self.item.obj
61-
try:
62-
d.update(func.__globals__)
63-
except AttributeError:
64-
d.update(func.func_globals)
60+
d.update(self.item.obj.__globals__)
6561
return d
6662

6763
def _istrue(self):

0 commit comments

Comments
 (0)