[UnionTypesRector] Do not refactor inherited methods (#6201)

# Failing Test for UnionTypesRector

Based on https://getrector.org/demo/6298a30b-d9f5-4fa0-b1f8-9712b0e98582

```
PHP Fatal error:  Declaration of Child::enqueueAt(DateTime|int $at) must be compatible with SomeParent::enqueueAt($at)
```
This commit is contained in:
Ruud Kamphuis 2021-04-22 14:47:25 +02:00 committed by GitHub
parent f17df67963
commit 40c0f3f0c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -0,0 +1,26 @@
<?php
namespace Vendor {
class SomeParent
{
public function enqueueAt($at)
{
}
}
}
namespace App {
use Vendor\SomeParent;
final class Child extends SomeParent
{
/**
* @param DateTime|int $at
*/
public function enqueueAt($at)
{
}
}
}
?>