Closed Pilzington closed 11 months ago
Looks like this when something fails:
$ make test
python3 -m pip install mock
Defaulting to user installation because normal site-packages is not writeable
Requirement already satisfied: mock in /home/alex/.local/lib/python3.10/site-packages (5.1.0)
Running tests in ./partition/roles/sonic
test_sonic_role_templates (test.template_test.SonicRoleTemplates) ... FAIL
======================================================================
FAIL: test_sonic_role_templates (test.template_test.SonicRoleTemplates)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/alex/Documents/github.com/metal-stack/metal-roles/partition/roles/sonic/test/template_test.py", line 37, in test_sonic_role_templates
self.assertEqual(metal_exp.strip(), metal_res.strip(), 'detected a diff for metal.yaml rendering - tc ' + tc)
AssertionError: '---\[340 chars]led\nfail: Ifail\nNTP:\n global:\n src_int[2710 chars]: 10' != '---\[340 chars]led\n\nNTP:\n global:\n src_intf: "eth0"\n[2699 chars]: 10'
---
DEVICE_METADATA:
localhost:
docker_routing_config_mode: split
hostname: "r01mgmtleaf"
hwsku: "Accton-AS7726-32X"
mac: "e0:01:a6:e3:29:3c"
platform: "x86_64-accton_as7726_32x-r0"
type: "LeafRouter"
frr_mgmt_framework_config: "true"
FEATURE:
dhcp_relay:
auto_restart: enabled
state: enabled
- fail: Ifail
+
NTP:
global:
src_intf: "eth0"
NTP_SERVER:
1.2.3.4: {}
LOOPBACK_INTERFACE:
Loopback0: {}
Loopback0|10.0.0.1/32: {}
MGMT_INTERFACE:
eth0|10.255.255.254/30:
gwaddr: "10.255.255.253"
MGMT_PORT:
eth0:
alias: "eth0"
admin_status: "up"
description: "Management Port"
MGMT_VRF_CONFIG:
vrf_global:
mgmtVrfEnabled: "true"
INTERFACE:
Ethernet120:
ipv6_use_link_local_only: enable
Ethernet124:
ipv6_use_link_local_only: enable
BREAKOUT_CFG:
Ethernet0:
brkout_mode: "4x25G"
Ethernet4:
brkout_mode: "1x100G[40G]"
Ethernet120:
brkout_mode: "1x100G[40G]"
Ethernet124:
brkout_mode: "1x100G[40G]"
PORT:
Ethernet0:
alias: Eth1/1(Port1)
autoneg: "off"
index: "1"
lanes: "1"
parent_port: Ethernet0
admin_status: up
speed: "1000"
mtu: "9000"
fec: "none"
Ethernet1:
alias: Eth1/2(Port1)
autoneg: "off"
index: "1"
lanes: "2"
parent_port: Ethernet0
admin_status: up
speed: "1000"
mtu: "9000"
fec: "none"
Ethernet2:
alias: Eth1/3(Port1)
autoneg: "off"
index: "1"
lanes: "3"
parent_port: Ethernet0
admin_status: up
speed: "1000"
mtu: "9000"
fec: "none"
Ethernet3:
alias: Eth1/4(Port1)
autoneg: "off"
index: "1"
lanes: "4"
parent_port: Ethernet0
admin_status: up
speed: "1000"
mtu: "9000"
fec: "none"
Ethernet4:
alias: Eth2(Port2)
autoneg: "off"
index: "2"
lanes: "5,6,7,8"
parent_port: Ethernet4
speed: "100000"
Ethernet120:
alias: Eth31(Port31)
autoneg: "off"
index: "31"
lanes: "121,122,123,124"
parent_port: Ethernet120
admin_status: up
speed: "100000"
mtu: "9216"
fec: "rs"
Ethernet124:
alias: Eth32(Port32)
autoneg: "off"
index: "32"
lanes: "125,126,127,128"
parent_port: Ethernet124
admin_status: up
speed: "100000"
mtu: "9000"
fec: "none"
VLAN:
Vlan1:
dhcp_servers: ['10.255.255.254']
vlanid: 1
Vlan2:
vlanid: 2
VLAN_INTERFACE:
Vlan1: {}
Vlan1|10.255.255.1/24: {}
Vlan2: {}
VLAN_MEMBER:
Vlan1|Ethernet0:
tagging_mode: untagged
Vlan1|Ethernet1:
tagging_mode: untagged
Vlan1|Ethernet2:
tagging_mode: untagged
Vlan1|Ethernet3:
tagging_mode: untagged
Vlan2|Ethernet4:
tagging_mode: untagged
VXLAN_EVPN_NVO:
nvo:
source_vtep: vtep
VXLAN_TUNNEL:
vtep:
src_ip: "10.0.0.1"
VXLAN_TUNNEL_MAP:
# test-vtep
"vtep|map_10002_Vlan2":
vlan: "Vlan2"
vni: "10002"
LLDP:
Global:
hello_timer: 10 : detected a diff for metal.yaml rendering - tc mgmtleaf
----------------------------------------------------------------------
Ran 1 test in 0.314s
FAILED (failures=1)
Running tests in ./partition/roles/systemd-networkd
test_template_inet_router (test.template_test.SystemdNetworkdTemplates) ... ok
test_template_vlan (test.template_test.SystemdNetworkdTemplates) ... ok
----------------------------------------------------------------------
Ran 2 tests in 0.046s
OK
Running tests in ./partition/roles/dhcp
test_dhcpd_config_template (test.template_test.DHCPD) ... ok
test_dhcpd_hosts_config_template (test.template_test.DHCPD) ... ok
----------------------------------------------------------------------
Ran 2 tests in 0.035s
OK
Running tests in ./control-plane/roles/gardener
test_cloud_profile_template_template (test.cloud_profile_template_test.CloudProfileTemplate) ... ok
test_extract_gcp_node_network (test.common_test.GCPTest) ... ok
test_image_list (test.common_test.ImageTest) ... ok
test_image_list_with_cri_mapping (test.common_test.ImageTest) ... ok
test_kubeconfig_for_sa (test.common_test.KubeconfigTest) ... ok
test_network_cidr_add (test.common_test.NetworkTest) ... ok
test_managed_seed_annotation_no_shooted_seed (test.common_test.ShootedSeedTest) ... ok
test_managed_seed_api_server_configs (test.common_test.ShootedSeedTest) ... ok
test_managed_seed_api_server_configs_with_default_replicas (test.common_test.ShootedSeedTest) ... ok
----------------------------------------------------------------------
Ran 9 tests in 0.046s
OK
One or more tests have failed.
make: *** [Makefile:4: test] Error 1
fixes #214
I am not sure why the indentation is so strange in GitHub. Locally it looks normal.