tests/functional/migration.py: Skip migration_with_exec() if socat is not available
Commit 643a171f5668 ("tests: Replace ncat with socat in migration test and drop ncat from containers") replaced ncat with socat, but missed to skip related test cases if socat is not available, which will cause test errors on the system without socat. Fix this by checking socat instead of the original ncat. Fixes: 643a171f5668 ("tests: Replace ncat with socat in migration test and drop ncat from containers") Signed-off-by: Zhao Liu <zhao1.liu@intel.com> Message-ID: <20260330053300.2721608-1-zhao1.liu@intel.com> Reviewed-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
Zhao Liu committed
Mar 30, 2026 at 13:33 UTC
c0eaf14d93135e13d8b003f7cb41187e3510373d
1 file changed
+2
-2
tests/functional/migration.py
+2
-2
@@ -80,8 +80,8 @@ class MigrationTest(QemuSystemTest):
80
self.migrate(dst_uri)
81
82
def migration_with_exec(self):
83
- if not which('ncat'):
84
- self.skipTest('ncat is not available')
83
+ if not which('socat'):
84
+ self.skipTest('socat is not available')
85
with Ports() as ports:
86
free_port = self._get_free_port(ports)
87
dst_uri = 'exec:socat TCP-LISTEN:%u -' % free_port