[OE-core] [PATCH v2 05/13] selftest: buildoptions: skip test in case features are missing

leonardo.sandoval.gonzalez at linux.intel.com leonardo.sandoval.gonzalez at linux.intel.com
Thu Nov 24 20:58:05 UTC 2016


From: Leonardo Sandoval <leonardo.sandoval.gonzalez at linux.intel.com>

The sato image needs opengl and x11 as distro features, so skip
test if this is not the case.

Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez at linux.intel.com>
---
 meta/lib/oeqa/selftest/buildoptions.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/meta/lib/oeqa/selftest/buildoptions.py b/meta/lib/oeqa/selftest/buildoptions.py
index b228c56..25d14f7 100644
--- a/meta/lib/oeqa/selftest/buildoptions.py
+++ b/meta/lib/oeqa/selftest/buildoptions.py
@@ -43,8 +43,9 @@ class ImageOptionsTests(oeSelfTest):
 
     @testcase(1435)
     def test_read_only_image(self):
-        if self.distro == 'poky-tiny':
-            self.skipTest('core-image-sato is not buildable with poky-tiny')
+        distro_features = get_bb_var('DISTRO_FEATURES')
+        if not ('x11' in distro_features and 'opengl' in distro_features):
+            self.skipTest('core-image-sato requires x11 and opengl in distro features')
         self.write_config('IMAGE_FEATURES += "read-only-rootfs"')
         bitbake("core-image-sato")
         # do_image will fail if there are any pending postinsts
-- 
2.1.4




More information about the Openembedded-core mailing list