summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/lib/oeqa/selftest/cases/buildoptions.py24
1 files changed, 24 insertions, 0 deletions
diff --git a/meta/lib/oeqa/selftest/cases/buildoptions.py b/meta/lib/oeqa/selftest/cases/buildoptions.py
index be49322f9c..f99881758e 100644
--- a/meta/lib/oeqa/selftest/cases/buildoptions.py
+++ b/meta/lib/oeqa/selftest/cases/buildoptions.py
@@ -148,6 +148,30 @@ class BuildhistoryTests(BuildhistoryBase):
148 self.run_buildhistory_operation(target, target_config="PR = \"r1\"", change_bh_location=True) 148 self.run_buildhistory_operation(target, target_config="PR = \"r1\"", change_bh_location=True)
149 self.run_buildhistory_operation(target, target_config="PR = \"r0\"", change_bh_location=False, expect_error=True, error_regex=error) 149 self.run_buildhistory_operation(target, target_config="PR = \"r0\"", change_bh_location=False, expect_error=True, error_regex=error)
150 150
151 def test_fileinfo(self):
152 self.config_buildhistory()
153 bitbake('hicolor-icon-theme')
154 history_dir = get_bb_var('BUILDHISTORY_DIR_PACKAGE', 'hicolor-icon-theme')
155 self.assertTrue(os.path.isdir(history_dir), 'buildhistory dir was not created.')
156
157 def load_bh(f):
158 d = {}
159 for line in open(f):
160 split = [s.strip() for s in line.split('=', 1)]
161 if len(split) > 1:
162 d[split[0]] = split[1]
163 return d
164
165 data = load_bh(os.path.join(history_dir, 'hicolor-icon-theme', 'latest'))
166 self.assertIn('FILELIST', data)
167 self.assertEqual(data['FILELIST'], '/usr/share/icons/hicolor/index.theme')
168 self.assertGreater(int(data['PKGSIZE']), 0)
169
170 data = load_bh(os.path.join(history_dir, 'hicolor-icon-theme-dev', 'latest'))
171 if 'FILELIST' in data:
172 self.assertEqual(data['FILELIST'], '')
173 self.assertEqual(int(data['PKGSIZE']), 0)
174
151class ArchiverTest(OESelftestTestCase): 175class ArchiverTest(OESelftestTestCase):
152 def test_arch_work_dir_and_export_source(self): 176 def test_arch_work_dir_and_export_source(self):
153 """ 177 """