diff --git a/tests/containers/bci_test.pm b/tests/containers/bci_test.pm index 8a80157e810e..873d0fbc7ca1 100644 --- a/tests/containers/bci_test.pm +++ b/tests/containers/bci_test.pm @@ -101,6 +101,13 @@ sub run { $error_count = 0; + # For some containers we need to fake the OS version to distinguish them + my $os_version = get_var('BCI_OS_VERSION'); + if ($os_version) { + script_run("export OS_VERSION=$os_version"); + validate_script_output('echo $OS_VERSION', sub { m/$os_version/ }); + } + my $engine = $args->{runtime}; my $bci_devel_repo = get_var('BCI_DEVEL_REPO'); my $bci_tests_repo = get_required_var('BCI_TESTS_REPO'); diff --git a/variables.md b/variables.md index f72ee78b2a3d..6b52e3b1b418 100644 --- a/variables.md +++ b/variables.md @@ -37,6 +37,7 @@ BCI_TARGET | string | ibs-cr | Container project to be tested. `ibs-cr` is the C BCI_SKIP | boolean | false | Switch to disable BCI test runs. Necessary for fine-granular test disablement BCI_PREPARE | boolean | false | Launch the bci_prepare step again. Useful to re-initialize the BCI-Test repo when using a different BCI_TESTS_REPO BCI_VIRTUALENV | boolean | false | Use a virtualenv for pip dependencies in BCI tests +BCI_OS_VERSION | string | | Set the environment variable OS_VERSION to this value, if present BOOTLOADER | string | grub2 | Which bootloader is used by the image (and in the future also: will be selected during installation) BTRFS | boolean | false | Indicates btrfs filesystem. Deprecated, use FILESYSTEM instead. BUILD | string | | Indicates build number of the product under test.