Skip to content
Esc
↑↓navigate↵open⌘Jpreview
On this page

rector-phpunit/phpunit-mock-to-stub set

rector-phpunit’s phpunit-mock-to-stub set: the Pun lint rules its Rector rules map to, and nothing else.

[lint]
sets = ["rector-phpunit/phpunit-mock-to-stub"]

A rule merged from several Rector rules runs only the rewrites of this set’s Rector rules, unless a preset also turns it on. Rector rules that are format rules in Pun run under [format] instead. Laravel, Pest, and PHPUnit rules also need their extension.

Rules (10)

Rule Rector rules Status
lint/phpunit/add-mock-intersection-param AddIntersectionParamToMockObjectParamRector Ported
lint/phpunit/add-mock-intersection-type AddIntersectionVarToMockObjectPropertyRector Ported
lint/phpunit/add-stub-intersection-type AddStubIntersectionVarToStubPropertyRector Ported
lint/phpunit/no-bare-mock-assign BareCreateMockAssignToDirectUseRector Ported
lint/phpunit/no-stub-with-expectations MockObjectArgCreateStubToCreateMockRector Ported
lint/phpunit/prefer-create-stub PropertyCreateMockToCreateStubRector Ported
lint/phpunit/prefer-create-stub-argument CreateStubOverCreateMockArgRector Ported
lint/phpunit/prefer-create-stub-expression ExpressionCreateMockToCreateStubRector Ported
lint/phpunit/prefer-create-stub-in-coalesce CreateStubInCoalesceArgRector Ported
lint/phpunit/prefer-stub-var MockObjectVarToStubRector Ported

Last updated on

Was this page helpful?