diff options
author | Nathan Rossi <nathan@nathanrossi.com> | 2019-09-11 14:13:07 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-09-16 23:02:43 +0100 |
commit | 6c7d657aaeb223c3136e916da34468af468397b7 (patch) | |
tree | 8d9657740e0b70d18f845052f5bbb65ad96f51f5 /meta/lib/oeqa/selftest/cases/glibc.py | |
parent | e08f657220fa119793949e26b2837026956d4238 (diff) | |
download | poky-6c7d657aaeb223c3136e916da34468af468397b7.tar.gz |
oeqa/selftest: Rework toolchain tests to use OEPTestResultTestCase
Use OEPTestResultTestCase to collect results and add logfile collection
and compression.
(From OE-Core rev: b75aced558013a459f29617b53cf477cb9b387ac)
Signed-off-by: Nathan Rossi <nathan@nathanrossi.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/selftest/cases/glibc.py')
-rw-r--r-- | meta/lib/oeqa/selftest/cases/glibc.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/meta/lib/oeqa/selftest/cases/glibc.py b/meta/lib/oeqa/selftest/cases/glibc.py index 2e42485dd6..c687f6ef93 100644 --- a/meta/lib/oeqa/selftest/cases/glibc.py +++ b/meta/lib/oeqa/selftest/cases/glibc.py | |||
@@ -2,6 +2,7 @@ | |||
2 | import os | 2 | import os |
3 | import contextlib | 3 | import contextlib |
4 | from oeqa.core.decorator import OETestTag | 4 | from oeqa.core.decorator import OETestTag |
5 | from oeqa.core.case import OEPTestResultTestCase | ||
5 | from oeqa.selftest.case import OESelftestTestCase | 6 | from oeqa.selftest.case import OESelftestTestCase |
6 | from oeqa.utils.commands import bitbake, get_bb_var, get_bb_vars, runqemu, Command | 7 | from oeqa.utils.commands import bitbake, get_bb_var, get_bb_vars, runqemu, Command |
7 | from oeqa.utils.nfs import unfs_server | 8 | from oeqa.utils.nfs import unfs_server |
@@ -13,7 +14,7 @@ def parse_values(content): | |||
13 | yield i[len(v) + 2:].strip(), v | 14 | yield i[len(v) + 2:].strip(), v |
14 | break | 15 | break |
15 | 16 | ||
16 | class GlibcSelfTestBase(OESelftestTestCase): | 17 | class GlibcSelfTestBase(OESelftestTestCase, OEPTestResultTestCase): |
17 | def run_check(self, ssh = None): | 18 | def run_check(self, ssh = None): |
18 | # configure ssh target | 19 | # configure ssh target |
19 | features = [] | 20 | features = [] |
@@ -31,10 +32,10 @@ class GlibcSelfTestBase(OESelftestTestCase): | |||
31 | builddir = get_bb_var("B", "glibc-testsuite") | 32 | builddir = get_bb_var("B", "glibc-testsuite") |
32 | 33 | ||
33 | ptestsuite = "glibc-user" if ssh is None else "glibc" | 34 | ptestsuite = "glibc-user" if ssh is None else "glibc" |
34 | self.extraresults = {"ptestresult.sections" : {ptestsuite : {}}} | 35 | self.ptest_section(ptestsuite) |
35 | with open(os.path.join(builddir, "tests.sum"), "r") as f: | 36 | with open(os.path.join(builddir, "tests.sum"), "r") as f: |
36 | for test, result in parse_values(f): | 37 | for test, result in parse_values(f): |
37 | self.extraresults["ptestresult.{}.{}".format(ptestsuite, test)] = {"status" : result} | 38 | self.ptest_result(ptestsuite, test, result) |
38 | 39 | ||
39 | def run_check_emulated(self): | 40 | def run_check_emulated(self): |
40 | with contextlib.ExitStack() as s: | 41 | with contextlib.ExitStack() as s: |