mirror of
https://github.com/ansible/awx.git
synced 2026-05-17 06:17:36 -02:30
tower_username to controller_username, etc
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
|
||||
- name: Try to use a token as a dict which is missing the token parameter
|
||||
job_list:
|
||||
tower_oauthtoken:
|
||||
controller_oauthtoken:
|
||||
not_token: "This has no token entry"
|
||||
register: results
|
||||
ignore_errors: true
|
||||
@@ -13,11 +13,11 @@
|
||||
- assert:
|
||||
that:
|
||||
- results is failed
|
||||
- '"The provided dict in tower_oauthtoken did not properly contain the token entry" == results.msg'
|
||||
- '"The provided dict in controller_oauthtoken did not properly contain the token entry" == results.msg'
|
||||
|
||||
- name: Try to use a token as a list
|
||||
job_list:
|
||||
tower_oauthtoken:
|
||||
controller_oauthtoken:
|
||||
- dummy_token
|
||||
register: results
|
||||
ignore_errors: true
|
||||
@@ -25,7 +25,7 @@
|
||||
- assert:
|
||||
that:
|
||||
- results is failed
|
||||
- '"The provided tower_oauthtoken type was not valid (list). Valid options are str or dict." == results.msg'
|
||||
- '"The provided controller_oauthtoken type was not valid (list). Valid options are str or dict." == results.msg'
|
||||
|
||||
- name: Try to delete a token with no existing_token or existing_token_id
|
||||
token:
|
||||
@@ -63,21 +63,21 @@
|
||||
|
||||
- name: Validate our token works by token
|
||||
job_list:
|
||||
tower_oauthtoken: "{{ tower_token.token }}"
|
||||
oauthtoken: "{{ token.token }}"
|
||||
register: job_list
|
||||
|
||||
- name: Validate out token works by object
|
||||
job_list:
|
||||
tower_oauthtoken: "{{ tower_token }}"
|
||||
oauthtoken: "{{ token }}"
|
||||
register: job_list
|
||||
|
||||
always:
|
||||
- name: Delete our Token with our own token
|
||||
token:
|
||||
existing_token: "{{ tower_token }}"
|
||||
tower_oauthtoken: "{{ tower_token }}"
|
||||
existing_token: "{{ token }}"
|
||||
oauthtoken: "{{ token }}"
|
||||
state: absent
|
||||
when: tower_token is defined
|
||||
when: token is defined
|
||||
register: results
|
||||
|
||||
- assert:
|
||||
@@ -99,10 +99,10 @@
|
||||
always:
|
||||
- name: Delete the second Token with our own token
|
||||
token:
|
||||
existing_token_id: "{{ tower_token['id'] }}"
|
||||
tower_oauthtoken: "{{ tower_token }}"
|
||||
existing_token_id: "{{ token['id'] }}"
|
||||
oauthtoken: "{{ token }}"
|
||||
state: absent
|
||||
when: tower_token is defined
|
||||
when: token is defined
|
||||
register: results
|
||||
|
||||
- assert:
|
||||
|
||||
Reference in New Issue
Block a user