Updated pip module to always return changed if venv is created (#24233)

* Updated pip module to always return changed if venv is created

Fixes #23204

* Add integration test to pip (see #23204)
This commit is contained in:
Nicklaus McClendon 2017-09-12 12:01:29 -05:00 committed by Toshio Kuratomi
commit 6dbc3c63f8
2 changed files with 21 additions and 1 deletions

View file

@ -166,3 +166,20 @@
assert:
that:
- "not q_check_mode.changed"
# ansible#23204
- name: ensure is a fresh virtualenv
file:
state: absent
name: "{{ output_dir }}/pipenv"
- name: install pip throught pip into fresh virtualenv
pip:
name: pip
virtualenv: "{{ output_dir }}/pipenv"
register: pip_install_venv
- name: make sure pip in fresh virtualenv report changed
assert:
that:
- "pip_install_venv.changed"