From 3374881bdd45c1212994681d9d8e3b003fce5cb3 Mon Sep 17 00:00:00 2001 From: Kamil Gierszewski Date: Thu, 2 Jan 2025 01:40:52 +0100 Subject: [PATCH] test-framework: fix config ip handle Signed-off-by: Kamil Gierszewski --- core/test_run_utils.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/test_run_utils.py b/core/test_run_utils.py index ef4f0b4..0f5326e 100644 --- a/core/test_run_utils.py +++ b/core/test_run_utils.py @@ -1,6 +1,6 @@ # # Copyright(c) 2019-2021 Intel Corporation -# Copyright(c) 2023-2024 Huawei Technologies Co., Ltd. +# Copyright(c) 2023-2025 Huawei Technologies Co., Ltd. # SPDX-License-Identifier: BSD-3-Clause # @@ -132,7 +132,8 @@ def __presetup(cls): if cls.config['type'] == 'ssh': try: IP(cls.config['ip']) - cls.config['host'] = cls.config['ip'] + if not cls.config['host']: + cls.config['host'] = cls.config['ip'] except ValueError: TestRun.block("IP address from config is in invalid format.") except KeyError: