spec:
    inputs:
        stage:
            description: "The stage of the job."
            default: test
        project_path:
            description: "The path to the project root directory."
            default: '.'

---
pytest:
    image: swepy/pytest:latest
    variables:
        PROJECT_PATH: $[[ inputs.project_path ]]
        PYTEST_CMD: "pytest $PROJECT_PATH"
    stage: $[[ inputs.stage ]]
    script:
        - $PYTEST_CMD