diff options
author | Paulo Neves <ptsneves@gmail.com> | 2022-06-14 17:11:03 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-07-01 12:37:52 +0100 |
commit | 00458ee0f8c0619707b53b7a72450fbd8cbc3e02 (patch) | |
tree | ac8eda9c7327fc686dd491d3ce7aa67ead7ecd5f /meta/lib | |
parent | 53f0ee8d420008efa7408b1a83c42f7d5438f06a (diff) | |
download | poky-00458ee0f8c0619707b53b7a72450fbd8cbc3e02.tar.gz |
oeqa/selftest: Test staged .la and .pc files
These files are checked by qa_check_staged but there was no
test cases for whether the tests actually worked. Now there
are.
(From OE-Core rev: 2a96719a201cb7b8db774718adec89dbd7e1aec3)
Signed-off-by: Paulo Neves <ptsneves@gmail.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib')
-rw-r--r-- | meta/lib/oeqa/selftest/cases/sysroot.py | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/meta/lib/oeqa/selftest/cases/sysroot.py b/meta/lib/oeqa/selftest/cases/sysroot.py index 9457f1e3ac..588fc8c713 100644 --- a/meta/lib/oeqa/selftest/cases/sysroot.py +++ b/meta/lib/oeqa/selftest/cases/sysroot.py | |||
@@ -45,3 +45,35 @@ TESTSTRING:pn-sysroot-test-arch2 = "%s" | |||
45 | expected = "maximum shebang size exceeded, the maximum size is 128. [shebang-size]" | 45 | expected = "maximum shebang size exceeded, the maximum size is 128. [shebang-size]" |
46 | res = bitbake("sysroot-shebang-test-native -c populate_sysroot", ignore_status=True) | 46 | res = bitbake("sysroot-shebang-test-native -c populate_sysroot", ignore_status=True) |
47 | self.assertTrue(expected in res.output, msg=res.output) | 47 | self.assertTrue(expected in res.output, msg=res.output) |
48 | |||
49 | def test_sysroot_la(self): | ||
50 | """ | ||
51 | Summary: Check that workdir paths are not contained in .la files. | ||
52 | Expected: Fail when a workdir path is found in the file content. | ||
53 | Author: Paulo Neves <ptsneves@gmail.com> | ||
54 | """ | ||
55 | expected = "la-test.la failed sanity test (workdir) in path" | ||
56 | |||
57 | res = bitbake("sysroot-la-test -c populate_sysroot", ignore_status=True) | ||
58 | self.assertTrue(expected in res.output, msg=res.output) | ||
59 | self.assertTrue('[la]' in res.output, msg=res.output) | ||
60 | |||
61 | res = bitbake("sysroot-la-test-native -c populate_sysroot", ignore_status=True) | ||
62 | self.assertTrue(expected in res.output, msg=res.output) | ||
63 | self.assertTrue('[la]' in res.output, msg=res.output) | ||
64 | |||
65 | def test_sysroot_pkgconfig(self): | ||
66 | """ | ||
67 | Summary: Check that tmpdir paths are not contained in .pc files. | ||
68 | Expected: Fail when a tmpdir path is found in the file content. | ||
69 | Author: Paulo Neves <ptsneves@gmail.com> | ||
70 | """ | ||
71 | expected = "test.pc failed sanity test (tmpdir) in path" | ||
72 | |||
73 | res = bitbake("sysroot-pc-test -c populate_sysroot", ignore_status=True) | ||
74 | self.assertTrue('[pkgconfig]' in res.output, msg=res.output) | ||
75 | self.assertTrue(expected in res.output, msg=res.output) | ||
76 | |||
77 | res = bitbake("sysroot-pc-test-native -c populate_sysroot", ignore_status=True) | ||
78 | self.assertTrue(expected in res.output, msg=res.output) | ||
79 | self.assertTrue('[pkgconfig]' in res.output, msg=res.output) | ||