2017-11-21 13:24:48 +01:00
|
|
|
---
|
|
|
|
|
|
|
|
- name: Make sure test bridge does not exist before tests
|
|
|
|
command: ovs-vsctl del-br br-test
|
2017-11-21 13:34:27 +01:00
|
|
|
ignore_errors: yes
|
2017-11-21 13:24:48 +01:00
|
|
|
|
|
|
|
- name: Create bridge
|
|
|
|
openvswitch_bridge:
|
|
|
|
bridge: br-test
|
|
|
|
register: result
|
|
|
|
|
|
|
|
- assert:
|
|
|
|
that:
|
|
|
|
- "result.changed == true"
|
|
|
|
|
|
|
|
- name: Create bridge again (idempotent)
|
|
|
|
openvswitch_bridge:
|
|
|
|
bridge: br-test
|
|
|
|
register: result
|
|
|
|
|
|
|
|
- assert:
|
|
|
|
that:
|
|
|
|
- "result.changed == false"
|
|
|
|
|
|
|
|
- name: Tear down test bridge
|
|
|
|
command: ovs-vsctl del-br br-test
|