---
- hosts: localhost
remote_user: root
pre_tasks:
- package: # Install additional dependecies
name: bind-utils
state: latest
roles:
- role: standard-test-rpm
tags:
- classic
tasks:
- include_tasks: test_socket_activation.yml
when: ansible_distribution == 'Fedora'
- include_tasks: test_manual_activation.yml
- set_fact:
tests_passed: '{{ socket_activation_failed is undefined and manual_activation_failed is undefined }}'
- name: report results
debug:
msg: |
test_socket_activation: {{ 'FAILED' if socket_activation_failed is defined else 'OK'}}
test_manual_activation: {{ 'FAILED' if manual_activation_failed is defined else 'OK'}}
- name: fail playbook if tests failed
debug:
msg: --- {{ 'PASSED' if tests_passed else 'FAILED' }} ---
failed_when: not tests_passed