diff --git a/tests_new/integration/roles/test_file/tasks/selinux_tests.yml b/tests_new/integration/roles/test_file/tasks/selinux_tests.yml index 7c898d46fc..048a366d1d 100644 --- a/tests_new/integration/roles/test_file/tasks/selinux_tests.yml +++ b/tests_new/integration/roles/test_file/tasks/selinux_tests.yml @@ -17,13 +17,14 @@ # along with Ansible. If not, see . - name: touch a file for testing - file: path={{output_dir}}/foo-se.txt state=file + file: path={{output_dir}}/foo-se.txt state=touch + register: file_se_result - name: verify that the file was marked as changed - assert: { that: "file_result.changed == true" } + assert: { that: "file_se_result.changed == true" } - name: assert touch a file for testing matches expected selinux context - assert: { that: "file_result.secontext == 'unconfined_u:object_r:admin_home_t:s0'" } + assert: { that: "file_se_result.secontext == 'unconfined_u:object_r:admin_home_t:s0'" } - name: remove the file used for testing file: path={{output_dir}}/foo-se.txt state=absent \ No newline at end of file