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.15.2
    • 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.101.0 in CI job 262272 | Last revision: October 24, 2022
Commit: [web] Update docs on notebook testing and web conversion. 1cb932f  | Edit this page on