Use this page to verify an install and run the main test suites after a pre-built package or a source build. Maintainer reference: TEST_SUITES_REFERENCE.md (CTest inventories, raw ctest, runners), REPORTING_AND_PLOTS.md (reports and plots), CONTRIBUTING.md (constraints), data/verification/README.md (verification data layout and normalization).
Pre-built package — Python 3.10 or newer required. From the package root:
- Windows:
tests\RUN-TESTS.ps1 - macOS / Linux:
./tests/RUN-TESTS.sh
This runs every demo case headless, compares output against expected baselines, and prints PASS/FAIL per case. Details and flags: tests/regression/run_seastack/README.md.
Source build (Windows) — After scripts/windows/build.ps1 (or an equivalent CMake build), use the suite scripts in the table below. For a quick CTest-only pass without post-run report steps: .\scripts\windows\build.ps1 -Test or .\scripts\windows\build.ps1 -Test -TestLabel unit. Advanced: ctest from build/ — see TEST_SUITES_REFERENCE.md.
macOS / Linux — From the repo root after building:
./scripts/unix/ctest_suite.sh <suite>Use <suite> = regression, unit, verification, comparison, chrono-free, or benchmark. Pass --no-pdf if Pandoc is on PATH but no LaTeX engine is installed.
Regression compares simulation output to frozen SEA-Stack baselines (ss_ref_*.txt) with tight tolerances; it is the usual every-commit gate. Consistency jobs are a subset of regression (extra label consistency) for internal checks such as spectrum vs eta round-trip.
Verification compares against external or multi-code reference data under data/verification/ with wider tolerances. Comparison runs two SEA-Stack configurations against each other (no external reference). Benchmark measures wall-clock timing (JSON output; not a strict pass/fail gate like regression).
Unit tests exercise libraries with assertions. Chrono-free tests omit Chrono DLLs; useful when you only need the non-Chrono stack.
| Track / suite | Purpose | Continuous integration | CTest label(s) |
|---|---|---|---|
| Unit | Library checks | Every pull request | unit |
| Chrono-free | No Chrono | Every pull request | chrono-free |
| Core regression | vs ss_ref_*.txt |
Every pull request | regression |
| Consistency | Internal self-validation | Every pull request | regression;consistency |
| External modules | External PTO and controller runs | Every pull request | external |
| Verification | Cross-code / multi-code | Nightly / on request | verification |
| Comparison | Method vs method (internal) | Nightly / on request | comparison |
| Benchmark | Performance timing | Nightly / on request (for information) | benchmark |
Windows (PowerShell, from repo root) — Prefer these wrappers; they align ctest -C with -BuildType, set parallelism, and run report steps where applicable. Pass -j N to cap parallelism (0 = all CPUs on most scripts). See -Help on each script.
| Suite | Script |
|---|---|
| Unit | .\scripts\windows\run_unit_tests.ps1 |
| Chrono-free | .\scripts\windows\run_chrono_free_tests.ps1 |
| Regression | .\scripts\windows\run_regression_tests.ps1 (-Long for long tests; -NoPdf to skip PDF) |
| Verification | .\scripts\windows\run_verification_tests.ps1 |
| Comparison | .\scripts\windows\run_comparison_tests.ps1 |
| Benchmark | .\scripts\windows\run_benchmarks.ps1 (sequential -j 1) |
Unix — ./scripts/unix/ctest_suite.sh <suite> as above.
Verbose ctest output, -BuildType/Release notes, and raw ctest vs PowerShell behavior for verification/comparison reports: TEST_SUITES_REFERENCE.md.
GitHub Actions builds and tests SEA-Stack on Linux, macOS and Windows (.github/workflows/ci.yml). Each platform has two jobs, which call the scripts in the tables above:
| Job | Build | Tests |
|---|---|---|
| Chrono-free | --no-chrono --external / -NoChrono -External |
chrono-free label and the downstream-consumer check |
| Chrono | Headless Chrono 10.0.0 built by scripts/unix/build_chrono.sh or scripts/windows/build_chrono.ps1, with MoorDyn, external modules and demos; no VSG |
unit, regression and external labels |
The Chrono job also runs the full suites (verification, comparison, long regression, the demo cases through run_tests.py --all and --extended, and the benchmarks) every night on dev, on a manual run of the workflow, and on a pull request that carries the label full-tests.
- Threads: two tests run at a time, each with
OMP_NUM_THREADS=2. - Skipped tests fail the run. CTest exits with 0 when a test returns its skip code, for example when a Python package is missing;
scripts/ci/check_ctest_junit.pyreads the JUnit report of each suite and fails unless every test ran and passed. The suite scripts write that report with--junit FILE(Unix) or-Junit FILE(Windows).test_demo_features_pythonruns under pytest and returns the skip code when pytest skips any of its tests, so the Chrono jobs install MHKiT fromdata/demos/run_seastack/features/requirements.txt. - Benchmarks do not fail the run. Timings on shared runners are for information only.
- Results: each job uploads its JUnit reports and logs. The page of a workflow run shows each report's table of checks against limits for every platform.
- PDF reports: the artifact
test-reportsholds the reports of all three platforms as PDF, in the folderslinux,macosandwindows, with the figures resampled to 150 dpi for reading on screen. The regression reports are in every run; the verification and comparison reports come with the full suites. The Chrono jobs write the reports as Markdown, and a final job converts them on Linux, where pandoc and LaTeX are installed. - Jobs that GitHub does not start: GitHub cancels a job when no hosted runner picks it up, which happens now and then on macOS; the run then fails although no test failed. A second workflow (
.github/workflows/retry-unstarted-jobs.yml) re-runs the failed jobs of such a run, up to three attempts in total, whenscripts/ci/unstarted_jobs.pyfinds that the only jobs that did not pass were never started. A job that ran and failed is not repeated automatically. A run whose job is still unstarted after the last attempt stays failed; use "Re-run failed jobs" on the run page. - Not covered: the VSG GUI build and the release packages.
run_seastack reads two variables that exist only so that tests can provoke
failures the program must detect; do not set them otherwise.
| Variable | Effect | Used by |
|---|---|---|
SEASTACK_TEST_WRONG_CELL_INDEX |
A parallel campaign cell reports another axis position, which the campaign must reject. | test_campaign_attribution |
SEASTACK_TEST_INTERRUPT_SUMMARY |
The campaign stops before writing its summary's completeness marker, as an interrupted write would. | test_campaign_attribution |
SEASTACK_LONG_TESTS=1 selects the long durations of the regression,
verification and comparison generators.
Regression, verification, and comparison can produce Markdown reports under build/bin/<Config>/results/tests/... (e.g. .../regression/report/regression_test_report.md). Each report starts with a table of checks against limits: one row per case with its status and the check that is closest to its limit (measured value, limit and share of the limit used), followed by every check that is outside a limit or a warning threshold. The numbers come from the status files that the comparisons write. PDF needs Pandoc and a LaTeX engine (MiKTeX, MacTeX, TeX Live); Windows runners add PDF when pandoc is on PATH unless you pass -NoPdf. Markdown is still written if PDF conversion fails.
The CTest report tests verification_report_generation and comparison_report_generation fail when no status file is found, when a status file cannot be read, when a status is FAIL or not recognised, or when a PASS or WARN has no positive comparison count. Both also fail when a case registered in the build has no result, when a result belongs to no registered case, or (verification) when a test name has more than one status file. The registered cases are written at configure time to tests/verification/expected_groups.txt and tests/comparison/expected_cases.txt in the build directory; rm3_mooring is registered only with SEASTACK_ENABLE_MOORING=ON. The report's summary outcome uses the same checks.
Configure-time vs runtime PDF behavior, .status.json, and shared generator code: REPORTING_AND_PLOTS.md.
- TEST_SUITES_REFERENCE.md — per-case tables, raw
ctest, CI examples - data/verification/CONVENTIONS.md — SI units, frames, signs for verification data
- data/verification/README.md — directory layout, normalization, provenance
- REPORTING_AND_PLOTS.md — report pipelines and plot standard
- CONTRIBUTING.md — test expectations and maintainer constraints
- regression/sphere/ETA_IMPORT.md — DFT eta-import pathway and
sphere_irreg_waves_eta