This commit is contained in:
Zhenwei Jin 2026-04-17 05:17:42 +00:00 committed by GitHub
commit 6db00d0c4b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 11 additions and 3 deletions

@ -1 +1 @@
Subproject commit 746348e88ab3d32624a04a1a4a724d276057d979
Subproject commit 39919475fd538d8ef87184f9c60273f3ffcaeafc

View File

@ -46,6 +46,7 @@ function help()
(e.g., ubsan, tsan, asan, posan)."
echo "-A use the specified wamrc command instead of building it"
echo "-N enable extended const expression feature"
echo "-U enable full unit test (passes FULL_TEST=ON to cmake when -s unit is used)"
echo "-r [requirement name] [N [N ...]] specify a requirement name followed by one or more"
echo " subrequirement IDs, if no subrequirement is specificed,"
echo " it will run all subrequirements. When this optin is used,"
@ -71,6 +72,7 @@ ENABLE_XIP=0
ENABLE_EH=0
ENABLE_DEBUG_VERSION=0
ENABLE_GC_HEAP_VERIFY=0
UNIT_FULL_TEST=0
#unit test case arrary
TEST_CASE_ARR=()
SGX_OPT=""
@ -93,7 +95,7 @@ REQUIREMENT_NAME=""
# Initialize an empty array for subrequirement IDs
SUBREQUIREMENT_IDS=()
while getopts ":s:cabgvt:m:MCpSXexwWEPGQF:j:T:r:A:N" opt
while getopts ":s:cabgvt:m:MCpSXexwWEPGQF:j:T:r:A:NU" opt
do
OPT_PARSED="TRUE"
case $opt in
@ -201,6 +203,10 @@ do
echo "enable extended const expression feature"
ENABLE_EXTENDED_CONST_EXPR=1
;;
U)
echo "enable full unit test (FULL_TEST=ON)"
UNIT_FULL_TEST=1
;;
P)
PARALLELISM=1
;;
@ -336,7 +342,9 @@ function unit_test()
echo "Build unit test"
touch ${REPORT_DIR}/unit_test_report.txt
cmake -S ${WORK_DIR}/../../unit -B unittest-build \
-DCOLLECT_CODE_COVERAGE=${COLLECT_CODE_COVERAGE}
-DCOLLECT_CODE_COVERAGE=${COLLECT_CODE_COVERAGE} \
-DFULL_TEST=${UNIT_FULL_TEST} \
-DWAMRC_COMPILER_DIR=${WAMR_DIR}/wamr-compiler/build
cmake --build unittest-build
ctest --test-dir unittest-build --output-on-failure | tee -a ${REPORT_DIR}/unit_test_report.txt