Do not interpolate values from tox --showconfig

Change-Id: I8ffa7d164e0afd2a325bc5b4d76d4dc75d330739
This commit is contained in:
Albin Vass 2020-05-20 09:09:08 +02:00
parent faa890582f
commit 30bc5d67ff
3 changed files with 11 additions and 7 deletions

View File

@ -272,7 +272,7 @@ def main():
tox_envlist = module.params.get('tox_envlist', '')
tox_show_config = module.params.get('tox_show_config')
tox_config = configparser.ConfigParser()
tox_config = configparser.RawConfigParser()
tox_config.read(tox_show_config)
envlist = {testenv.strip() for testenv

View File

@ -10,3 +10,6 @@ commands = sh -c "echo linters >> {posargs}"
[testenv:non-default]
commands = sh -c "echo non-default >> {posargs}"
[testenv:%s]
commands = sh -c "echo working"

View File

@ -32,9 +32,6 @@
tox_extra_args: "{{ default_tempfile.path }}"
tox_install_siblings: false
tox_envlist: ''
tox_environment:
ANSIBLE_ROLES_PATH: "{{ ansible_user_dir }}/{{ zuul.project.src_dir }}/roles"
ANSIBLE_LIBRARY: "{{ ansible_user_dir }}/{{ zuul.project.src_dir }}/tests/fake-ansible"
- name: Make sure magic lines are present
lineinfile:
@ -62,9 +59,6 @@
tox_install_siblings: false
tox_extra_args: "{{ ALL_tempfile.path }}"
tox_envlist: 'ALL'
tox_environment:
ANSIBLE_ROLES_PATH: "{{ ansible_user_dir }}/{{ zuul.project.src_dir }}/roles"
ANSIBLE_LIBRARY: "{{ ansible_user_dir }}/{{ zuul.project.src_dir }}/tests/fake-ansible"
always:
- name: Make sure magic lines are present
loop:
@ -76,3 +70,10 @@
check_mode: true
register: ALL_status
failed_when: ALL_status is changed
- name: Run tox with tox_envlist = %s
include_role:
name: tox
vars:
zuul_work_dir: "{{ zuul.project.src_dir }}/test-playbooks/python/"
tox_envlist: '%s'