Skip to content

Add test suite and GitHub Actions CI - #11

Merged
egpbos merged 4 commits into
masterfrom
copilot/add-test-suite-and-ci
Jun 16, 2026
Merged

Add test suite and GitHub Actions CI#11
egpbos merged 4 commits into
masterfrom
copilot/add-test-suite-and-ci

Conversation

Copilot AI commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

No automated tests existed for FindFFTW.cmake, making it hard to validate changes or catch regressions. Adds a configure-time CMake test and a 3-job GitHub Actions matrix covering the main FFTW install scenarios.

test/CMakeLists.txt

Configure-time test project (project(... NONE) — no compiler needed). Accepts a semicolon-separated component list via -DFFTW_TEST_COMPONENTS and asserts:

  • FFTW_FOUND, FFTW_INCLUDE_DIRS, FFTW_LIBRARIES are set
  • Each required component's FFTW_<component>_FOUND, FFTW_<component> (library path), and imported CMake target (FFTW::Double, etc.) are set
  • Prints a full component-status table for diagnostics

Run manually as:

cmake -S test -B build -DFFTW_TEST_COMPONENTS="DOUBLE_LIB;FLOAT_LIB;LONGDOUBLE_LIB"

.github/workflows/test.yml

Three-job matrix on ubuntu-latest, fail-fast: false:

Job Install Components required
apt libfftw3-dev 9 (3 precisions × basic / threads / OpenMP)
source FFTW 3.3.10 tarball built with --enable-threads --enable-openmp × 3 precisions; result cached 9 (same) via FFTW_ROOT
conda conda-forge::fftw via micromamba 6 (3 precisions × basic / threads) via FFTW_ROOT=$CONDA_PREFIX

- test/CMakeLists.txt: configure-time test that runs find_package(FFTW)
  and checks FFTW_FOUND, FFTW_INCLUDE_DIRS, FFTW_LIBRARIES, per-component
  _FOUND/_LIB variables, and imported CMake targets
- .github/workflows/test.yml: three-way matrix (apt, source tarball, conda-forge)
  apt: tests 9 components (3 precisions × basic/threads/openmp)
  source: builds FFTW 3.3.10 from tarball with cache, tests all 9 variants
  conda: installs fftw from conda-forge via micromamba, tests 6 variants
Copilot AI changed the title [WIP] Add test suite and CI for FindFFTW Add test suite and GitHub Actions CI Jun 16, 2026
Copilot AI requested a review from egpbos June 16, 2026 14:41
egpbos added 2 commits June 16, 2026 17:47
There was no reuse across the matrix, all steps were conditional on one of the matrix elements!
@egpbos
egpbos marked this pull request as ready for review June 16, 2026 16:03
@egpbos egpbos linked an issue Jun 16, 2026 that may be closed by this pull request
@egpbos
egpbos merged commit 32b86f1 into master Jun 16, 2026
3 checks passed
@egpbos
egpbos deleted the copilot/add-test-suite-and-ci branch June 16, 2026 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add test suite and CI

2 participants