mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-13 01:24:22 -07:00
(cherry picked from commit fc817601bc
)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
parent
3182be1a2f
commit
ad2d899713
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