
Create a set of roles to be composed into a new infrared plugin. The final goal for these roles is to be used for either downstream and upstream CI Change-Id: I48d5f500c2e694c3f94ee497a0df1d92b6c411b3
55 lines
1.3 KiB
YAML
55 lines
1.3 KiB
YAML
---
|
|
|
|
- hosts: '{{ test_host }}'
|
|
gather_facts: yes
|
|
any_errors_fatal: yes
|
|
roles:
|
|
|
|
- role: tobiko-common
|
|
|
|
- role: tobiko-deploy
|
|
vars:
|
|
src_dir: '{{ tobiko_src_dir }}'
|
|
dest_dir: '{{ tobiko_dir }}'
|
|
git_repo: '{{ tobiko_git_repo }}'
|
|
git_refspec: '{{ tobiko_git_refspec }}'
|
|
git_version: '{{ tobiko_git_version }}'
|
|
when:
|
|
- test_stage in ['all', 'pre-run', 'deploy', 'deploy-tobiko']
|
|
|
|
- role: tobiko-deploy
|
|
vars:
|
|
src_dir: '{{ test_src_dir }}'
|
|
dest_dir: '{{ test_dir }}'
|
|
git_repo: '{{ test_git_repo }}'
|
|
git_refspec: '{{ test_git_refspec }}'
|
|
git_version: '{{ test_git_version }}'
|
|
when:
|
|
- test_stage in ['all', 'pre-run', 'deploy', 'deploy-test']
|
|
- tobiko_dir != test_dir
|
|
|
|
- role: tobiko-configure
|
|
when:
|
|
- test_stage in ['all', 'pre-run', 'configure']
|
|
|
|
- role: tobiko-tox
|
|
ignore_errors: yes
|
|
when:
|
|
- test_stage in ['all', 'run', 'tox']
|
|
|
|
- role: tobiko-collect
|
|
when:
|
|
- test_stage in ['all', 'post-run', 'collect']
|
|
|
|
|
|
- hosts: '{{ test_host }}'
|
|
tasks:
|
|
|
|
- name: 'report test failure'
|
|
debug:
|
|
msg: 'Test cases have failed'
|
|
failed_when: yes
|
|
when:
|
|
- run_tox is defined
|
|
- run_tox is failed
|