ab26d8263a
This patch brings out the improvements done from tripleo-validations to validations-common regarding the molecule testing infrastructure with the UBI8 images. This patch integrates molecule fix after release of cryptography3.4. See https://review.opendev.org/c/openstack/tripleo-validations/+/774747 Related-Bug: #1915101 Co-Authored-By: David Vallee Delisle <dvd@redhat.com> Change-Id: I2e5ebebdd48e4013aa87868a22807e91feb3ffab Signed-off-by: Gael Chamoulaud (Strider) <gchamoul@redhat.com>
40 lines
1.5 KiB
YAML
40 lines
1.5 KiB
YAML
---
|
|
- hosts: all
|
|
environment:
|
|
ANSIBLE_LOG_PATH: "{{ ansible_user_dir }}/zuul-output/logs/ansible-execution.log"
|
|
pre_tasks:
|
|
|
|
- name: Set project path fact
|
|
set_fact:
|
|
validations_common_project_path: "{{ ansible_user_dir }}/{{ zuul.projects['opendev.org/openstack/validations-common'].src_dir }}"
|
|
|
|
- name: Set roles path fact
|
|
set_fact:
|
|
validations_common_roles_paths:
|
|
- "{{ validations_common_project_path }}/validations_common/roles"
|
|
- "/usr/share/ansible/roles"
|
|
|
|
- name: Set library path fact
|
|
set_fact:
|
|
validations_common_library_paths:
|
|
- "{{ validations_common_project_path }}/validations_common/library"
|
|
- "/usr/share/ansible/library"
|
|
|
|
tasks:
|
|
- name: Run role test job
|
|
shell: |-
|
|
. {{ ansible_user_dir }}/test-python/bin/activate
|
|
. {{ validations_common_project_path }}/ansible-test-env.rc
|
|
pytest --color=yes \
|
|
--html={{ ansible_user_dir }}/zuul-output/logs/reports.html \
|
|
--self-contained-html \
|
|
--ansible-args='{{ tripleo_job_ansible_args | default("") }}' \
|
|
{{ validations_common_project_path }}/tests/test_molecule.py
|
|
args:
|
|
chdir:
|
|
"{{ validations_common_project_path }}/validations_common/roles/{{ validations_common_role_name }}"
|
|
executable: /bin/bash
|
|
environment:
|
|
ANSIBLE_ROLES_PATH: "{{ validations_common_roles_paths | join(':') }}"
|
|
ANSIBLE_LIBRARY: "{{ validations_common_library_paths | join(':') }}"
|