Skip to content

Conversation

@mairo744
Copy link

Q A
Documentation no
Bugfix no
BC Break no
New Feature no
RFC no
QA yes

Description

This PR refactors metadata classes by:

  • Replacing @final annotations with actual final class declarations.
  • Updating related tests to remove mocks, since final classes cannot be mocked.

…ing metadata classes as `final`

Signed-off-by: mmalac <[email protected]>
Copy link
Member

@gsteel gsteel left a comment

Choose a reason for hiding this comment

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

Thanks @mairo744 - Non-static data providers will be picked up when we upgrade PHPUnit

* 1: Metadata\AbstractMetadata
* }>
*/
public function validMetadataTypes(): Generator
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
public function validMetadataTypes(): Generator
public static function validMetadataTypes(): Generator

@gsteel gsteel self-assigned this Oct 13, 2025
@gsteel gsteel added this to the 3.0.0 milestone Oct 13, 2025
@gsteel gsteel added Enhancement New feature or request QA Quality assurance tasks such as static analysis improvements BC Break labels Oct 13, 2025
@gsteel gsteel merged commit d8bf222 into mezzio:3.0.x Oct 13, 2025
15 of 16 checks passed
@gsteel gsteel changed the title refactor: replace mocked metadata with direct init and declare remain… refactor: replace mocked metadata with direct init and declare remaining metadata classes as final Oct 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BC Break Enhancement New feature or request QA Quality assurance tasks such as static analysis improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants