separate test target into 2 for C and C++

This commit is contained in:
Alfi Maulana 2023-01-11 16:47:00 +07:00
parent 17a40c86ca
commit 6f70267077
No known key found for this signature in database
GPG Key ID: 2242A64C2A8DF5A4
3 changed files with 7 additions and 3 deletions

View File

@ -49,10 +49,10 @@ jobs:
uses: ./
with:
source-dir: test
targets: test
targets: test_c test_cpp
- name: Run build result
run: build/test
run: build/test_c && build/test_cpp
use-action-with-specified-compiler:
runs-on: ubuntu-latest

View File

@ -12,4 +12,5 @@ if(BUILD_CXX)
add_executable(hello_world hello_world.cpp)
endif()
add_executable(test EXCLUDE_FROM_ALL test.cpp)
add_executable(test_c EXCLUDE_FROM_ALL test.c)
add_executable(test_cpp EXCLUDE_FROM_ALL test.cpp)

3
test/test.c Normal file
View File

@ -0,0 +1,3 @@
int main() {
return 0;
}