mirror of
https://github.com/threeal/cmake-action.git
synced 2025-04-20 02:31:20 +00:00
replace test configuration with regex match
This commit is contained in:
parent
c2bf81f4d3
commit
354c02b686
8
.github/workflows/test.yml
vendored
8
.github/workflows/test.yml
vendored
@ -33,6 +33,7 @@ jobs:
|
||||
source-dir: test
|
||||
build-dir: output
|
||||
run-test: true
|
||||
test-args: -R hello_world
|
||||
|
||||
- name: Check if the default build directory does not exist
|
||||
run: test ! -d build && test ! -d test/build
|
||||
@ -55,7 +56,7 @@ jobs:
|
||||
c-flags: ${{ matrix.compiler == 'msvc' && '/w /WX-' || '-Wno-unused-variable' }}
|
||||
cxx-flags: ${{ matrix.compiler == 'msvc' && '/w /WX-' || '-Wno-unused-variable' }}
|
||||
args: -D CHECK_SURPASS_WARNING=ON
|
||||
test-args: -C test -E hello_world
|
||||
test-args: -R test
|
||||
|
||||
specified-compiler-usage:
|
||||
runs-on: ${{ matrix.os }}-latest
|
||||
@ -76,7 +77,7 @@ jobs:
|
||||
c-compiler: clang
|
||||
cxx-compiler: clang++
|
||||
args: -D CHECK_USING_CLANG=ON
|
||||
test-args: -C test -E hello_world
|
||||
test-args: -R test
|
||||
|
||||
specified-generator-usage:
|
||||
runs-on: ${{ matrix.os }}-latest
|
||||
@ -91,5 +92,6 @@ jobs:
|
||||
uses: ./
|
||||
with:
|
||||
source-dir: test
|
||||
generator: Ninja
|
||||
run-test: true
|
||||
generator: Ninja
|
||||
test-args: -R hello_world
|
||||
|
@ -28,5 +28,5 @@ foreach(LANG ${LANGS})
|
||||
$<$<BOOL:${CHECK_USING_CLANG}>:CHECK_USING_CLANG>
|
||||
$<$<BOOL:${CHECK_SURPASS_WARNING}>:CHECK_SURPASS_WARNING>
|
||||
)
|
||||
add_test(NAME test_${LANG} CONFIGURATIONS test COMMAND $<TARGET_FILE:test_${LANG}>)
|
||||
add_test(NAME test_${LANG} COMMAND $<TARGET_FILE:test_${LANG}>)
|
||||
endforeach()
|
||||
|
Loading…
Reference in New Issue
Block a user