You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ansible/test/integration/targets/rds_instance/tasks/credential_tests.yml

37 lines
897 B
YAML

---
- name: test without credentials
rds_instance:
db_instance_identifier: test-rds-instance
register: result
ignore_errors: yes
- assert:
that:
- result.failed
- 'result.msg == "The rds_instance module requires a region and none was found in configuration, environment variables or module parameters"'
- name: test without credentials
rds_instance:
db_instance_identifier: test-rds-instance
region: us-east-1
register: result
ignore_errors: yes
- assert:
that:
- result.failed
- '"Unable to locate credentials" in result.msg'
- name: test with invalid credentials
rds_instance:
db_instance_identifier: test-rds-instance
region: us-east-1
profile: doesnotexist
register: result
ignore_errors: yes
- assert:
that:
- result.failed
- 'result.msg == "The config profile (doesnotexist) could not be found"'