From a5e7e441d32ab89ddfb19505c5839e8538dcf5cb Mon Sep 17 00:00:00 2001 From: holger krekel Date: Tue, 18 Sep 2012 13:46:24 +0200 Subject: [PATCH] fix bug introduced with last checkin --- _pytest/python.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/_pytest/python.py b/_pytest/python.py index 8543d6e77..c490828c0 100644 --- a/_pytest/python.py +++ b/_pytest/python.py @@ -1469,7 +1469,8 @@ class SetupCall: self.funcargmanager = funcargmanager self.baseid = baseid self.func = func - self.funcargnames = getfuncargnames(func, startindex=int(unittest)) + startindex = unittest and 1 or None + self.funcargnames = getfuncargnames(func, startindex=startindex) self.scope = scope self.scopenum = scopes.index(scope) self.active = False