[OE-core] [PATCH v3] oeqa/sdk/cases:Adds validation for SDK compatibility tests
Francisco Pedraza
francisco.j.pedraza.gonzalez at intel.com
Fri Feb 24 16:14:10 UTC 2017
Added validation for SDK compatibility tests with eSDK.
buildcvs, buildiptables, gcc, perl, python and buildgalculator based on target manifest file.Running with: $ bitbake <image> -c testsdkext
[YOCTO #9090]
Signed-off-by: Francisco Pedraza <francisco.j.pedraza.gonzalez at intel.com>
---
meta/lib/oeqa/sdk/cases/buildcvs.py | 5 ++++-
meta/lib/oeqa/sdk/cases/buildgalculator.py | 4 +++-
meta/lib/oeqa/sdk/cases/buildiptables.py | 5 ++++-
meta/lib/oeqa/sdk/cases/gcc.py | 5 ++++-
meta/lib/oeqa/sdk/cases/perl.py | 5 ++++-
meta/lib/oeqa/sdk/cases/python.py | 5 ++++-
6 files changed, 23 insertions(+), 6 deletions(-)
diff --git a/meta/lib/oeqa/sdk/cases/buildcvs.py b/meta/lib/oeqa/sdk/cases/buildcvs.py
index 8cbbca1..5665beb 100644
--- a/meta/lib/oeqa/sdk/cases/buildcvs.py
+++ b/meta/lib/oeqa/sdk/cases/buildcvs.py
@@ -15,7 +15,10 @@ class BuildCvsTest(OESDKTestCase):
self.project.download_archive()
machine = self.td.get("MACHINE")
- if not self.tc.hasHostPackage("packagegroup-cross-canadian-%s" % machine):
+ if not (self.tc.hasTargetPackage("packagegroup-cross-canadian-%s" % machine) or
+ self.tc.hasTargetPackage("gcc-runtime") or
+ self.tc.hasTargetPackage("libgcc") or
+ self.tc.hasTargetPackage("gcc-sanitizers")):
raise unittest.SkipTest("SDK doesn't contain a cross-canadian toolchain")
def test_cvs(self):
diff --git a/meta/lib/oeqa/sdk/cases/buildgalculator.py b/meta/lib/oeqa/sdk/cases/buildgalculator.py
index 42e8ddb..f309ddf 100644
--- a/meta/lib/oeqa/sdk/cases/buildgalculator.py
+++ b/meta/lib/oeqa/sdk/cases/buildgalculator.py
@@ -9,7 +9,9 @@ class GalculatorTest(OESDKTestCase):
@classmethod
def setUpClass(self):
if not (self.tc.hasTargetPackage("gtk+3") or\
- self.tc.hasTargetPackage("libgtk-3.0")):
+ self.tc.hasTargetPackage("libgtk-3.0") or
+ self.tc.hasTargetPackage("gtk") or
+ self.tc.hasTargetPackage("matchbox-config-gtk")):
raise unittest.SkipTest("GalculatorTest class: SDK don't support gtk+3")
def test_galculator(self):
diff --git a/meta/lib/oeqa/sdk/cases/buildiptables.py b/meta/lib/oeqa/sdk/cases/buildiptables.py
index 0bd00d1..d7a0e6a 100644
--- a/meta/lib/oeqa/sdk/cases/buildiptables.py
+++ b/meta/lib/oeqa/sdk/cases/buildiptables.py
@@ -17,7 +17,10 @@ class BuildIptablesTest(OESDKTestCase):
machine = self.td.get("MACHINE")
- if not self.tc.hasHostPackage("packagegroup-cross-canadian-%s" % machine):
+ if not (self.tc.hasTargetPackage("packagegroup-cross-canadian-%s" % machine) or
+ self.tc.hasTargetPackage("gcc-runtime") or
+ self.tc.hasTargetPackage("libgcc") or
+ self.tc.hasTargetPackage("gcc-sanitizers")):
raise unittest.SkipTest("SDK doesn't contain a cross-canadian toolchain")
def test_iptables(self):
diff --git a/meta/lib/oeqa/sdk/cases/gcc.py b/meta/lib/oeqa/sdk/cases/gcc.py
index 74ad2a2..5404b74 100644
--- a/meta/lib/oeqa/sdk/cases/gcc.py
+++ b/meta/lib/oeqa/sdk/cases/gcc.py
@@ -18,7 +18,10 @@ class GccCompileTest(OESDKTestCase):
def setUp(self):
machine = self.td.get("MACHINE")
- if not self.tc.hasHostPackage("packagegroup-cross-canadian-%s" % machine):
+ if not (self.tc.hasTargetPackage("packagegroup-cross-canadian-%s" % machine) or
+ self.tc.hasTargetPackage("gcc-runtime") or
+ self.tc.hasTargetPackage("libgcc") or
+ self.tc.hasTargetPackage("gcc-sanitizers")):
raise unittest.SkipTest("GccCompileTest class: SDK doesn't contain a cross-canadian toolchain")
def test_gcc_compile(self):
diff --git a/meta/lib/oeqa/sdk/cases/perl.py b/meta/lib/oeqa/sdk/cases/perl.py
index e1bded2..8be9b74 100644
--- a/meta/lib/oeqa/sdk/cases/perl.py
+++ b/meta/lib/oeqa/sdk/cases/perl.py
@@ -8,7 +8,10 @@ from oeqa.sdk.case import OESDKTestCase
class PerlTest(OESDKTestCase):
@classmethod
def setUpClass(self):
- if not self.tc.hasHostPackage("nativesdk-perl"):
+ if not (self.tc.hasHostPackage("nativesdk-perl") or
+ self.tc.hasHostPackage("perl-native") or
+ self.tc.hasHostPackage("libperl5") or
+ self.tc.hasHostPackage("perl")):
raise unittest.SkipTest("No perl package in the SDK")
for f in ['test.pl']:
diff --git a/meta/lib/oeqa/sdk/cases/python.py b/meta/lib/oeqa/sdk/cases/python.py
index 94a296f..1628787 100644
--- a/meta/lib/oeqa/sdk/cases/python.py
+++ b/meta/lib/oeqa/sdk/cases/python.py
@@ -8,7 +8,10 @@ from oeqa.sdk.case import OESDKTestCase
class PythonTest(OESDKTestCase):
@classmethod
def setUpClass(self):
- if not self.tc.hasHostPackage("nativesdk-python"):
+ if not (self.tc.hasHostPackage("nativesdk-python") or
+ self.tc.hasHostPackage("python-smartpm-native") or
+ self.tc.hasHostPackage("python3-native") or
+ self.tc.hasHostPackage("python-native")):
raise unittest.SkipTest("No python package in the SDK")
for f in ['test.py']:
--
1.8.3.1
More information about the Openembedded-core
mailing list