---
# Ensure internal var __rsyslog_version is set correctly
#
# [Test scenario]
# 0. Run logging role.
#    In the execution, __rsyslog_version is set to the rsyslog version.
# 1. Check variable __rsyslog_version value is is no longer
#    the initial value "0.0.0".
#
- name: Ensure internal var __rsyslog_version is set correctly
  hosts: all
  vars:
    __rsyslog_version: "0.0.0"

  tasks:
    - name: Default run
      include_role:
        name: redhat.rhel_system_roles.logging

    - name: Check rsyslog version
      assert:
        that: __rsyslog_version != "0.0.0"
