tests: test for collection_skeleton_ignore (#86896)

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
This commit is contained in:
Abhijeet Kasurde
2026-06-02 08:26:04 -07:00
committed by GitHub
parent 2a628c04c9
commit 9dfed16dae
2 changed files with 14 additions and 4 deletions
@@ -116,6 +116,14 @@
loop:
- inventory/foo.py
- galaxy.yml
- CLAUDE.md
- name: create a valid skeleton ignore expression in ansible.cfg
copy:
content: |
[galaxy]
collection_skeleton_ignore=^\./CLAUDE.md$
dest: "{{ galaxy_dir }}/scratch/skeleton/ansible.cfg"
- name: create symlinks
file:
@@ -151,6 +159,7 @@
- galaxy.yml
- plugins/inventory/foo.py
- README
- CLAUDE.md
- assert:
that:
@@ -159,6 +168,7 @@
- stat_result.results[2].stat.islnk
- stat_result.results[3].stat.isreg
- stat_result.results[4].stat.isreg
- not stat_result.results[5].stat.exists
- name: Verify the README was templated successfully
copy:
@@ -708,13 +708,13 @@
# test --ignore-signature-status-code passed multiple times
- name: reinstall collections with only one valid signature by ignoring the other errors
command: ansible-galaxy install -r {{ req_file }} {{ cli_opts }} {{ galaxy_verbosity }} {{ ignore_errors }}
command: ansible-galaxy install -r {{ req_file }} {{ cli_opts }} {{ galaxy_verbosity }} {{ ignore_flags }}
register: install_req
vars:
req_file: "{{ galaxy_dir }}/ansible_collections/requirements.yaml"
cli_opts: "-s {{ test_name }} --keyring {{ keyring }} --force"
keyring: "{{ gpg_homedir }}/pubring.kbx"
ignore_errors: "--ignore-signature-status-code BADSIG --ignore-signature-status-code FAILURE"
ignore_flags: "--ignore-signature-status-code BADSIG --ignore-signature-status-code FAILURE"
environment:
ANSIBLE_COLLECTIONS_PATH: '{{ galaxy_dir }}/ansible_collections'
ANSIBLE_GALAXY_REQUIRED_VALID_SIGNATURE_COUNT: all
@@ -735,13 +735,13 @@
# test --ignore-signature-status-code passed once with a list
- name: reinstall collections with only one valid signature by ignoring the other errors
command: ansible-galaxy install -r {{ req_file }} {{ cli_opts }} {{ galaxy_verbosity }} {{ ignore_errors }}
command: ansible-galaxy install -r {{ req_file }} {{ cli_opts }} {{ galaxy_verbosity }} {{ ignore_flags }}
register: install_req
vars:
req_file: "{{ galaxy_dir }}/ansible_collections/requirements.yaml"
cli_opts: "-s {{ test_name }} --keyring {{ keyring }} --force"
keyring: "{{ gpg_homedir }}/pubring.kbx"
ignore_errors: "--ignore-signature-status-codes BADSIG FAILURE"
ignore_flags: "--ignore-signature-status-codes BADSIG FAILURE"
environment:
ANSIBLE_COLLECTIONS_PATH: '{{ galaxy_dir }}/ansible_collections'
ANSIBLE_GALAXY_REQUIRED_VALID_SIGNATURE_COUNT: all