summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/lib/oeqa/selftest/cases/oescripts.py17
1 files changed, 15 insertions, 2 deletions
diff --git a/meta/lib/oeqa/selftest/cases/oescripts.py b/meta/lib/oeqa/selftest/cases/oescripts.py
index 1ee753763e..bcdc2d5ac0 100644
--- a/meta/lib/oeqa/selftest/cases/oescripts.py
+++ b/meta/lib/oeqa/selftest/cases/oescripts.py
@@ -10,6 +10,19 @@ class BuildhistoryDiffTests(BuildhistoryBase):
10 target = 'xcursor-transparent-theme' 10 target = 'xcursor-transparent-theme'
11 self.run_buildhistory_operation(target, target_config="PR = \"r1\"", change_bh_location=True) 11 self.run_buildhistory_operation(target, target_config="PR = \"r1\"", change_bh_location=True)
12 self.run_buildhistory_operation(target, target_config="PR = \"r0\"", change_bh_location=False, expect_error=True) 12 self.run_buildhistory_operation(target, target_config="PR = \"r0\"", change_bh_location=False, expect_error=True)
13 result = runCmd("oe-pkgdata-util read-value PKGV %s" % target)
14 pkgv = result.output.rstrip()
13 result = runCmd("buildhistory-diff -p %s" % get_bb_var('BUILDHISTORY_DIR')) 15 result = runCmd("buildhistory-diff -p %s" % get_bb_var('BUILDHISTORY_DIR'))
14 expected_output = 'PR changed from "r1" to "r0"' 16 expected_endlines = [
15 self.assertTrue(expected_output in result.output, msg="Did not find expected output: %s" % result.output) 17 "xcursor-transparent-theme-dev: RDEPENDS: removed \"xcursor-transparent-theme (['= %s-r1'])\", added \"xcursor-transparent-theme (['= %s-r0'])\"" % (pkgv, pkgv),
18 "xcursor-transparent-theme-staticdev: RDEPENDS: removed \"xcursor-transparent-theme-dev (['= %s-r1'])\", added \"xcursor-transparent-theme-dev (['= %s-r0'])\"" % (pkgv, pkgv)
19 ]
20 for line in result.output.splitlines():
21 for el in expected_endlines:
22 if line.endswith(el):
23 expected_endlines.remove(el)
24 break
25 else:
26 self.fail('Unexpected line:\n%s\nExpected line endings:\n %s' % (line, '\n '.join(expected_endlines)))
27 if expected_endlines:
28 self.fail('Missing expected line endings:\n %s' % '\n '.join(expected_endlines))