mirror of
https://github.com/espressif/openthread.git
synced 2026-09-07 17:50:09 +00:00
[script] use real time when run expect tests (#5130)
This commit is contained in:
+13
-2
@@ -44,7 +44,6 @@ readonly NODE_TYPE="${NODE_TYPE:-sim}"
|
||||
readonly OT_NATIVE_IP="${OT_NATIVE_IP:-0}"
|
||||
readonly THREAD_VERSION="${THREAD_VERSION:-1.1}"
|
||||
readonly VERBOSE="${VERBOSE:-0}"
|
||||
readonly VIRTUAL_TIME="${VIRTUAL_TIME:-1}"
|
||||
|
||||
build_simulation()
|
||||
{
|
||||
@@ -347,6 +346,18 @@ envsetup()
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ ! ${VIRTUAL_TIME+x} ]]; then
|
||||
# All expect tests only works in real time mode.
|
||||
VIRTUAL_TIME=1
|
||||
for arg in "$@"; do
|
||||
if [[ $arg == expect ]]; then
|
||||
VIRTUAL_TIME=0
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
readonly VIRTUAL_TIME
|
||||
export NODE_TYPE VIRTUAL_TIME
|
||||
|
||||
# CMake always works in verbose mode if VERBOSE exists in environments.
|
||||
@@ -365,7 +376,7 @@ envsetup()
|
||||
|
||||
main()
|
||||
{
|
||||
envsetup
|
||||
envsetup "$@"
|
||||
|
||||
if [[ -z $1 ]]; then
|
||||
print_usage 1
|
||||
|
||||
Reference in New Issue
Block a user