Signed-off-by: Costin Constantin <costin.c.constan...@intel.com> --- meta/lib/oeqa/selftest/buildoptions.py | 29 +++++++++-------------------- 1 file changed, 9 insertions(+), 20 deletions(-)
diff --git a/meta/lib/oeqa/selftest/buildoptions.py b/meta/lib/oeqa/selftest/buildoptions.py index e48bd04..620fd77 100644 --- a/meta/lib/oeqa/selftest/buildoptions.py +++ b/meta/lib/oeqa/selftest/buildoptions.py @@ -124,26 +124,15 @@ 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(283) - def test_btrfs(self): + @testcase(563) + def test_directfb(self): """ - This method is used to test the build of an image with btrfs file system. After building it, qemu is launched - and the test searches for the "login" keyword that it expects in order to consider an image as functional. - Please note that "runquemu" requires sudo access. In order to solve this please add to visudo (sudo visudo) - the following line: your_username ALL=NOPASSWD: ALL - The above setting was tested in Ubuntu + 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("MACHINE = \"qemux86\"\nIMAGE_FSTYPES = \"btrfs\"\nKERNEL_FEATURES_append = \" cfg/fs/btrfs \"") - self.res = bitbake("core-image-sato").status - self.remove_config("MACHINE = \"qemux86\"\nIMAGE_FSTYPES = \"btrfs\"\nKERNEL_FEATURES_append = \" cfg/fs/btrfs \"") - self.assertEqual(self.res, 0, "\nbtrfs core-image-sato failed to build. Please check logs for further details.\n") - self.prc = p.spawn("runqemu qemux86 core-image-sato nographic") - try: - self.prc.expect("login", timeout=150) - self.prc.kill(9) - self.assertTrue(True, "couldn't start qemu") - except: - self.prc.kill(9) - self.log.error("It is possible that runquemu didn't start correctly. Add this line your_username ALL=NOPASSWD: ALL\nto your visudo") - self.assertTrue(False, "Couldn't start qemu") \ No newline at end of file + 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 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core