diff options
-rw-r--r-- | meta/lib/oeqa/selftest/buildoptions.py | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/meta/lib/oeqa/selftest/buildoptions.py b/meta/lib/oeqa/selftest/buildoptions.py index 998697daef..483803bf8d 100644 --- a/meta/lib/oeqa/selftest/buildoptions.py +++ b/meta/lib/oeqa/selftest/buildoptions.py | |||
@@ -2,6 +2,8 @@ import unittest | |||
2 | import os | 2 | import os |
3 | import logging | 3 | import logging |
4 | import re | 4 | import re |
5 | import glob as g | ||
6 | import pexpect as p | ||
5 | 7 | ||
6 | from oeqa.selftest.base import oeSelfTest | 8 | from oeqa.selftest.base import oeSelfTest |
7 | from oeqa.selftest.buildhistory import BuildhistoryBase | 9 | from oeqa.selftest.buildhistory import BuildhistoryBase |
@@ -130,3 +132,18 @@ class BuildImagesTest(oeSelfTest): | |||
130 | self.write_config("DISTRO_FEATURES_remove = \"x11\"\nDISTRO_FEATURES_append = \" directfb\"\nMACHINE ??= \"qemuarm\"") | 132 | self.write_config("DISTRO_FEATURES_remove = \"x11\"\nDISTRO_FEATURES_append = \" directfb\"\nMACHINE ??= \"qemuarm\"") |
131 | res = bitbake("core-image-directfb", ignore_status=True) | 133 | res = bitbake("core-image-directfb", ignore_status=True) |
132 | self.assertEqual(res.status, 0, "\ncoreimagedirectfb failed to build. Please check logs for further details.\nbitbake output %s" % res.output) | 134 | self.assertEqual(res.status, 0, "\ncoreimagedirectfb failed to build. Please check logs for further details.\nbitbake output %s" % res.output) |
135 | |||
136 | class ArchiverTest(oeSelfTest): | ||
137 | @testcase(926) | ||
138 | def test_arch_work_dir_and_export_source(self): | ||
139 | """ | ||
140 | Test for archiving the work directory and exporting the source files. | ||
141 | """ | ||
142 | self.add_command_to_tearDown('cleanupworkdir') | ||
143 | self.write_config("INHERIT = \"archiver\"\nARCHIVER_MODE[src] = \"original\"\nARCHIVER_MODE[srpm] = \"1\"") | ||
144 | res = bitbake("xcursor-transparent-theme", ignore_status=True) | ||
145 | self.assertEqual(res.status, 0, "\nCouldn't build xcursortransparenttheme.\nbitbake output %s" % res.output) | ||
146 | pkgs_path = g.glob(str(self.builddir) + "/tmp/deploy/sources/allarch*/xcurs*") | ||
147 | src_file_glob = str(pkgs_path[0]) + "/xcursor*.src.rpm" | ||
148 | tar_file_glob = str(pkgs_path[0]) + "/xcursor*.tar.gz" | ||
149 | self.assertTrue((g.glob(src_file_glob) and g.glob(tar_file_glob)), "Couldn't find .src.rpm and .tar.gz files under tmp/deploy/sources/allarch*/xcursor*") | ||