summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorCornelia Huck2020-11-30 19:02:15 +0100
committerCornelia Huck2020-12-11 11:38:10 +0100
commit864852ccb8359bda6b7fc51b676b3426562715e0 (patch)
treedc8a7f917428b366b534bf6ea9787a3aead0c711 /tests
parenttests/acceptance: test virtio-ccw revision handling (diff)
downloadqemu-864852ccb8359bda6b7fc51b676b3426562715e0.tar.gz
qemu-864852ccb8359bda6b7fc51b676b3426562715e0.tar.xz
qemu-864852ccb8359bda6b7fc51b676b3426562715e0.zip
tests/acceptance: verify s390x device detection
The kernel/initrd combination does not provide the virtio-net driver; therefore, simply check whether the presented device type is indeed virtio-net for the two virtio-net-{ccw,pci} devices. Signed-off-by: Cornelia Huck <cohuck@redhat.com> [re-formatted overlong lines] Reviewed-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Message-Id: <20201130180216.15366-3-cohuck@redhat.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/acceptance/machine_s390_ccw_virtio.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/acceptance/machine_s390_ccw_virtio.py b/tests/acceptance/machine_s390_ccw_virtio.py
index c681271972..ebea1b755c 100644
--- a/tests/acceptance/machine_s390_ccw_virtio.py
+++ b/tests/acceptance/machine_s390_ccw_virtio.py
@@ -82,3 +82,14 @@ class S390CCWVirtioMachine(Test):
exec_command_and_wait_for_pattern(self,
'cat /sys/bus/ccw/devices/0.3.1234/virtio?/features',
virtio_rng_features)
+ # verify that we indeed have virtio-net devices (without having the
+ # virtio-net driver handy)
+ exec_command_and_wait_for_pattern(self,
+ 'cat /sys/bus/ccw/devices/0.1.1111/cutype',
+ '3832/01')
+ exec_command_and_wait_for_pattern(self,
+ 'cat /sys/bus/pci/devices/0005\:00\:00.0/subsystem_vendor',
+ '0x1af4')
+ exec_command_and_wait_for_pattern(self,
+ 'cat /sys/bus/pci/devices/0005\:00\:00.0/subsystem_device',
+ '0x0001')