summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/lib/oeqa/utils/decorators.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/meta/lib/oeqa/utils/decorators.py b/meta/lib/oeqa/utils/decorators.py
index 0d79223a29..d52f326f1a 100644
--- a/meta/lib/oeqa/utils/decorators.py
+++ b/meta/lib/oeqa/utils/decorators.py
@@ -57,6 +57,7 @@ class skipIfFailure(object):
57 self.testcase = testcase 57 self.testcase = testcase
58 58
59 def __call__(self,f): 59 def __call__(self,f):
60 @wraps(f)
60 def wrapped_f(*args, **kwargs): 61 def wrapped_f(*args, **kwargs):
61 res = getResults() 62 res = getResults()
62 if self.testcase in (res.getFailList() or res.getErrorList()): 63 if self.testcase in (res.getFailList() or res.getErrorList()):
@@ -71,6 +72,7 @@ class skipIfSkipped(object):
71 self.testcase = testcase 72 self.testcase = testcase
72 73
73 def __call__(self,f): 74 def __call__(self,f):
75 @wraps(f)
74 def wrapped_f(*args, **kwargs): 76 def wrapped_f(*args, **kwargs):
75 res = getResults() 77 res = getResults()
76 if self.testcase in res.getSkipList(): 78 if self.testcase in res.getSkipList():
@@ -85,6 +87,7 @@ class skipUnlessPassed(object):
85 self.testcase = testcase 87 self.testcase = testcase
86 88
87 def __call__(self,f): 89 def __call__(self,f):
90 @wraps(f)
88 def wrapped_f(*args, **kwargs): 91 def wrapped_f(*args, **kwargs):
89 res = getResults() 92 res = getResults()
90 if self.testcase in res.getSkipList() or \ 93 if self.testcase in res.getSkipList() or \
@@ -97,11 +100,11 @@ class skipUnlessPassed(object):
97 return wrapped_f 100 return wrapped_f
98 101
99class testcase(object): 102class testcase(object):
100
101 def __init__(self, test_case): 103 def __init__(self, test_case):
102 self.test_case = test_case 104 self.test_case = test_case
103 105
104 def __call__(self, func): 106 def __call__(self, func):
107 @wraps(func)
105 def wrapped_f(*args, **kwargs): 108 def wrapped_f(*args, **kwargs):
106 return func(*args, **kwargs) 109 return func(*args, **kwargs)
107 wrapped_f.test_case = self.test_case 110 wrapped_f.test_case = self.test_case