Skip to content

Commit

Permalink
Update testing
Browse files Browse the repository at this point in the history
  • Loading branch information
jchristopherson committed Sep 12, 2023
1 parent abea4ca commit 208ab26
Show file tree
Hide file tree
Showing 6 changed files with 116 additions and 61,480 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- uses: actions/checkout@v3

- name: Configure CMake
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_Fortran_COMPILER=${{ env.FC }} -DBUILD_FSTATS_TESTING=TRUE
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_Fortran_COMPILER=${{ env.FC }} -DBUILD_TESTING=TRUE

- name: Build with CMake
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
Expand Down
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ link_library(${PROJECT_NAME} ${linalg_LIBRARY} ${linalg_INCLUDE_DIR})
add_subdirectory(install)

# Testing
option(BUILD_FSTATS_TESTING "Build tests")
option(BUILD_TESTING "Build tests")
include(CTest)
message(STATUS "Build tests: ${BUILD_TESTING}")
if (BUILD_FSTATS_TESTING)
if (BUILD_TESTING)
enable_testing()
add_subdirectory(tests)
endif()
Expand Down
9 changes: 0 additions & 9 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,8 @@
include("${PROJECT_SOURCE_DIR}/cmake/helper.cmake")

# Dependencies
add_subdirectory(fortran_csv_module)
add_subdirectory(fortran_test_helper)

# Copy necessary test files
configure_file(
${CMAKE_SOURCE_DIR}/tests/files/allan_test_data.csv
${CMAKE_BINARY_DIR}/tests/allan_test_data.csv
COPYONLY
)

# Define the source files
set(fstats_test_sources
fstats_tests.f90
Expand All @@ -27,7 +19,6 @@ set(fstats_test_sources
# Build the tests
add_executable(fstats_tests ${fstats_test_sources})
link_library(fstats_tests ${PROJECT_NAME} ${PROJECT_INCLUDE_DIR})
link_library(fstats_tests ${fortran-csv-module_LIBRARY} ${fortran-csv-module_INCLUDE_DIR})
link_library(fstats_tests ${fortran_test_helper_LIBRARY} ${fortran_test_helper_INCLUDE_DIR})
add_test(
NAME fstats_tests
Expand Down
Loading

0 comments on commit 208ab26

Please sign in to comment.