Goddard-Fortran-Ecosystem / pFUnit

Parallel Fortran Unit Testing Framework
Other
174 stars 45 forks source link

CMake: Fix linking tests in nested subdirectories #340

Closed ZedThree closed 2 years ago

ZedThree commented 2 years ago

For some reason, when using add_pfunit_ctest in a subdirectory, _[P]FUNIT_LIBRARIES was empty, meaning the tests weren't getting compiled/linked properly.

add_pfunit_test uses PFUNIT_LIBRARIES directly, so follow that in add_pfunit_ctest too.