mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 21:00:22 -07:00
add some Tower module integration tests (and fix a bug or two) (#37421)
* add additional test coverage for tower modules * add test coverage for the tower_credential module * add test coverage for the tower_user module * fix a bug in py3 for tower_credential when ssh_key_data is specified * add test coverage for tower_host, tower_label, and tower_project * add test coverage for tower_inventory and tower_job_template * add more test coverage for tower modules - tower_job_launch - tower_job_list - tower_job_wait - tower_job_cancel * add a check mode/version assertion for tower module integration tests * add test coverage for the tower_role module * add test coverage for the tower_group module * add more integration test edge cases for various tower modules * give the job_wait module more time before failing * randomize passwords in the tower_user and tower_group tests
This commit is contained in:
parent
594840c1d6
commit
872a7b4a7a
32 changed files with 953 additions and 8 deletions
2
test/integration/targets/tower_project/aliases
Normal file
2
test/integration/targets/tower_project/aliases
Normal file
|
@ -0,0 +1,2 @@
|
|||
cloud/tower
|
||||
posix/ci/cloud/group4/tower
|
27
test/integration/targets/tower_project/tasks/main.yml
Normal file
27
test/integration/targets/tower_project/tasks/main.yml
Normal file
|
@ -0,0 +1,27 @@
|
|||
- name: Create an SCM Credential
|
||||
tower_credential:
|
||||
name: SCM Credential for Project
|
||||
organization: Default
|
||||
kind: scm
|
||||
|
||||
- name: Create a Project
|
||||
tower_project:
|
||||
name: my-project
|
||||
organization: Default
|
||||
state: present
|
||||
scm_credential: SCM Credential for Project
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- "result is changed"
|
||||
|
||||
- name: Delete a Project
|
||||
tower_project:
|
||||
name: my-project
|
||||
state: absent
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- "result is changed"
|
Loading…
Add table
Add a link
Reference in a new issue