From 6a1b0c2003a0b4a1983f9494440e6ea02dc25585 Mon Sep 17 00:00:00 2001 From: Nathan Rossi Date: Sat, 7 Sep 2019 12:55:06 +0000 Subject: oeqa/selftest: Use extraresults on self instead of self.tc In order to take advantage of multiprocess execution of tests the extraresults must be passed through the TestResult. With changes to how oeqa/core handles test cases the extraresults attribute of the testcase is passed to the TestResult, with passing across process boundaries handled automatically. Signed-off-by: Nathan Rossi Signed-off-by: Richard Purdie --- meta/lib/oeqa/selftest/cases/glibc.py | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'meta/lib/oeqa/selftest/cases/glibc.py') diff --git a/meta/lib/oeqa/selftest/cases/glibc.py b/meta/lib/oeqa/selftest/cases/glibc.py index 4d0c13131b..e13de87014 100644 --- a/meta/lib/oeqa/selftest/cases/glibc.py +++ b/meta/lib/oeqa/selftest/cases/glibc.py @@ -15,15 +15,6 @@ def parse_values(content): @OETestTag("machine") class GlibcSelfTest(OESelftestTestCase): - @classmethod - def setUpClass(cls): - super().setUpClass() - if not hasattr(cls.tc, "extraresults"): - cls.tc.extraresults = {} - - if "ptestresult.sections" not in cls.tc.extraresults: - cls.tc.extraresults["ptestresult.sections"] = {} - def test_glibc(self): self.glibc_run_check() @@ -44,10 +35,10 @@ class GlibcSelfTest(OESelftestTestCase): builddir = get_bb_var("B", "glibc-testsuite") ptestsuite = "glibc-user" if ssh is None else "glibc" - self.tc.extraresults["ptestresult.sections"][ptestsuite] = {} + self.extraresults = {"ptestresult.sections" : {ptestsuite : {}}} with open(os.path.join(builddir, "tests.sum"), "r") as f: for test, result in parse_values(f): - self.tc.extraresults["ptestresult.{}.{}".format(ptestsuite, test)] = {"status" : result} + self.extraresults["ptestresult.{}.{}".format(ptestsuite, test)] = {"status" : result} class GlibcSelfTestSystemEmulated(GlibcSelfTest): default_installed_packages = [ -- cgit 1.2.3-korg