summaryrefslogtreecommitdiffstats
path: root/test/integration/targets/ansible-galaxy-collection-cli/tasks/manifest.yml
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 16:04:21 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 16:04:21 +0000
commit8a754e0858d922e955e71b253c139e071ecec432 (patch)
tree527d16e74bfd1840c85efd675fdecad056c54107 /test/integration/targets/ansible-galaxy-collection-cli/tasks/manifest.yml
parentInitial commit. (diff)
downloadansible-core-8a754e0858d922e955e71b253c139e071ecec432.tar.xz
ansible-core-8a754e0858d922e955e71b253c139e071ecec432.zip
Adding upstream version 2.14.3.upstream/2.14.3upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'test/integration/targets/ansible-galaxy-collection-cli/tasks/manifest.yml')
-rw-r--r--test/integration/targets/ansible-galaxy-collection-cli/tasks/manifest.yml57
1 files changed, 57 insertions, 0 deletions
diff --git a/test/integration/targets/ansible-galaxy-collection-cli/tasks/manifest.yml b/test/integration/targets/ansible-galaxy-collection-cli/tasks/manifest.yml
new file mode 100644
index 0000000..5f37c72
--- /dev/null
+++ b/test/integration/targets/ansible-galaxy-collection-cli/tasks/manifest.yml
@@ -0,0 +1,57 @@
+- name: Create test collection dir
+ script: make_collection_dir.py "{{ output_dir }}/test_manifest_collection"
+ args:
+ executable: '{{ ansible_facts.python.executable }}'
+
+- name: Copy galaxy.yml with manifest_directives_full
+ copy:
+ src: galaxy.yml
+ dest: '{{ output_dir }}/test_manifest_collection/galaxy.yml'
+
+- name: Build collection
+ command: ansible-galaxy collection build --output-path {{ output_dir|quote }} -vvv
+ args:
+ chdir: '{{ output_dir }}/test_manifest_collection'
+
+- name: Get artifact contents
+ command: tar tzf '{{ output_dir }}/ns-col-1.0.0.tar.gz'
+ register: artifact_contents
+
+- debug:
+ var: artifact_contents.stdout_lines|sort
+
+- debug:
+ var: lookup('file', 'expected.txt').splitlines()|sort
+
+- assert:
+ that:
+ - artifact_contents.stdout_lines|sort == lookup('file', 'expected.txt').splitlines()|sort
+
+- name: Create test collection dir
+ script: make_collection_dir.py "{{ output_dir }}/test_manifest_no_defaults_collection"
+ args:
+ executable: '{{ ansible_facts.python.executable }}'
+
+- name: Copy galaxy.yml with manifest_directives_full
+ copy:
+ src: full_manifest_galaxy.yml
+ dest: '{{ output_dir }}/test_manifest_no_defaults_collection/galaxy.yml'
+
+- name: Build collection
+ command: ansible-galaxy collection build --output-path {{ output_dir|quote }} -vvv
+ args:
+ chdir: '{{ output_dir }}/test_manifest_no_defaults_collection'
+
+- name: Get artifact contents
+ command: tar tzf '{{ output_dir }}/ns-col-2.0.0.tar.gz'
+ register: artifact_contents
+
+- debug:
+ var: artifact_contents.stdout_lines|sort
+
+- debug:
+ var: lookup('file', 'expected_full_manifest.txt').splitlines()|sort
+
+- assert:
+ that:
+ - artifact_contents.stdout_lines|sort == lookup('file', 'expected_full_manifest.txt').splitlines()|sort