Skip to content

Document mutation-testing workflow contract tests - #301

Draft
leynos wants to merge 1 commit into
mainfrom
docs/mutation-contract-tests
Draft

Document mutation-testing workflow contract tests#301
leynos wants to merge 1 commit into
mainfrom
docs/mutation-contract-tests

Conversation

@leynos

@leynos leynos commented Jul 19, 2026

Copy link
Copy Markdown
Owner

Summary

  • Adds a new ## Mutation-testing workflow contract tests section to
    docs/developers-guide.md, explaining
    .github/workflows/mutation-testing.yml, its delegation to
    leynos/shared-actions/.github/workflows/mutation-cargo.yml, and the
    contract test that pins the caller's shape.
  • Documents the local run command, make test-workflow-contracts.

Permutation

Permutation A — Rust (single crate). ddlint is a single-crate package (no
workspace), so the section describes a manual dispatch that "mutates the
whole crate".

Contract-test style

Shape-only: tests/workflow_contracts/mutation_testing_test.py uses a
USES_RE regex asserting ...@[0-9a-f]{40}; the pinned SHA value itself is
not hard-coded, so Dependabot bumps it without any accompanying test edit.
The with: block is asserted by equality against a separate EXPECTED_WITH
dict (exclude-globs, extra-args — this repo's caller has no paths
input). The module has no pytestmark/skip guard; ddlint is a Rust crate, so
there is no mutmut sandbox that omits .github/.

Local run command

make test-workflow-contracts, which runs:

uv run --with 'pytest>=8' --with 'pyyaml>=6' pytest tests/workflow_contracts -q

Roadmap / execplan note

No roadmap or execplan tracking applies. docs/roadmap.md and
docs/execplans/* were searched for "mutation" and contain no matching task,
so nothing was ticked or annotated.

TOC / cross-link

docs/developers-guide.md has no in-page table of contents (headings run
directly, no index list). docs/contents.md already lists the developer
guide as a whole document ("Maintainer-facing workflow and implementation
guidance for the current codebase"), which already covers this addition, so
no cross-link changes were needed.

Docs lint result

make markdownlint passed after the change (it chains spelling, which
enforces en-GB Oxford-ize spelling via pinned typos). Two Oxford-spelling
fixes were needed in the drafted prose (summarisingsummarizing,
serialisesserializes) before the gate passed cleanly. The gate's
spelling step regenerates typos.toml from the shared dictionary as a
side effect; that regeneration was unrelated to this change and was reverted
before committing, leaving typos.toml untouched in this PR.

Only the docs gate was run, per instructions; the Rust/Python test suites
were not run.

Changed file

Add a developer guide section explaining the mutation-testing caller
workflow and its shape-only contract test, so contributors know what
the test enforces and how to run it locally before touching either
file.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @leynos, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

@coderabbitai

coderabbitai Bot commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: e3f30050-7b58-465f-a3f1-9fabe5fa3f24

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/mutation-contract-tests

Comment @coderabbitai help to get the list of available commands.

codescene-access[bot]

This comment was marked as outdated.

@codescene-access codescene-access Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No quality gates enabled for this code.

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.

1 participant