diff --git a/tests/integration/targets/remote_cluster_info/tasks/main.yml b/tests/integration/targets/remote_cluster_info/tasks/main.yml index fb1935ff1..c4fdd4af7 100644 --- a/tests/integration/targets/remote_cluster_info/tasks/main.yml +++ b/tests/integration/targets/remote_cluster_info/tasks/main.yml @@ -11,7 +11,11 @@ register: initial - name: If remote cluster is configured - when: sc_config[sc_host].sc_replication_dest_host + # sc_replication_dest_host is a non-empty URL string when configured, "" when not -- + # a bare string in `when:` used to be truthy-tested implicitly, but ansible-core + # 2.17.4 rejects it with "Conditionals must have a boolean result" the first time the + # string is genuinely non-empty (MEASURED 2026-10-29). + when: sc_config[sc_host].sc_replication_dest_host | length > 0 block: - ansible.builtin.assert: that: @@ -33,7 +37,7 @@ - results.records[0].name == initial.records[0].name - name: If remote cluster is not configured - when: not sc_config[sc_host].sc_replication_dest_host + when: sc_config[sc_host].sc_replication_dest_host | length == 0 block: - ansible.builtin.assert: that: diff --git a/tests/integration/targets/version_update_info/tasks/main.yml b/tests/integration/targets/version_update_info/tasks/main.yml index 7517d3f41..e79899138 100644 --- a/tests/integration/targets/version_update_info/tasks/main.yml +++ b/tests/integration/targets/version_update_info/tasks/main.yml @@ -28,10 +28,14 @@ - updates.records[-1].uuid == sc_config[sc_host].features.version_update.latest_version - updates.next.uuid == sc_config[sc_host].features.version_update.next_version - updates.latest.uuid == sc_config[sc_host].features.version_update.latest_version - when: sc_config[sc_host].features.version_update.next_version + # next_version is a non-empty version string when the host has real updates offered, + # "" when not -- a bare string in `when:` used to be truthy-tested implicitly, but + # ansible-core 2.17.4 rejects it the first time the string is genuinely non-empty + # (MEASURED 2026-10-29). + when: sc_config[sc_host].features.version_update.next_version | length > 0 - name: Check returned update list - no updates available ansible.builtin.assert: that: - updates.records == [] - when: not sc_config[sc_host].features.version_update.next_version + when: sc_config[sc_host].features.version_update.next_version | length == 0 diff --git a/tests/integration/targets/vm_clone__replicated/tasks/main.yml b/tests/integration/targets/vm_clone__replicated/tasks/main.yml index e299a7709..1f7e9c5e4 100644 --- a/tests/integration/targets/vm_clone__replicated/tasks/main.yml +++ b/tests/integration/targets/vm_clone__replicated/tasks/main.yml @@ -20,9 +20,12 @@ block: - name: Check replication is configured + # sc_replication_dest_host is a non-empty URL string when configured, "" when not -- + # a bare string here used to be truthy-tested implicitly, but ansible-core 2.17.4 + # rejects it the first time the string is genuinely non-empty (MEASURED 2026-10-29). ansible.builtin.assert: that: - - sc_config[sc_host].sc_replication_dest_host + - sc_config[sc_host].sc_replication_dest_host | length > 0 - include_tasks: 01_cleanup.yml - include_tasks: 02_prepare_source_vms.yml diff --git a/tests/integration/targets/vm_replication_info/tasks/main.yml b/tests/integration/targets/vm_replication_info/tasks/main.yml index a1d7a3cf1..f482fd9de 100644 --- a/tests/integration/targets/vm_replication_info/tasks/main.yml +++ b/tests/integration/targets/vm_replication_info/tasks/main.yml @@ -19,16 +19,21 @@ - include_tasks: 01_vm_replication_info_missing_vm.yml - include_tasks: 02_cleanup_destination_vms.yml - when: sc_config[sc_host].sc_replication_dest_host + # sc_replication_dest_host is a non-empty URL string when configured, "" when not -- + # a bare string in `when:` used to be truthy-tested implicitly, but ansible-core + # 2.17.4 rejects it with "Conditionals must have a boolean result" the first time the + # string is genuinely non-empty (MEASURED 2026-10-29, hypercore-ci-fleet's Indy-lab + # fixture is the first host in a long time to set a real non-empty value here). + when: sc_config[sc_host].sc_replication_dest_host | length > 0 # We can create VM and check vm_replication_info output also on # cluster without replication - include_tasks: 03_recreate_source_vms.yml - include_tasks: 10_vm_replication_info.yml - when: sc_config[sc_host].sc_replication_dest_host + when: sc_config[sc_host].sc_replication_dest_host | length > 0 - include_tasks: 20_vm_info.yml - when: sc_config[sc_host].sc_replication_dest_host + when: sc_config[sc_host].sc_replication_dest_host | length > 0 - include_tasks: 99_cleanup.yml