tests BT privacy: Simplify a bit scripts

Reduce the unnecessary hidding and indirection,
as it makes the scripts more difficult to follow
for no benefit.
If somebody wants to debug these tests, they'll want
to see the sim_id, and won't benefit from going around
opening files needlessly.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This commit is contained in:
Alberto Escolar Piedras 2023-09-25 14:34:24 +02:00 committed by Carles Cufí
commit 03b601f0a9
8 changed files with 8 additions and 12 deletions

View file

@ -5,10 +5,7 @@
set -eu set -eu
bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")" bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")"
test_name="$(basename "$(realpath "$bash_source_dir/..")")"
bsim_bin="${BSIM_OUT_PATH}/bin" bsim_bin="${BSIM_OUT_PATH}/bin"
verbosity_level=2
BOARD="${BOARD:-nrf52_bsim}" BOARD="${BOARD:-nrf52_bsim}"
simulation_id="$test_name"
central_exe="${bsim_bin}/bs_${BOARD}_tests_bsim_bluetooth_host_privacy_central_prj_conf" central_exe="${bsim_bin}/bs_${BOARD}_tests_bsim_bluetooth_host_privacy_central_prj_conf"
peripheral_exe="${central_exe}" peripheral_exe="${central_exe}"

View file

@ -8,6 +8,8 @@ bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")"
source "${bash_source_dir}/_env.sh" source "${bash_source_dir}/_env.sh"
source ${ZEPHYR_BASE}/tests/bsim/sh_common.source source ${ZEPHYR_BASE}/tests/bsim/sh_common.source
verbosity_level=2
simulation_id="$(basename "$(realpath "$bash_source_dir/..")")"
EXECUTE_TIMEOUT=30 EXECUTE_TIMEOUT=30
cd ${BSIM_OUT_PATH}/bin cd ${BSIM_OUT_PATH}/bin

View file

@ -7,9 +7,6 @@ bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")"
: "${BSIM_OUT_PATH:?BSIM_OUT_PATH must be defined}" : "${BSIM_OUT_PATH:?BSIM_OUT_PATH must be defined}"
test_name="$(basename "$(realpath "$bash_source_dir/..")")"
bsim_bin="${BSIM_OUT_PATH}/bin" bsim_bin="${BSIM_OUT_PATH}/bin"
verbosity_level=2
BOARD="${BOARD:-nrf52_bsim}" BOARD="${BOARD:-nrf52_bsim}"
simulation_id="$test_name"
test_exe="${bsim_bin}/bs_${BOARD}_tests_bsim_bluetooth_host_privacy_device_prj_conf" test_exe="${bsim_bin}/bs_${BOARD}_tests_bsim_bluetooth_host_privacy_device_prj_conf"

View file

@ -8,6 +8,8 @@ bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")"
source "${bash_source_dir}/_env.sh" source "${bash_source_dir}/_env.sh"
source ${ZEPHYR_BASE}/tests/bsim/sh_common.source source ${ZEPHYR_BASE}/tests/bsim/sh_common.source
verbosity_level=2
simulation_id="$(basename "$(realpath "$bash_source_dir/..")")"
EXECUTE_TIMEOUT=30 EXECUTE_TIMEOUT=30
cd ${BSIM_OUT_PATH}/bin cd ${BSIM_OUT_PATH}/bin

View file

@ -5,10 +5,7 @@
set -eu set -eu
bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")" bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")"
test_name="$(basename "$(realpath "$bash_source_dir/..")")"
bsim_bin="${BSIM_OUT_PATH}/bin" bsim_bin="${BSIM_OUT_PATH}/bin"
verbosity_level=2
BOARD="${BOARD:-nrf52_bsim}" BOARD="${BOARD:-nrf52_bsim}"
simulation_id="$test_name"
central_exe="${bsim_bin}/bs_${BOARD}_tests_bsim_bluetooth_host_privacy_legacy_prj_conf" central_exe="${bsim_bin}/bs_${BOARD}_tests_bsim_bluetooth_host_privacy_legacy_prj_conf"
peripheral_exe="${central_exe}" peripheral_exe="${central_exe}"

View file

@ -8,6 +8,8 @@ bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")"
source "${bash_source_dir}/_env.sh" source "${bash_source_dir}/_env.sh"
source ${ZEPHYR_BASE}/tests/bsim/sh_common.source source ${ZEPHYR_BASE}/tests/bsim/sh_common.source
verbosity_level=2
simulation_id="$(basename "$(realpath "$bash_source_dir/..")")"
EXECUTE_TIMEOUT=30 EXECUTE_TIMEOUT=30
cd ${BSIM_OUT_PATH}/bin cd ${BSIM_OUT_PATH}/bin

View file

@ -5,10 +5,7 @@
set -eu set -eu
bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")" bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")"
test_name="$(basename "$(realpath "$bash_source_dir/..")")"
bsim_bin="${BSIM_OUT_PATH}/bin" bsim_bin="${BSIM_OUT_PATH}/bin"
verbosity_level=2
BOARD="${BOARD:-nrf52_bsim}" BOARD="${BOARD:-nrf52_bsim}"
simulation_id="$test_name"
central_exe="${bsim_bin}/bs_${BOARD}_tests_bsim_bluetooth_host_privacy_peripheral_prj_conf" central_exe="${bsim_bin}/bs_${BOARD}_tests_bsim_bluetooth_host_privacy_peripheral_prj_conf"
peripheral_exe="${central_exe}" peripheral_exe="${central_exe}"

View file

@ -8,6 +8,8 @@ bash_source_dir="$(realpath "$(dirname "${BASH_SOURCE[0]}")")"
source "${bash_source_dir}/_env.sh" source "${bash_source_dir}/_env.sh"
source ${ZEPHYR_BASE}/tests/bsim/sh_common.source source ${ZEPHYR_BASE}/tests/bsim/sh_common.source
verbosity_level=2
simulation_id="$(basename "$(realpath "$bash_source_dir/..")")"
EXECUTE_TIMEOUT=30 EXECUTE_TIMEOUT=30
cd ${BSIM_OUT_PATH}/bin cd ${BSIM_OUT_PATH}/bin