diff options
Diffstat (limited to 'meta/lib/oeqa/oetest.py')
-rw-r--r-- | meta/lib/oeqa/oetest.py | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/meta/lib/oeqa/oetest.py b/meta/lib/oeqa/oetest.py index d1aef967e4..d7c358844f 100644 --- a/meta/lib/oeqa/oetest.py +++ b/meta/lib/oeqa/oetest.py | |||
@@ -145,20 +145,6 @@ class OETestCalledProcessError(subprocess.CalledProcessError): | |||
145 | 145 | ||
146 | subprocess.CalledProcessError = OETestCalledProcessError | 146 | subprocess.CalledProcessError = OETestCalledProcessError |
147 | 147 | ||
148 | class oeSDKTest(oeTest): | ||
149 | def __init__(self, methodName='runTest'): | ||
150 | self.sdktestdir = oeSDKTest.tc.sdktestdir | ||
151 | super(oeSDKTest, self).__init__(methodName) | ||
152 | |||
153 | @classmethod | ||
154 | def hasHostPackage(self, pkg): | ||
155 | if re.search(pkg, oeTest.tc.hostpkgmanifest): | ||
156 | return True | ||
157 | return False | ||
158 | |||
159 | def _run(self, cmd): | ||
160 | return subprocess.check_output(". %s > /dev/null; %s;" % (self.tc.sdkenv, cmd), shell=True, stderr=subprocess.STDOUT).decode("utf-8") | ||
161 | |||
162 | class oeSDKExtTest(oeSDKTest): | 148 | class oeSDKExtTest(oeSDKTest): |
163 | def _run(self, cmd): | 149 | def _run(self, cmd): |
164 | # extensible sdk shows a warning if found bitbake in the path | 150 | # extensible sdk shows a warning if found bitbake in the path |
@@ -657,43 +643,6 @@ class ExportTestContext(RuntimeTestContext): | |||
657 | pkg_dir = os.path.join(export_dir, extracted_dir) | 643 | pkg_dir = os.path.join(export_dir, extracted_dir) |
658 | super(ExportTestContext, self).install_uninstall_packages(test_id, pkg_dir, install) | 644 | super(ExportTestContext, self).install_uninstall_packages(test_id, pkg_dir, install) |
659 | 645 | ||
660 | class SDKTestContext(TestContext): | ||
661 | def __init__(self, d, sdktestdir, sdkenv, tcname, *args): | ||
662 | super(SDKTestContext, self).__init__(d) | ||
663 | |||
664 | self.sdktestdir = sdktestdir | ||
665 | self.sdkenv = sdkenv | ||
666 | self.tcname = tcname | ||
667 | |||
668 | if not hasattr(self, 'target_manifest'): | ||
669 | self.target_manifest = d.getVar("SDK_TARGET_MANIFEST") | ||
670 | try: | ||
671 | self.pkgmanifest = {} | ||
672 | with open(self.target_manifest) as f: | ||
673 | for line in f: | ||
674 | (pkg, arch, version) = line.strip().split() | ||
675 | self.pkgmanifest[pkg] = (version, arch) | ||
676 | except IOError as e: | ||
677 | bb.fatal("No package manifest file found. Did you build the sdk image?\n%s" % e) | ||
678 | |||
679 | if not hasattr(self, 'host_manifest'): | ||
680 | self.host_manifest = d.getVar("SDK_HOST_MANIFEST") | ||
681 | try: | ||
682 | with open(self.host_manifest) as f: | ||
683 | self.hostpkgmanifest = f.read() | ||
684 | except IOError as e: | ||
685 | bb.fatal("No host package manifest file found. Did you build the sdk image?\n%s" % e) | ||
686 | |||
687 | def _get_test_namespace(self): | ||
688 | return "sdk" | ||
689 | |||
690 | def _get_test_suites(self): | ||
691 | return (self.d.getVar("TEST_SUITES_SDK") or "auto").split() | ||
692 | |||
693 | def _get_test_suites_required(self): | ||
694 | return [t for t in (self.d.getVar("TEST_SUITES_SDK") or \ | ||
695 | "auto").split() if t != "auto"] | ||
696 | |||
697 | class SDKExtTestContext(SDKTestContext): | 646 | class SDKExtTestContext(SDKTestContext): |
698 | def __init__(self, d, sdktestdir, sdkenv, tcname, *args): | 647 | def __init__(self, d, sdktestdir, sdkenv, tcname, *args): |
699 | self.target_manifest = d.getVar("SDK_EXT_TARGET_MANIFEST") | 648 | self.target_manifest = d.getVar("SDK_EXT_TARGET_MANIFEST") |