From: Michal Privoznik <mprivozn@redhat.com>
Soon, individual test cases of networkxml2xmltest will be subject
to networkValidate() call. This means, that input XMLs must be
valid (or marked as expected fail). Anyway, there are couple of
offenders:
1) 8021Qbh-net.xml setting vlan for <forward mode='private'/> is
unsupported,
2) hostdev.xml networkValidate() will check if hostdevs specified
for <forward mode='hostdev'/> are VFs. Use PCI addresses from
virpcimock.
3) openvswitch-net.xml for <forward mode='bridge'/> only
openvswitch type of virtualports is allowed.
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
---
tests/networkxml2xmlin/8021Qbh-net.xml | 3 ---
tests/networkxml2xmlin/hostdev.xml | 6 ++----
tests/networkxml2xmlin/openvswitch-net.xml | 6 +++---
tests/networkxml2xmlout/8021Qbh-net.xml | 3 ---
tests/networkxml2xmlout/hostdev.xml | 6 ++----
tests/networkxml2xmlout/openvswitch-net.xml | 6 +++---
tests/networkxml2xmlupdateout/openvswitch-net-modified.xml | 4 ++--
.../openvswitch-net-more-portgroups.xml | 6 +++---
.../openvswitch-net-without-alice.xml | 4 ++--
9 files changed, 17 insertions(+), 27 deletions(-)
diff --git a/tests/networkxml2xmlin/8021Qbh-net.xml b/tests/networkxml2xmlin/8021Qbh-net.xml
index 3aaab61db6..2d779dcac0 100644
--- a/tests/networkxml2xmlin/8021Qbh-net.xml
+++ b/tests/networkxml2xmlin/8021Qbh-net.xml
@@ -8,9 +8,6 @@
<interface dev="eth4"/>
<interface dev="eth5"/>
</forward>
- <vlan>
- <tag id='549'/>
- </vlan>
<virtualport type="802.1Qbh">
<parameters profileid="spongebob24"/>
</virtualport>
diff --git a/tests/networkxml2xmlin/hostdev.xml b/tests/networkxml2xmlin/hostdev.xml
index 03f141106f..94974804a7 100644
--- a/tests/networkxml2xmlin/hostdev.xml
+++ b/tests/networkxml2xmlin/hostdev.xml
@@ -2,9 +2,7 @@
<name>hostdev</name>
<uuid>81ff0d90-c91e-6742-64da-4a736edb9a9b</uuid>
<forward mode='hostdev' managed='yes'>
- <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x1'/>
- <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x2'/>
- <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x3'/>
- <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x4'/>
+ <address type='pci' domain='0x0000' bus='0x06' slot='0x12' function='0x1'/>
+ <address type='pci' domain='0x0000' bus='0x06' slot='0x12' function='0x2'/>
</forward>
</network>
diff --git a/tests/networkxml2xmlin/openvswitch-net.xml b/tests/networkxml2xmlin/openvswitch-net.xml
index 2f6084d690..30c1e2af10 100644
--- a/tests/networkxml2xmlin/openvswitch-net.xml
+++ b/tests/networkxml2xmlin/openvswitch-net.xml
@@ -7,7 +7,7 @@
<vlan trunk='yes'>
<tag id='666'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='bob-profile'/>
</virtualport>
</portgroup>
@@ -17,7 +17,7 @@
<tag id='888'/>
<tag id='999'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='alice-profile'/>
</virtualport>
</portgroup>
@@ -26,7 +26,7 @@
<tag id='123' nativeMode='tagged'/>
<tag id='444'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='native-profile'/>
</virtualport>
</portgroup>
diff --git a/tests/networkxml2xmlout/8021Qbh-net.xml b/tests/networkxml2xmlout/8021Qbh-net.xml
index 281466a9f7..d4d5b4b443 100644
--- a/tests/networkxml2xmlout/8021Qbh-net.xml
+++ b/tests/networkxml2xmlout/8021Qbh-net.xml
@@ -8,9 +8,6 @@
<interface dev='eth4'/>
<interface dev='eth5'/>
</forward>
- <vlan>
- <tag id='549'/>
- </vlan>
<virtualport type='802.1Qbh'>
<parameters profileid='spongebob24'/>
</virtualport>
diff --git a/tests/networkxml2xmlout/hostdev.xml b/tests/networkxml2xmlout/hostdev.xml
index 03f141106f..94974804a7 100644
--- a/tests/networkxml2xmlout/hostdev.xml
+++ b/tests/networkxml2xmlout/hostdev.xml
@@ -2,9 +2,7 @@
<name>hostdev</name>
<uuid>81ff0d90-c91e-6742-64da-4a736edb9a9b</uuid>
<forward mode='hostdev' managed='yes'>
- <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x1'/>
- <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x2'/>
- <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x3'/>
- <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x4'/>
+ <address type='pci' domain='0x0000' bus='0x06' slot='0x12' function='0x1'/>
+ <address type='pci' domain='0x0000' bus='0x06' slot='0x12' function='0x2'/>
</forward>
</network>
diff --git a/tests/networkxml2xmlout/openvswitch-net.xml b/tests/networkxml2xmlout/openvswitch-net.xml
index 2f6084d690..30c1e2af10 100644
--- a/tests/networkxml2xmlout/openvswitch-net.xml
+++ b/tests/networkxml2xmlout/openvswitch-net.xml
@@ -7,7 +7,7 @@
<vlan trunk='yes'>
<tag id='666'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='bob-profile'/>
</virtualport>
</portgroup>
@@ -17,7 +17,7 @@
<tag id='888'/>
<tag id='999'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='alice-profile'/>
</virtualport>
</portgroup>
@@ -26,7 +26,7 @@
<tag id='123' nativeMode='tagged'/>
<tag id='444'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='native-profile'/>
</virtualport>
</portgroup>
diff --git a/tests/networkxml2xmlupdateout/openvswitch-net-modified.xml b/tests/networkxml2xmlupdateout/openvswitch-net-modified.xml
index cc0c344c1b..d52e91e564 100644
--- a/tests/networkxml2xmlupdateout/openvswitch-net-modified.xml
+++ b/tests/networkxml2xmlupdateout/openvswitch-net-modified.xml
@@ -7,7 +7,7 @@
<vlan trunk='yes'>
<tag id='666'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='bob-profile'/>
</virtualport>
</portgroup>
@@ -26,7 +26,7 @@
<tag id='123' nativeMode='tagged'/>
<tag id='444'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='native-profile'/>
</virtualport>
</portgroup>
diff --git a/tests/networkxml2xmlupdateout/openvswitch-net-more-portgroups.xml b/tests/networkxml2xmlupdateout/openvswitch-net-more-portgroups.xml
index 7c19ad9f48..069b2a01d8 100644
--- a/tests/networkxml2xmlupdateout/openvswitch-net-more-portgroups.xml
+++ b/tests/networkxml2xmlupdateout/openvswitch-net-more-portgroups.xml
@@ -18,7 +18,7 @@
<vlan trunk='yes'>
<tag id='666'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='bob-profile'/>
</virtualport>
</portgroup>
@@ -28,7 +28,7 @@
<tag id='888'/>
<tag id='999'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='alice-profile'/>
</virtualport>
</portgroup>
@@ -37,7 +37,7 @@
<tag id='123' nativeMode='tagged'/>
<tag id='444'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='native-profile'/>
</virtualport>
</portgroup>
diff --git a/tests/networkxml2xmlupdateout/openvswitch-net-without-alice.xml b/tests/networkxml2xmlupdateout/openvswitch-net-without-alice.xml
index 41044240df..2fb0cf9f6d 100644
--- a/tests/networkxml2xmlupdateout/openvswitch-net-without-alice.xml
+++ b/tests/networkxml2xmlupdateout/openvswitch-net-without-alice.xml
@@ -7,7 +7,7 @@
<vlan trunk='yes'>
<tag id='666'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='bob-profile'/>
</virtualport>
</portgroup>
@@ -16,7 +16,7 @@
<tag id='123' nativeMode='tagged'/>
<tag id='444'/>
</vlan>
- <virtualport>
+ <virtualport type='openvswitch'>
<parameters profileid='native-profile'/>
</virtualport>
</portgroup>
--
2.52.0