diff options
| author | Joseph Hunkeler <jhunkeler@gmail.com> | 2026-06-30 12:19:40 -0400 |
|---|---|---|
| committer | Joseph Hunkeler <jhunkeler@gmail.com> | 2026-06-30 13:16:21 -0400 |
| commit | 2f18f2e68927946d13933419d4f66540d16c867d (patch) | |
| tree | c49812e0ebd3dc0fcab74f46342a4ea61614bfb1 | |
| parent | cf5a884d271527a108c6bda3751993b925609595 (diff) | |
| download | stasis-2f18f2e68927946d13933419d4f66540d16c867d.tar.gz | |
Split RT tests from Unit testswheel-summary
* Enable verbose output for RT side
* Truncate huge skyscraper-length html output
| -rw-r--r-- | .github/workflows/cmake-multi-platform.yml | 31 | ||||
| -rw-r--r-- | tests/setup.sh | 22 |
2 files changed, 47 insertions, 6 deletions
diff --git a/.github/workflows/cmake-multi-platform.yml b/.github/workflows/cmake-multi-platform.yml index 2191559..9ab157c 100644 --- a/.github/workflows/cmake-multi-platform.yml +++ b/.github/workflows/cmake-multi-platform.yml @@ -68,8 +68,8 @@ jobs: -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DASAN=ON -DTESTS=ON - -DTESTS_VERBOSE=ON -DTESTS_RT=ON + -DTESTS_VERBOSE=ON -DDEBUG_MESSAGES=ON -S ${{ github.workspace }} @@ -78,7 +78,25 @@ jobs: PKG_CONFIG_PATH: /opt/homebrew/lib/pkgconfig:/usr/lib/x86_64-linux-gnu/pkgconfig run: cmake --build ${{ steps.strings.outputs.build-output-dir }} --config ${{ matrix.build_type }} - - name: Test + - name: Test (Unit) + working-directory: ${{ steps.strings.outputs.build-output-dir }} + run: | + export ASAN_OPTIONS="verify_asan_link_order=0 strict_string_checks=1 detect_stack_use_after_return=1" + if [[ "$RUNNER_OS" == "macOS" ]]; then + ASAN_OPTIONS="$ASAN_OPTIONS detect_leaks=0" + else + ASAN_OPTIONS="$ASAN_OPTIONS detect_leaks=1" + fi + ctest --tests-regex '^test_.*' \ + --build-config ${{ matrix.build_type }} \ + --output-on-failure \ + --output-junit results_unit.xml \ + --test-output-size-passed 65536 \ + --test-output-size-failed 65536 + env: + STASIS_SYSCONFDIR: ../../.. + + - name: Test (RT) working-directory: ${{ steps.strings.outputs.build-output-dir }} run: | export ASAN_OPTIONS="verify_asan_link_order=0 strict_string_checks=1 detect_stack_use_after_return=1" @@ -87,6 +105,13 @@ jobs: else ASAN_OPTIONS="$ASAN_OPTIONS detect_leaks=1" fi - ctest --build-config ${{ matrix.build_type }} --output-on-failure --output-junit results.xml --test-output-size-passed 65536 --test-output-size-failed 65536 + ctest --tests-regex '^rt_.*' \ + -V \ + --build-config ${{ matrix.build_type }} \ + --output-junit results_rt.xml \ + --test-output-size-passed 65536 \ + --test-output-size-failed 65536 env: STASIS_SYSCONFDIR: ../../.. + STASIS_TEST_ALWAYS_SHOW_OUTPUT: 1 + STASIS_TEST_ALWAYS_SHOW_INDEXER_OUTPUT: 0 diff --git a/tests/setup.sh b/tests/setup.sh index bce2fbd..c69d047 100644 --- a/tests/setup.sh +++ b/tests/setup.sh @@ -102,6 +102,8 @@ install_stasis() { popd } +STASIS_TEST_ALWAYS_SHOW_OUTPUT=${STASIS_TEST_ALWAYS_SHOW_OUTPUT:-0} +STASIS_TEST_ALWAYS_SHOW_INDEXER_OUTPUT=${STASIS_TEST_ALWAYS_SHOW_INDEXER_OUTPUT:-0} STASIS_TEST_RESULT_FAIL=0 STASIS_TEST_RESULT_PASS=0 @@ -112,8 +114,14 @@ run_command() { local lines_on_error=1000 /bin/echo "Testing: $cmd " - $cmd &>"$logfile" - code=$? + if (( STASIS_TEST_ALWAYS_SHOW_OUTPUT )); then + $cmd + code=$? + else + $cmd &>"$logfile" + code=$? + fi + if (( code )); then if (( code == 127 )); then echo "... SKIP" @@ -226,7 +234,15 @@ check_output_indexed_dir() { echo echo "FILENAME: $x" echo - cat "$x" + if (( STASIS_TEST_ALWAYS_SHOW_INDEXER_OUTPUT )); then + cat "$x" + else + head "$x" + echo + echo '<!-- crunched -->' + echo + tail "$x" + fi echo "[EOF]" echo done |
