Skip to content

Commit 78faf84

Browse files
committed
Mark network tests that don't require node's additional interfaces
Acceptance tests for new architectures, platforms etc. shouldn't depend on having extra NICs on the cluster nodes, except for the primary interface. In order to have satisfactory coveage in these tests, we mark all the these tests with the a new marker, which can and should be used for these types of tests.
1 parent 881f934 commit 78faf84

16 files changed

+34
-0
lines changed

pytest.ini

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ markers =
3636
hugepages: tests that require nodes with hugepages
3737
service_mesh: tests that require the service mesh operator to be installed
3838
jumbo_frame: tests that require network configurations supporting jumbo frames
39+
single_nic: tests that dont require mutli-nic nodes, required for conformance tests for new archs, platforms etc.
3940
# CI
4041
smoke: Mark tests as smoke tests
4142
ci: Mark tests as CI tests

tests/network/cluster_addons_operator/test_network_addons_operator.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,7 @@ def net_add_op_bridge_attached_vm(namespace, net_add_op_br1test_nad):
215215

216216
@pytest.mark.gating
217217
@pytest.mark.post_upgrade
218+
@pytest.mark.single_nic
218219
@pytest.mark.polarion("CNV-2520")
219220
def test_component_installed_by_operator(network_addons_config_scope_session):
220221
"""
@@ -246,6 +247,7 @@ def test_linux_bridge_functionality(net_add_op_bridge_attached_vm):
246247

247248

248249
@pytest.mark.polarion("CNV-6754")
250+
@pytest.mark.single_nic
249251
def test_cnao_labels(
250252
admin_client,
251253
network_addons_config_scope_session,

tests/network/connectivity/test_ovs_linux_bridge.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ def test_ipv4_linux_bridge(
5050
@pytest.mark.post_upgrade
5151
@pytest.mark.polarion("CNV-11125")
5252
@pytest.mark.ipv6
53+
@pytest.mark.single_nic
5354
@pytest.mark.jira("CNV-58529", run=True)
5455
def test_ipv6_linux_bridge(
5556
self,

tests/network/connectivity/test_pod_network.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ def cloud_init_ipv6_network_data(dual_stack_network_data):
102102
indirect=False,
103103
)
104104
@pytest.mark.gating
105+
@pytest.mark.single_nic
105106
def test_connectivity_over_pod_network(
106107
ip_family,
107108
pod_net_vma,

tests/network/general/test_dhcp6_configurations_on_ipv4_single_stack_cluster.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ def listening_dhcpv6_pid_in_virt_launcher_pod(worker_node1_pod_executor, virt_la
7373

7474
@pytest.mark.polarion("CNV-7407")
7575
@pytest.mark.ipv4
76+
@pytest.mark.single_nic
7677
def test_dhcp6_disabled_on_ipv4_single_stack_cluster(
7778
fail_if_not_ipv4_single_stack_cluster,
7879
vm_cirros,

tests/network/general/test_ip_family_services.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ def expected_num_families_in_service(request, dual_stack_cluster):
105105

106106
class TestServiceConfigurationViaManifest:
107107
@pytest.mark.polarion("CNV-5789")
108+
@pytest.mark.single_nic
108109
def test_service_with_configured_ip_families(
109110
self,
110111
running_vm_for_exposure,
@@ -116,6 +117,7 @@ def test_service_with_configured_ip_families(
116117
), "Wrong ipFamilies set in service"
117118

118119
@pytest.mark.polarion("CNV-5831")
120+
@pytest.mark.single_nic
119121
def test_service_with_default_ip_family_policy(
120122
self,
121123
running_vm_for_exposure,
@@ -151,6 +153,7 @@ class TestServiceConfigurationViaVirtctl:
151153
],
152154
indirect=["virtctl_expose_service", "expected_num_families_in_service"],
153155
)
156+
@pytest.mark.single_nic
154157
def test_vitrctl_expose_services(
155158
self,
156159
expected_num_families_in_service,

tests/network/general/test_network_naming.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ def invalid_network_names():
1212

1313

1414
@pytest.mark.polarion("CNV-8304")
15+
@pytest.mark.single_nic
1516
def test_vm_with_illegal_network_name(namespace, unprivileged_client, invalid_network_names):
1617
vm_name = "unsupported-network-name-vm"
1718

tests/network/general/test_vm_ips_report.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,14 @@ def report_masquerade_ip_vmi(unprivileged_client, namespace):
3838

3939
@pytest.mark.sno
4040
@pytest.mark.polarion("CNV-4455")
41+
@pytest.mark.single_nic
4142
def test_report_masquerade_ip(report_masquerade_ip_vmi):
4243
assert_ip_mismatch(vm=report_masquerade_ip_vmi)
4344

4445

4546
@pytest.mark.gating
4647
@pytest.mark.polarion("CNV-4153")
48+
@pytest.mark.single_nic
4749
def test_report_masquerade_ip_after_migration(report_masquerade_ip_vmi):
4850
src_node = report_masquerade_ip_vmi.instance.status.nodeName
4951
with VirtualMachineInstanceMigration(

tests/network/jumbo_frame/test_pod_network_ovn.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
class TestJumboPodNetworkOnly:
1818
@pytest.mark.ipv4
1919
@pytest.mark.polarion("CNV-9660")
20+
@pytest.mark.single_nic
2021
def test_jumbo_traffic_over_pod_network_separate_nodes(
2122
self,
2223
running_vma_jumbo_primary_interface_worker_1,
@@ -31,6 +32,7 @@ def test_jumbo_traffic_over_pod_network_separate_nodes(
3132

3233
@pytest.mark.ipv4
3334
@pytest.mark.polarion("CNV-9671")
35+
@pytest.mark.single_nic
3436
def test_jumbo_traffic_over_pod_network_same_node(
3537
self,
3638
running_vma_jumbo_primary_interface_worker_1,
@@ -45,6 +47,7 @@ def test_jumbo_traffic_over_pod_network_same_node(
4547

4648
@pytest.mark.ipv4
4749
@pytest.mark.polarion("CNV-9672")
50+
@pytest.mark.single_nic
4851
def test_jumbo_negative_traffic_over_pod_network_with_oversized_traffic(
4952
self,
5053
running_vma_jumbo_primary_interface_worker_1,

tests/network/kubemacpool/test_kubemacpool.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ def test_disabled_assignment_ns(
120120

121121
@pytest.mark.sno
122122
@pytest.mark.polarion("CNV-4405")
123+
@pytest.mark.single_nic
123124
def test_kmp_down(namespace, kmp_down):
124125
with pytest.raises(ApiException):
125126
with VirtualMachineForTests(name="kmp-down-vm", namespace=namespace.name):

0 commit comments

Comments
 (0)