Remove vyos_facts neighbors integration tests (#27957)

The tests rely on setting the lldp IP on the management interface.
However, the IP discovered is the private IP of the node, and tests
require accessing it via Nodepool node public IP.
Removing that test for now to get CI green again, we'll reasses once we
release 2.4.
pull/24841/merge
Ricardo Carrillo Cruz 7 years ago committed by GitHub
parent 3241b7116e
commit 9f26b853e8

@ -1,51 +0,0 @@
- name: get eth0 ip address
vyos_command:
commands:
- show interfaces ethernet eth0
register: eth0_ip
# if there is no ip assigned to eth0, skip this
- block:
- set_fact:
vyos_lldp_node: "{{ eth0_ip.stdout_lines[0][2] | regex_replace('.*inet ', '') | regex_replace('/.*', '') }}"
- name: start LLDP
vyos_config:
lines:
- set service lldp
- set service lldp management-address {{ vyos_lldp_node }}
- debug: var=vyos_lldp_node
- name: wait for LLDP to start up. If this fails check that vyos_lldp_node is a valid ip address
vyos_command:
commands:
- show lldp neighbors detail
register: neighbors
until: neighbors.stdout_lines[0]|length > 3
retries: 5
delay: 5
- name: collect neighbor facts from the device
vyos_facts:
gather_subset: neighbors
# provider: {{ cli }}
register: result
- debug: var=result.ansible_facts.ansible_net_neighbors
- name: check ansible_net_neighbors
assert:
that:
- result.ansible_facts.ansible_net_neighbors is defined
# - result.ansible_facts.ansible_net_neighbors.eth0 is defined
- result.ansible_facts.ansible_net_neighbors|length > 0
always:
- name: stop lldp
vyos_config:
lines:
- delete service lldp
- delete service lldp management-address {{ vyos_lldp_node }}
when: "'inet' in eth0_ip.stdout[0]"
Loading…
Cancel
Save