Skip to content

fix: apply negated toUse to each target in a multi-element expect - #1770

Open
lazerg wants to merge 1 commit into
pestphp:5.xfrom
lazerg:fix/negated-touse-multi-target
Open

fix: apply negated toUse to each target in a multi-element expect#1770
lazerg wants to merge 1 commit into
pestphp:5.xfrom
lazerg:fix/negated-touse-multi-target

Conversation

@lazerg

@lazerg lazerg commented Jul 25, 2026

Copy link
Copy Markdown

What:

  • Bug Fix
  • New Feature

Description:

A negated toUse on a multi-element expect([...]) never failed. The positive check fails as soon as one target doesn't use the dependency, and the negation reads that failure as a pass, so a real violation by another target slips through. This decomposes the expect targets the way the dependencies already are, so each one is checked on its own.

Related:

Fixes #1751

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.

Negated toUse with a multi-element expect([...]) is silently inert — the arch rule can never fail

1 participant