Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix testing the right targets on CI #461

Merged
merged 1 commit into from
Jul 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion ci/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,5 @@ if [ "$WASI_SDK_CI_SKIP_TESTS" = "1" ]; then
fi

# Run tests to ensure that the sysroot works.
ctest --output-on-failure --parallel 10 --test-dir $build_dir/sysroot/tests
ctest --output-on-failure --parallel 10 --test-dir $build_dir/sysroot/tests \
--timeout 60
2 changes: 2 additions & 0 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ function(add_testcase runwasi test)
# as well.
if(NOT(CMAKE_C_COMPILER MATCHES ${target}))
target_compile_options(${target_name} PRIVATE --target=${target})
target_link_options(${target_name} PRIVATE --target=${target})
endif()

# Apply test-specific compile options and link flags.
Expand Down Expand Up @@ -79,6 +80,7 @@ function(add_testcase runwasi test)
# Apply target-specific options.
if(target MATCHES threads)
target_compile_options(${target_name} PRIVATE -pthread)
target_link_options(${target_name} PRIVATE -pthread)
endif()

if(runwasi)
Expand Down
2 changes: 1 addition & 1 deletion tests/general/sigabrt.c.stderr.expected
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ Program received fatal signal: Aborted
Error: failed to run main module `sigabrt.c.---.wasm`

Caused by:
0: failed to invoke command default
0: failed to invoke ---
1 change: 1 addition & 0 deletions tests/general/sigabrt.c.stderr.expected.filter
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ set -euo pipefail
cat \
| sed -e 's/main module `.*sigabrt\.c\.wasm`/main module `sigabrt.c.---.wasm`/' \
| sed -e 's/source location: @[[:xdigit:]]*$/source location: @----/' \
| sed -e 's/failed to invoke.*/failed to invoke ---/' \
| head -n 6
Loading