mirror of
https://git.yoctoproject.org/poky
synced 2026-03-19 13:49:41 +01:00
selftest/sstatetests: separate sstate presence check into its own class
This allows reusing the check function in tests other than CDN/local mirror ones, such as sstate bundle testing. (From OE-Core rev: 8a4ab4c063f307b480d98c6aac1e76cde0b9e99e) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
11762e4dc3
commit
c149c74605
@@ -917,8 +917,7 @@ INHERIT += "base-do-configure-modified"
|
||||
""",
|
||||
expected_sametmp_output, expected_difftmp_output)
|
||||
|
||||
@OETestTag("yocto-mirrors")
|
||||
class SStateMirrors(SStateBase):
|
||||
class SStateCheckObjectPresence(SStateBase):
|
||||
def check_bb_output(self, output, exceptions, check_cdn):
|
||||
def is_exception(object, exceptions):
|
||||
for e in exceptions:
|
||||
@@ -960,6 +959,8 @@ class SStateMirrors(SStateBase):
|
||||
self.assertEqual(len(failed_urls), missing_objects, "Amount of reported missing objects does not match failed URLs: {}\nFailed URLs:\n{}\nFetcher diagnostics:\n{}".format(missing_objects, "\n".join(failed_urls), "\n".join(failed_urls_extrainfo)))
|
||||
self.assertEqual(len(failed_urls), 0, "Missing objects in the cache:\n{}\nFetcher diagnostics:\n{}".format("\n".join(failed_urls), "\n".join(failed_urls_extrainfo)))
|
||||
|
||||
@OETestTag("yocto-mirrors")
|
||||
class SStateMirrors(SStateCheckObjectPresence):
|
||||
def run_test(self, machine, targets, exceptions, check_cdn = True, ignore_errors = False):
|
||||
# sstate is checked for existence of these, but they never get written out to begin with
|
||||
exceptions += ["{}.*image_qa".format(t) for t in targets.split()]
|
||||
|
||||
Reference in New Issue
Block a user