---
- name: "Ipv4: Check if 10.0.0.0/8 is a valid IPV4 address"
  ansible.builtin.assert:
    that: "{{ '10.0.0.0/8' is ansible.utils.ipv4 }}"

- name: "Ipv4: Check if 192.168.1.250 is a valid IPV4 address"
  ansible.builtin.assert:
    that: "{{ '192.168.1.250' is ansible.utils.ipv4 }}"

- name: "Ipv4: Test invalidness"
  ansible.builtin.set_fact:
    criteria_check1: "{{ 'fe80::216:3eff:fee4:16f3' is ansible.utils.ipv4 }}"

- name: "Ipv4: Assert invalidness"
  ansible.builtin.assert:
    that: "{{ criteria_check1 == false }}"

- name: "Ipv4: Test invalidness"
  ansible.builtin.set_fact:
    criteria_check2: "{{ 'string' is ansible.utils.ipv4 }}"

- name: "Ipv4: Assert invalidness"
  ansible.builtin.assert:
    that: "{{ criteria_check2 == false }}"
