mirror of
https://github.com/ansible/awx.git
synced 2026-01-11 10:00:01 -03:30
Add more integration tests for export collection
This commit is contained in:
parent
ac57f5cb28
commit
271613b86d
@ -61,6 +61,40 @@
|
||||
- mixed_export['assets']['organizations'] | length() == 1
|
||||
- "'workflow_job_templates' not in mixed_export['assets']"
|
||||
|
||||
- name: Export list of organizations
|
||||
export:
|
||||
organizations: "{{[org_name1, org_name2]}}"
|
||||
register: list_asserts
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- list_asserts is not changed
|
||||
- list_asserts is successful
|
||||
- list_asserts['assets']['organizations'] | length() >= 2
|
||||
|
||||
- name: Export list with one organization
|
||||
export:
|
||||
organizations: "{{[org_name1]}}"
|
||||
register: list_asserts
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- list_asserts is not changed
|
||||
- list_asserts is successful
|
||||
- list_asserts['assets']['organizations'] | length() >= 1
|
||||
- "org_name1 in (list_asserts['assets']['organizations'] | map(attribute='name') )"
|
||||
|
||||
- name: Export one organization as string
|
||||
export:
|
||||
organizations: "{{org_name2}}"
|
||||
register: string_asserts
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- string_asserts is not changed
|
||||
- string_asserts is successful
|
||||
- string_asserts['assets']['organizations'] | length() >= 1
|
||||
- "org_name2 in (string_asserts['assets']['organizations'] | map(attribute='name') )"
|
||||
always:
|
||||
- name: Remove our inventory
|
||||
inventory:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user