1
0
mirror of https://github.com/ansible-collections/community.general.git synced 2025-04-18 20:44:16 +03:00

[PR #9945/e5e33534 backport][stable-8] Simplify YAML callback tests (#9946)

Simplify YAML callback tests (#9945)

Simplify YAML callback tests.

(cherry picked from commit e5e335348a14789fc502ed1d84f3c05b604e4803)

Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
patchback[bot] 2025-03-29 11:01:54 +01:00 committed by GitHub
parent 3cba1a99e6
commit b742f7e0ce
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -67,7 +67,7 @@
ANSIBLE_NOCOLOR: 'true'
ANSIBLE_FORCE_COLOR: 'false'
ANSIBLE_STDOUT_CALLBACK: community.general.yaml
playbook: |
playbook: !unsafe |
- hosts: testhost
gather_facts: false
vars:
@ -78,9 +78,7 @@
tasks:
- name: Test to_yaml
debug:
msg: "{{ '{{' }}'{{ '{{' }}'{{ '}}' }} data | to_yaml {{ '{{' }}'{{ '}}' }}'{{ '}}' }}"
# The above should be: msg: "{{ data | to_yaml }}"
# Unfortunately, the way Ansible handles templating, we need to do some funny 'escaping' tricks...
msg: "{{ data | to_yaml }}"
expected_output: [
"",
"PLAY [testhost] ****************************************************************",