diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index c58c1ae..927c660 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -32,9 +32,7 @@ jobs: with: source-dir: test build-dir: output - - - name: Run the build result - run: output/hello_world + run_test: true - name: Check if the default build directory does not exist run: test ! -d build && test ! -d test/build @@ -98,6 +96,4 @@ jobs: with: source-dir: test generator: Ninja - - - name: Run the build result - run: test/build/hello_world + run-test: true diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 1f6ccca..c031db3 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -14,7 +14,9 @@ if(CHECK_SURPASS_WARNING) endif() endif() +enable_testing() add_executable(hello_world hello_world.cpp) +add_test(NAME hello_world COMMAND $) list(APPEND LANGS c cpp) foreach(LANG ${LANGS})