diff mbox series

[v2,2/9] oe-selftest: devtool ide-sdk: do not guess the slirp SSH port

Message ID 20260907063720.56742-3-adrian.freihofer@siemens.com
State Under Review
Headers show
Series devtool: ide-sdk: bug fixes, do_install-through-bitbake, NFS deploy prep | expand

Commit Message

AdrianF Sept. 7, 2026, 6:36 a.m. UTC
From: Adrian Freihofer <adrian.freihofer@siemens.com>

Falling back to a hardcoded 2222 hides the case where runqemu did not
report an ip:port pair: the test would then keep running against a port
that nothing listens on and fail somewhere further down. Assert the port
instead, so the failure points at its actual cause.

Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com>
---
 meta/lib/oeqa/selftest/cases/devtool.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/meta/lib/oeqa/selftest/cases/devtool.py b/meta/lib/oeqa/selftest/cases/devtool.py
index de59feadb8..3a407a5162 100644
--- a/meta/lib/oeqa/selftest/cases/devtool.py
+++ b/meta/lib/oeqa/selftest/cases/devtool.py
@@ -3991,7 +3991,8 @@  class DevtoolIdeSdkGccTests(DevtoolIdeSdkTests):
 
         with runqemu(testimage, runqemuparams="nographic slirp") as qemu:
             slirp_host = qemu.ip
-            slirp_port = qemu.port or '2222'
+            self.assertIsNotNone(qemu.port, 'No SSH port for the slirp target')
+            slirp_port = qemu.port
 
             # Re-run ide-sdk with the actual slirp address; image is already built.
             bitbake_sdk_cmd = (