]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
oeqa/sstatetests: Improve/fix sstate creation tests
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 25 Jun 2025 13:43:26 +0000 (14:43 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 26 Jun 2025 10:00:48 +0000 (11:00 +0100)
commit5b9263040013199c5cb480125d5ca349f5d6dc55
tree7cd6f56837554000c2a95cae154fb96cb7f21df3
parente1c46fdb44fed18909d9ff4b43b4e445c5a22d33
oeqa/sstatetests: Improve/fix sstate creation tests

There are multiple problems with the sstate creation tests. They currently both execute
twice, once to check one set of files, then another. We can do this together in one
test which makes the code easier to follow.

The common test function also has parameters which were always the same value, so
those can be simplified.

We can use the umask context manager from bb.utils to simplfy the umask code.

The badperms test was actually broken, it was detecting bad permissions, then
ignoring them. This patch fixes that regression too and allows the check to
operate (relying on a separate fix to sstate umask handling).

The result should be an easier to understand couple of test cases which should
also function correctly and be more reliable.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/lib/oeqa/selftest/cases/sstatetests.py