Workflow testing

Introduction

We use the workflow manager Snakemake to test workflows which consist of the execution of several steps which are based on each other.

Requirements

  • Snakemake >= 7.32.4
    • If you use OGS_USE_PIP=ON then snakemake is installed in your virtual environment in your build-directory automatically. You can then call it via .venv/bin/snakemake ... (inside your build directory).
  • On Windows only:

Examples

These example workflows are added to CTest as well:

if(SNAKEMAKE AND NOT OGS_USE_MPI)
    add_test(NAME snakemake_ExtractBoundary
        COMMAND ${SNAKEMAKE} -j 1
            --configfile ${PROJECT_BINARY_DIR}/buildinfo.yaml
            -s ${CMAKE_CURRENT_SOURCE_DIR}/ExtractBoundary.smk
    )
    add_test(NAME snakemake_VoxelGridFromLayers
    # ...
    )
    add_dependencies(ctest ExtractBoundary Layers2Grid AddFaultToVoxelGrid)
endif()

Modularization

We started on implementing modular rule definitions and tool wrapper in scripts/snakemake.


This article was written by Lars Bilke. If you are missing something or you find an error please let us know.
Generated with Hugo 0.122.0 in CI job 418530 | Last revision: February 1, 2024
Commit: [cmake] Set runtime parameter on larger benchmarks. 86f23e2  | Edit this page on