summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/buildperf
diff options
context:
space:
mode:
authorMarkus Lehtonen <markus.lehtonen@linux.intel.com>2016-10-27 18:20:46 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-01-23 12:05:21 +0000
commitef988b3d06d71fe0dfb5d16e01dc9071ca0a095a (patch)
tree67045d04e1334e46026ad762c180325ea8d4354f /meta/lib/oeqa/buildperf
parent6a4debb732e1fef44b45f4c254c0e7d24d35dad5 (diff)
downloadpoky-ef988b3d06d71fe0dfb5d16e01dc9071ca0a095a.tar.gz
oeqa.buildperf: prevent a crash on unexpected success
(From OE-Core rev: af205d9a13d182a0b590426ba8c4e3dff7f3f02b) Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/buildperf')
-rw-r--r--meta/lib/oeqa/buildperf/base.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/meta/lib/oeqa/buildperf/base.py b/meta/lib/oeqa/buildperf/base.py
index 59dd02521c..4955914c23 100644
--- a/meta/lib/oeqa/buildperf/base.py
+++ b/meta/lib/oeqa/buildperf/base.py
@@ -137,7 +137,7 @@ class BuildPerfTestResult(unittest.TextTestResult):
137 def addSuccess(self, test): 137 def addSuccess(self, test):
138 """Record results from successful tests""" 138 """Record results from successful tests"""
139 super(BuildPerfTestResult, self).addSuccess(test) 139 super(BuildPerfTestResult, self).addSuccess(test)
140 self.successes.append((test, None)) 140 self.successes.append(test)
141 141
142 def startTest(self, test): 142 def startTest(self, test):
143 """Pre-test hook""" 143 """Pre-test hook"""
@@ -165,7 +165,10 @@ class BuildPerfTestResult(unittest.TextTestResult):
165 'SKIPPED': self.skipped} 165 'SKIPPED': self.skipped}
166 for status, tests in result_map.items(): 166 for status, tests in result_map.items():
167 for test in tests: 167 for test in tests:
168 yield (status, test) 168 if isinstance(test, tuple):
169 yield (status, test)
170 else:
171 yield (status, (test, None))
169 172
170 173
171 def update_globalres_file(self, filename): 174 def update_globalres_file(self, filename):