From 3addfc9a94bb4cf14aff53b3b81f0731da6db0fa Mon Sep 17 00:00:00 2001 From: bialger Date: Thu, 18 Jan 2024 15:18:02 +0300 Subject: [PATCH] Fixed syntax --- .github/workflows/ci_tests.yml | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci_tests.yml b/.github/workflows/ci_tests.yml index d34e49d..ece6afa 100644 --- a/.github/workflows/ci_tests.yml +++ b/.github/workflows/ci_tests.yml @@ -54,9 +54,23 @@ jobs: endif() - name: Create CMake cache - shell: bash + shell: cmake -P {0} run: | - cmake -S . -B cmake-build -DCMAKE_CXX_COMPILER=$CXX -DCMAKE_C_COMPILER=$CC + + execute_process( + COMMAND cmake -S . -B cmake-build -DCMAKE_CXX_COMPILER=${{ matrix.config.cxx }} -DCMAKE_C_COMPILER=${{ matrix.config.cc }} + RESULT_WORKING_DIRECTORY build + RESULT_VARIABLE result + ECHO_OUTPUT_VARIABLE result_output + ECHO_ERROR_VARIABLE result_error + ) + + if (NOT result EQUAL 0) + message(FATAL_ERROR "Running tests failed!") + endif() + + message(STATUS "${result_output}") + message(STATUS "${result_error}") - name: Build main target run: |