Skip to content

Cleanup: Drop unused dev dependency and migrate PHPUnit annotations to attributes (Case 212955) - #28

Merged
janopae merged 2 commits into
masterfrom
212955-cleanup
Jul 31, 2026
Merged

Cleanup: Drop unused dev dependency and migrate PHPUnit annotations to attributes (Case 212955)#28
janopae merged 2 commits into
masterfrom
212955-cleanup

Conversation

@janopae

@janopae janopae commented Jul 31, 2026

Copy link
Copy Markdown
Member
  • Remove doctrine/common from require-dev — the Collections classes are provided by doctrine/collections (already in require) and Doctrine\Common\EventManager by doctrine/event-manager (transitive via doctrine/orm). Confirmed clean with composer-require-checker.
  • Migrate all PHPUnit @test and @doesNotPerformAssertions doc-annotations to #[Test] and #[DoesNotPerformAssertions] PHP 8 attributes across 24 test files. These annotations are deprecated in PHPUnit 11 and removed in PHPUnit 12.
  • Update phpunit.xml.dist schema URL from 11.0 to 11.5 and rename <coverage> to <source>, clearing the last PHPUnit deprecation warning.

janopae added 2 commits July 31, 2026 10:31
doctrine/common was listed as a dev dependency but nothing in the
codebase depends on it directly. The Doctrine\Common\Collections\*
symbols (used in Recipient and PendingOptIn) are provided by
doctrine/collections, which is already in require. The
Doctrine\Common\EventManager symbol (used in AppClassTemplatesTest)
is provided by doctrine/event-manager, a transitive dependency of
doctrine/orm. Confirmed with composer-require-checker: no unknown
symbols after removal.
PHPUnit 11 deprecates @test and related doc-annotations; PHPUnit 12
removes them. Convert all 24 test files from /** @test */ docblocks to
#[Test] attributes. Four methods also used @doesNotPerformAssertions,
which PHPUnit 11 silently ignores in docblock form (causing those tests
to be reported as risky); those were converted to #[DoesNotPerformAssertions]
as well.

Also update the phpunit.xml.dist schema URL from 11.0 to 11.5 via
--migrate-configuration, which also renames <coverage> to <source>.
This clears the last remaining PHPUnit deprecation warning.
@janopae janopae changed the title 212955 cleanup Cleanup: Drop unused dev dependency and migrate PHPUnit annotations to attributes (Case 212955) Jul 31, 2026
@janopae
janopae merged commit edd9b61 into master Jul 31, 2026
3 checks passed
@janopae
janopae deleted the 212955-cleanup branch July 31, 2026 08:43
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