Skip to content

[Deprecate] ConfiguredMockEntityToSetterObjectRector as experimental - #789

Merged
TomasVotruba merged 1 commit into
mainfrom
deprecate-configured-mock-entity-to-setter
Sep 29, 2026
Merged

TomasVotruba merged 1 commit into
mainfrom
deprecate-configured-mock-entity-to-setter

Conversation

@TomasVotruba

Copy link
Copy Markdown
Member

This rule is experimental and can generate broken code:

  • Silently drops config keys that don't start with get, losing stubbed values without warning.
  • Assumes a matching setX() setter exists for every getX key - generates calls to nonexistent methods on immutable/constructor-only entities.

Mirrors the deprecation done for WillReturnCallbackFallbackToThrowRector (#740): implements DeprecatedInterface, refactor() throws, keeps rule definition for docs. Test dir removed and the commented-out set registration dropped.

@TomasVotruba TomasVotruba changed the title Deprecate ConfiguredMockEntityToSetterObjectRector as experimental [Deprecate] ConfiguredMockEntityToSetterObjectRector as experimental Sep 29, 2026
@TomasVotruba
TomasVotruba merged commit f847ef0 into main Sep 29, 2026
8 checks passed
@TomasVotruba
TomasVotruba deleted the deprecate-configured-mock-entity-to-setter branch September 29, 2026 08:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant