[OE-core] [PATCH] oeqa/selftest/buildoptions.py: added auto test for directfb image generation

Costin Constantin costin.c.constantin at intel.com
Tue Jun 9 11:12:15 UTC 2015


Signed-off-by: Costin Constantin <costin.c.constantin at intel.com>
---
 meta/lib/oeqa/selftest/buildoptions.py | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/meta/lib/oeqa/selftest/buildoptions.py b/meta/lib/oeqa/selftest/buildoptions.py
index 926ffe9..c69da68 100644
--- a/meta/lib/oeqa/selftest/buildoptions.py
+++ b/meta/lib/oeqa/selftest/buildoptions.py
@@ -120,7 +120,16 @@ class BuildhistoryTests(BuildhistoryBase):
         self.run_buildhistory_operation(target, target_config="PR = \"r0\"", change_bh_location=False, expect_error=True, error_regex=error)
 
 
-
-
-
-
+class BuildImagesTest(oeSelfTest):
+    @testcase(563)
+    def test_directfb(self):
+        """
+        This method is used to test the build of directfb image for arm arch.
+        In essence we build a core-image-directfb and test the exitcode of bitbake that in case of success is 0.
+        """
+        self.add_command_to_tearDown('cleanup-workdir')
+        self.write_config("DISTRO_FEATURES_remove = \"x11\"\nDISTRO_FEATURES_append = \" directfb\"\nMACHINE ??= \"qemuarm\"")
+        self.res = bitbake("core-image-directfb").status
+        self.remove_config("DISTRO_FEATURES_remove = \"x11\"\nDISTRO_FEATURES_append = \" directfb\"\nMACHINE ??= \"qemuarm\"")
+        self.assertEqual(self.res, 0, "\ndirectfb image couldn't be built\n")
+        self.assertEqual(self.res, 0, "\ncore-image-directfb failed to build. Please check logs for further details.\n")
\ No newline at end of file
-- 
2.1.4




More information about the Openembedded-core mailing list