diff --git a/rules-tests/TypeDeclaration/Rector/BooleanAnd/BinaryOpNullableToInstanceofRector/Fixture/skip_assign2.php.inc b/rules-tests/TypeDeclaration/Rector/BooleanAnd/BinaryOpNullableToInstanceofRector/Fixture/skip_assign2.php.inc new file mode 100644 index 0000000000..c835f01f4f --- /dev/null +++ b/rules-tests/TypeDeclaration/Rector/BooleanAnd/BinaryOpNullableToInstanceofRector/Fixture/skip_assign2.php.inc @@ -0,0 +1,24 @@ +someClass = $this->get()) && $this->someClass->someMethod()) { + return $this->someClass->someMethod(); + } + + return 'no'; + } + + private function get(): ?SomeInstance + { + return rand(0, 1) ? new SomeInstance() : null; + } +}