Skip to content

Inject conflict Git-directory fixture - #555

Open
leynos wants to merge 1 commit into
mainfrom
test-quality-sweep-conflict-fixture
Open

leynos wants to merge 1 commit into
mainfrom
test-quality-sweep-conflict-fixture

Conversation

@leynos

@leynos leynos commented Sep 24, 2026 •

Copy link
Copy Markdown
Owner

Summary

This branch makes the fallible Git-directory setup in the conflict-selection
tests an rstest fixture. Each affected test now receives fresh setup through
injection while retaining its TempDir guard and existing assertions.

It follows merged #530 and
targets main with only the follow-on test fixture.

Review walkthrough

Validation

  • Focused discovery found 16 expanded cases across the seven injected test functions; all 16 passed before the replay.
  • make check-fmt, make lint, make test, make typecheck, make markdownlint, make nixie, make verus, and make verus-selftest: passed sequentially after replay on cf5e31fe498cb276712daf869f21e0970a1f261a.
  • cs delta ef68c09f0e7ae5ce21b1e2214049f25cbb8daadf cf5e31fe498cb276712daf869f21e0970a1f261a --file src/select/conflict_tests.rs: no issues found.
  • Independent read-only review and git diff --check: passed.

References

@coderabbitai

coderabbitai Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Team

Run ID: d86e19ce-a6d0-46b7-8190-c71304f26e89

📥 Commits

Reviewing files that changed from the base of the PR and between ef68c09 and cf5e31f.

📒 Files selected for processing (1)
  • src/select/conflict_tests.rs
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • leynos/netsuke (auto-detected)
  • leynos/df12-dylint-builds (auto-detected)
  • leynos/typos-config-builder (auto-detected)
  • leynos/falcon-correlate (auto-detected)
  • leynos/msgspec-crockford (auto-detected)
  • leynos/vk (auto-detected)
  • leynos/simulacat-core (auto-detected)
  • leynos/agent-template-python (auto-detected)
  • leynos/shared-actions (auto-detected)
  • leynos/cuprum (auto-detected)

Included review availability: 3 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 4 reviews per hour.


Summary

  • Convert Git-directory setup in the conflict-selection tests into an rstest fixture.
  • Inject the fallible fixture into affected tests. Keep the TempDir guard and existing assertions.

Testing

  • The PR description reports that all 16 expanded cases passed before replay.
  • It also reports that the listed checks and git diff --check passed after replay. No test results were independently verified.

Walkthrough

The conflict tests now use rstest fixture injection to provide temporary Git directory data. The affected tests unwrap the fixture result. Existing test cases and assertions remain otherwise unchanged.

Changes

Conflict test fixture injection

Layer / File(s) Summary
Fixture and test injection
src/select/conflict_tests.rs
The Git directory helper is now an rstest fixture. Affected tests receive and unwrap its fallible result through fixture injection.

Priority: ⬇️ Low

Change: Refactor

Merge Risk: ⚪ Minimal · up to cf5e3

The change only reorganizes existing conflict-test setup; each test still gets fresh temporary data and retains its existing assertions. No actionable merge risk is apparent.

🚥 Pre-merge checks | ✅ 15
✅ Passed checks (15 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main change: injecting an rstest fixture for the conflict Git-directory setup. No roadmap item or issue reference is required because the provided context includes ne…
Description check ✅ Passed The description directly explains the fixture change, affected tests, retained assertions, validation results, and references. It is relevant to the changeset.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 8 functions across 1 files.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Testing (Overall) ✅ Passed Pass. The pull request changes only src/select/conflict_tests.rs and introduces no product behaviour. It converts the existing fallible Git-directory setup into an rstest fixture, while the affect…
User-Facing Documentation ✅ Passed Treat this change as test-only. The pull request changes only src/select/conflict_tests.rs: it injects an rstest fixture and preserves the existing test assertions. It introduces no user-facing fu…
Developer Documentation ✅ Passed Pass. Treat the change as test-only. The diff changes only src/select/conflict_tests.rs, adds an rstest fixture, and injects it into private test functions. The module remains under #[cfg(test)]…
Module-Level Documentation ✅ Passed Mark the check PASS. src/select/conflict_tests.rs has module-level //! documentation that states its purpose and utility: it tests the two conflict predicates and covers both detection and false-p…
Testing (Unit And Behavioural) ✅ Passed The pull request only refactors existing conflict-selection tests to inject an rstest fixture. The diff preserves the existing behavioural cases, edge cases, error paths, assertions, and temporary-d…
Testing (Property / Proof) ✅ Passed PASS. The pull request changes only src/select/conflict_tests.rs and only injects the existing fallible Git-directory setup through an rstest fixture. It does not introduce a new invariant, input/…
Testing (Compile-Time / Ui) ✅ Passed Pass the check. The pull request changes only src/select/conflict_tests.rs: it adds an rstest fixture and injects it into existing tests. It introduces no Rust or TypeScript compile-time behaviour…
Unit Architecture ✅ Passed Mark the check PASS. The pull request changes only src/select/conflict_tests.rs. It makes git_dir_fixture an rstest fixture with an explicit io::Result, injects it into the affected tests, and…
Domain Architecture ✅ Passed Pass. Keep the change as test-only. The diff modifies only src/select/conflict_tests.rs, which src/select.rs includes under #[cfg(test)]. It injects an rstest fixture for temporary Git-directo…
Observability ✅ Passed Mark this check as passed. The pull request changes only src/select/conflict_tests.rs and only converts test setup to an rstest fixture. It introduces no production or operational behaviour, so lo…

A fixture prepares a Git space
Tests receive it at their own pace
The result arrives with care
Assertions stay in place
The markers wait right there

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

@sourcery-ai

sourcery-ai Bot commented Sep 24, 2026

Copy link
Copy Markdown
Contributor

Reviewer's Guide

The PR replaces direct Git-directory fixture calls with rstest dependency injection across seven conflict-selection tests, ensuring each expanded case receives fresh fallible setup while retaining TempDir cleanup and existing assertions.

File-Level Changes

Change Details Files
Convert the fallible Git-directory setup into an injected rstest fixture while preserving temporary-directory lifetime and setup error handling.
  • Mark the existing fixture with rstest and continue returning the TempDir guard alongside paths and capability directory.
  • Inject the fixture into the parameterized conflict-selection test, replacing direct fixture calls.
  • Convert the six standalone tests to rstest functions and inject fresh fixture instances into each.
  • Retain existing setup failure messages, test data, and behavioral assertions.
src/select/conflict_tests.rs

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

codescene-access[bot]

This comment was marked as outdated.

Base automatically changed from test-quality-sweep-workflow-reader to main September 24, 2026 04:36
Make the fallible Git-directory setup an `rstest` fixture so each
dependent case receives fresh, explicit setup while retaining the
temporary-directory guard for its full test lifetime.
@leynos
leynos force-pushed the test-quality-sweep-conflict-fixture branch from 09fcc85 to cf5e31f Compare September 24, 2026 04:41
@leynos
leynos marked this pull request as ready for review September 24, 2026 04:48

@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've used your own review budget of 250,000 diff characters for the last 7 days.

You can request another review in 5 hours and 58 minutes by commenting @sourcery-ai review. Upgrade to get a review now.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 24, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-24T04:49:50.997737Z cf5e31f Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@pandalump

Copy link
Copy Markdown
Collaborator

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

This branch has not been deployed

No deployments
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.

2 participants