...
integration_platforms = ['nocloud-kvm', 'lxd']
integration_os_names = ['xenial']
stage('NoCloudKVM integration test') {
for (int i = 0; i < integration_platforms.size(); i++) {
for (int j = 0; j < integration_os_names.size(); j++) {
integration_test_platform(
${platforms[i]}, ${os_names[j]})
}
}
def integration_test_platform(platform, os_name) {
sh 'python3 -m tests.cloud_tests run --verbose --os-name ${os_name} --platform ${platform} --test modules/apt_configure_sources_list.yaml --test modules/ntp_servers --test modules/set_password_list --test modules/user_groups --deb cloud-init_*_all.deb'
}