diff --git a/tests/bsim/bluetooth/host/misc/conn_stress/scripts/_conn_stress.sh b/tests/bsim/bluetooth/host/misc/conn_stress/scripts/_conn_stress.sh index 94228bdc986..4b10172cdd3 100755 --- a/tests/bsim/bluetooth/host/misc/conn_stress/scripts/_conn_stress.sh +++ b/tests/bsim/bluetooth/host/misc/conn_stress/scripts/_conn_stress.sh @@ -2,6 +2,8 @@ # Copyright (c) 2023 Nordic Semiconductor # SPDX-License-Identifier: Apache-2.0 +source ${ZEPHYR_BASE}/tests/bsim/sh_common.source + simulation_id="conn_stress" process_ids=""; exit_code=0 @@ -20,28 +22,23 @@ function Execute(){ echo "Running $@" } -: "${BSIM_OUT_PATH:?BSIM_OUT_PATH must be defined}" - -#Give a default value to BOARD if it does not have one yet: -BOARD="${BOARD:-nrf52_bsim}" - test_path="bsim_bluetooth_host_misc_conn_stress" bsim_central_exe_name="bs_nrf52_${test_path}_central_prj_conf" bsim_peripheral_exe_name="bs_nrf52_${test_path}_peripheral_prj_conf" # terminate running simulations (if any) -${BSIM_COMPONENTS_PATH}/common/stop_bsim.sh +${BSIM_COMPONENTS_PATH}/common/stop_bsim.sh $simulation_id # (re)Build the central & peripheral images. Don't continue if build fails. west build -b ${BOARD} -d build_central central && \ cp build_central/zephyr/zephyr.exe \ "${BSIM_OUT_PATH}/bin/${bsim_central_exe_name}" \ - || exit + || exit 1 west build -b ${BOARD} -d build_peripheral peripheral && \ cp build_peripheral/zephyr/zephyr.exe \ "${BSIM_OUT_PATH}/bin/${bsim_peripheral_exe_name}" \ - || exit + || exit 1 cd ${BSIM_OUT_PATH}/bin