From 7298f25fe00682363249bb974a1fd49dc7b9df02 Mon Sep 17 00:00:00 2001 From: Felix Fontein Date: Fri, 1 Aug 2025 23:46:46 +0200 Subject: [PATCH] Fix no longer valid constructs in tests (#10543) Fix no longer valid constructs in tests. --- tests/integration/targets/apache2_module/tasks/actualtest.yml | 2 +- tests/integration/targets/decompress/tasks/dest.yml | 3 ++- tests/integration/targets/ldap_search/tasks/tests/schema.yml | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/integration/targets/apache2_module/tasks/actualtest.yml b/tests/integration/targets/apache2_module/tasks/actualtest.yml index 5bf66db9fb..88e063fe92 100644 --- a/tests/integration/targets/apache2_module/tasks/actualtest.yml +++ b/tests/integration/targets/apache2_module/tasks/actualtest.yml @@ -186,7 +186,7 @@ - name: ensure configcheck fails task with when run without mpm modules assert: that: - - "{{ item.failed }}" + - item is failed with_items: "{{ remove_with_configcheck.results }}" - name: try to disable all mpm modules without configcheck diff --git a/tests/integration/targets/decompress/tasks/dest.yml b/tests/integration/targets/decompress/tasks/dest.yml index 9a7bbe499f..4afd39e7b3 100644 --- a/tests/integration/targets/decompress/tasks/dest.yml +++ b/tests/integration/targets/decompress/tasks/dest.yml @@ -34,7 +34,8 @@ - name: Test that file exists assert: - that: "{{ item.stat.exists }}" + that: + - item.stat.exists quiet: true loop: "{{ result_files_stat.results }}" loop_control: diff --git a/tests/integration/targets/ldap_search/tasks/tests/schema.yml b/tests/integration/targets/ldap_search/tasks/tests/schema.yml index 63dd3fdf68..ca26305b82 100644 --- a/tests/integration/targets/ldap_search/tasks/tests/schema.yml +++ b/tests/integration/targets/ldap_search/tasks/tests/schema.yml @@ -22,4 +22,5 @@ that: - output is not failed - output.results | length >= 1 - - "{{ 'displayName' in output.results.0.attrs }}" + - >- + 'displayName' in output.results.0.attrs