mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 12:50:22 -07:00
dnf to support modularity module appstream specs
Fixes #48743 Signed-off-by: Adam Miller <admiller@redhat.com>
This commit is contained in:
parent
b4542e429f
commit
4a06e95671
4 changed files with 178 additions and 28 deletions
|
@ -38,3 +38,8 @@
|
|||
when:
|
||||
- ansible_distribution == 'Fedora'
|
||||
- ansible_distribution_major_version|int >= 23
|
||||
|
||||
- import_tasks: 'modularity.yml'
|
||||
when:
|
||||
- ansible_distribution == 'Fedora' and ansible_distribution_major_version|int >= 29
|
||||
- ansible_distribution == 'RedHat' and ansible_distribution_major_version|int >= 8
|
||||
|
|
48
test/integration/targets/dnf/tasks/modularity.yml
Normal file
48
test/integration/targets/dnf/tasks/modularity.yml
Normal file
|
@ -0,0 +1,48 @@
|
|||
- name: install "@postgresql:9.6/client" module
|
||||
dnf:
|
||||
name: "@postgresql:9.6/client"
|
||||
state: present
|
||||
register: dnf_result
|
||||
|
||||
- name: verify installation of "@postgresql:9.6/client" module
|
||||
assert:
|
||||
that:
|
||||
- "not dnf_result.failed"
|
||||
- "dnf_result.changed"
|
||||
|
||||
- name: install "@postgresql:9.6/client" module again
|
||||
dnf:
|
||||
name: "@postgresql:9.6/client"
|
||||
state: present
|
||||
register: dnf_result
|
||||
|
||||
- name: verify installation of "@postgresql:9.6/client" module again
|
||||
assert:
|
||||
that:
|
||||
- "not dnf_result.failed"
|
||||
- "not dnf_result.changed"
|
||||
|
||||
- name: uninstall "@postgresql:9.6/client" module
|
||||
dnf:
|
||||
name: "@postgresql:9.6/client"
|
||||
state: absent
|
||||
register: dnf_result
|
||||
|
||||
- name: verify uninstallation of "@postgresql:9.6/client" module
|
||||
assert:
|
||||
that:
|
||||
- "not dnf_result.failed"
|
||||
- "dnf_result.changed"
|
||||
|
||||
- name: uninstall "@postgresql:9.6/client" module again
|
||||
dnf:
|
||||
name: "@postgresql:9.6/client"
|
||||
state: install
|
||||
register: dnf_result
|
||||
|
||||
- name: verify uninstallation of "@postgresql:9.6/client" module again
|
||||
assert:
|
||||
that:
|
||||
- "not dnf_result.failed"
|
||||
- "not dnf_result.changed"
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue