[v9,4/8] testsuite: Allow variable bootstrap providers

Message ID 20240614113425.122722-5-amikan@ilbers.de
State Superseded, archived
Headers show
Series [v9,1/8] isar-bootstrap: Move common parts to bbclass | expand

Commit Message

Anton Mikanovich June 14, 2024, 11:34 a.m. UTC
If we can use different recipes provide bootstrap, recipe name should
be obtained from target environment.

Signed-off-by: Anton Mikanovich <amikan@ilbers.de>
---
 testsuite/cibase.py | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

Patch

diff --git a/testsuite/cibase.py b/testsuite/cibase.py
index 0f6997af..c6117b36 100755
--- a/testsuite/cibase.py
+++ b/testsuite/cibase.py
@@ -179,8 +179,9 @@  class CIBaseTest(CIBuilder):
         # Rebuild image
         self.move_in_build_dir('tmp', 'tmp_before_sstate')
         self.bitbake(image_target, **kwargs)
+        bootstrap_target_task = self.getVars('PREFERRED_PROVIDER_bootstrap-target', target=image_target)
         if not all([
-                check_executed_tasks('isar-bootstrap-target',
+                check_executed_tasks(bootstrap_target_task,
                     ['do_bootstrap_setscene', '!do_bootstrap']),
                 check_executed_tasks('sbuild-chroot-target',
                     ['do_rootfs_install_setscene', '!do_rootfs_install']),
@@ -204,7 +205,7 @@  class CIBaseTest(CIBuilder):
         self.move_in_build_dir('tmp', 'tmp_middle_sstate')
         self.bitbake(package_target, **kwargs)
         if not all([
-                check_executed_tasks('isar-bootstrap-target',
+                check_executed_tasks(bootstrap_target_task,
                     ['do_bootstrap_setscene']),
                 check_executed_tasks('sbuild-chroot-target',
                     ['!do_sbuildchroot_deploy']),
@@ -218,7 +219,7 @@  class CIBaseTest(CIBuilder):
         process.run(f'find {self.build_dir}/sstate-cache/ -name sstate:hello:* -delete')
         self.bitbake(image_target, **kwargs)
         if not all([
-                check_executed_tasks('isar-bootstrap-target',
+                check_executed_tasks(bootstrap_target_task,
                     ['do_bootstrap_setscene', '!do_bootstrap']),
                 check_executed_tasks('sbuild-chroot-target',
                     ['do_rootfs_install_setscene', '!do_rootfs_install']),