Skip to content

Commit

Permalink
disable build test on default when using cmake
Browse files Browse the repository at this point in the history
  • Loading branch information
oathdruid committed Oct 17, 2024
1 parent b4aa5c7 commit 1f7eca5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: hendrikmuhs/[email protected]
- run: cmake -Bbuild -DBUILD_DEPS=ON -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
- run: cmake -Bbuild -DBUILD_DEPS=ON -DBUILD_TESTING=ON -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
- run: cmake --build build --parallel $(nproc)
- run: ctest --test-dir build --output-on-failure --parallel $(nproc)
3 changes: 1 addition & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@ include(CMakePackageConfigHelpers) # for write_basic_package_version_file

option(BUILD_DEPS "Use FetchContent download and build dependencies" OFF)

if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
if(BUILD_TESTING AND CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
set(CMAKE_CXX_STANDARD 20)
set(BUILD_TESTING ON)
endif()

if(BUILD_DEPS)
Expand Down

0 comments on commit 1f7eca5

Please sign in to comment.