diff --git a/backends/arm/test/runner_utils.py b/backends/arm/test/runner_utils.py index f0a1c540e3d..2c76af1b779 100644 --- a/backends/arm/test/runner_utils.py +++ b/backends/arm/test/runner_utils.py @@ -714,7 +714,9 @@ def assert_elf_path_exists(elf_path): ) -def get_elf_path(target_board: str, use_portable_ops: bool = False): +def get_elf_path(target_board: str, use_portable_ops: bool = False) -> str: + elf_path = "" + if target_board not in VALID_TARGET: raise ValueError(f"Unsupported target: {target_board}") @@ -729,14 +731,13 @@ def get_elf_path(target_board: str, use_portable_ops: bool = False): f"arm_semihosting_executor_runner_{portable_ops_str}{target_board}", "arm_executor_runner", ) - assert_elf_path_exists(elf_path) elif target_board == "vkml_emulation_layer": elf_path = os.path.join( f"arm_test/arm_executor_runner_{portable_ops_str}vkml", "executor_runner", ) - assert_elf_path_exists(elf_path) + assert_elf_path_exists(elf_path) return elf_path