mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-03 12:44:22 -07:00
django_manage: add extra tests (#5476)
This commit is contained in:
parent
be0b5e5f8c
commit
fc817601bc
2 changed files with 20 additions and 0 deletions
|
@ -67,3 +67,18 @@
|
|||
project_path: "{{ tmp_django_root.path }}/simple_project/p1"
|
||||
command: collectstatic --noinput
|
||||
virtualenv: "{{ tmp_django_root.path }}/venv"
|
||||
|
||||
- name: Trigger exception with environment variable
|
||||
community.general.django_manage:
|
||||
project_path: "{{ tmp_django_root.path }}/simple_project/p1"
|
||||
command: collectstatic --noinput
|
||||
virtualenv: "{{ tmp_django_root.path }}/venv"
|
||||
environment:
|
||||
DJANGO_ANSIBLE_RAISE: blah
|
||||
ignore_errors: true
|
||||
register: env_raise
|
||||
|
||||
- name: Check env variable reached manage.py
|
||||
ansible.builtin.assert:
|
||||
that:
|
||||
- "'ValueError: DJANGO_ANSIBLE_RAISE=blah' in env_raise.msg"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue