From 13869944f33c81f0f4cc9e2e316343f94aaf7fee Mon Sep 17 00:00:00 2001
From: Martin Pitt <martin@piware.de>
Date: Thu, 18 Feb 2021 10:12:58 +0100
Subject: [PATCH] test: Check os-release instead of /dev/kvm for Machines tests

Commit e17149cb did not work as intended -- the RHEL gating machines
also don't have /dev/kvm, but are still powerful enough to run all
Machines tests. So consult /etc/os-release instead of /dev/kvm.
---
 tests/run-test.sh | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tests/run-test.sh b/tests/run-test.sh
index ae63992..c587338 100755
--- a/tests/run-test.sh
+++ b/tests/run-test.sh
@@ -53,10 +53,10 @@ if [ -n "$test_optional" ]; then
          TestUpdates.testSecurityOnly"
 
     # Fedora gating tests are running on infra without /dev/kvm; Machines tests are too darn slow there
-    if [ -w /dev/kvm ]; then
-        TESTS="$TESTS TestMachines"
-    else
+    if [ "$ID" = "fedora" ]; then
         TESTS="$TESTS TestMachinesCreate.testCreateImportDisk"
+    else
+        TESTS="$TESTS TestMachines"
     fi
 fi