Skip to content

Commit f700abb

Browse files
committed
tests/functional/test_migration: Use "ncat" instead of "nc" in the exec test
"nc" can either be GNU netcat, OpenBSD netcat or NMap ncat. At least GNU netcat currently does not work with this test anymore, though the comment in the test says otherwise. GNU netcat seems to be quite unmaintained nowadays, according to its website (https://netcat.sourceforge.net/), the last public release is from 2004, so we should rather avoid that binary. In our CI, we are only using "ncat" in the containers (it's the only flavor that lcitool supports), thus to avoid silent regressions with the other netcats, let's limit this test to "ncat" only now. Reported-by: Matheus Tavares Bernardino <[email protected]> Message-ID: <[email protected]> Reviewed-by: Matheus Tavares Bernardino <[email protected]> Reviewed-by: Philippe Mathieu-Daudé <[email protected]> Acked-by: Fabiano Rosas <[email protected]> Signed-off-by: Thomas Huth <[email protected]>
1 parent 1ddd4d3 commit f700abb

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

tests/functional/test_migration.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,13 +87,12 @@ def test_migration_with_unix(self):
8787
dest_uri = 'unix:%s/qemu-test.sock' % socket_path
8888
self.do_migrate(dest_uri)
8989

90-
@skipIfMissingCommands('nc')
90+
@skipIfMissingCommands('ncat')
9191
def test_migration_with_exec(self):
92-
"""The test works for both netcat-traditional and netcat-openbsd packages."""
9392
with Ports() as ports:
9493
free_port = self._get_free_port(ports)
95-
dest_uri = 'exec:nc -l localhost %u' % free_port
96-
src_uri = 'exec:nc localhost %u' % free_port
94+
dest_uri = 'exec:ncat -l localhost %u' % free_port
95+
src_uri = 'exec:ncat localhost %u' % free_port
9796
self.do_migrate(dest_uri, src_uri)
9897

9998
if __name__ == '__main__':

0 commit comments

Comments
 (0)