Skip to content

Commit 5a9c214

Browse files
committed
chore: updates
1 parent 44aa5c9 commit 5a9c214

5 files changed

Lines changed: 62 additions & 30 deletions

File tree

rules-tests/DeadCode/Rector/ClassMethod/RemoveEmptyClassMethodRector/Fixture/removed_empty_construct_when_no_parent.php.inc

Lines changed: 0 additions & 30 deletions
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?php
2+
3+
namespace Rector\Tests\DeadCode\Rector\ClassMethod\RemoveEmptyClassMethodRector\Fixture;
4+
5+
use Rector\Tests\DeadCode\Rector\ClassMethod\RemoveEmptyClassMethodRector\Source\ParentWithoutConstructor;
6+
7+
class RemovedEmptyConstructWhenNoParentConstruct extends ParentWithoutConstructor
8+
{
9+
public function __construct()
10+
{
11+
}
12+
}
13+
14+
?>
15+
-----
16+
<?php
17+
18+
namespace Rector\Tests\DeadCode\Rector\ClassMethod\RemoveEmptyClassMethodRector\Fixture;
19+
20+
use Rector\Tests\DeadCode\Rector\ClassMethod\RemoveEmptyClassMethodRector\Source\ParentWithoutConstructor;
21+
22+
class RemovedEmptyConstructWhenNoParentConstruct extends ParentWithoutConstructor
23+
{
24+
}
25+
26+
?>
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?php
2+
3+
namespace Rector\Tests\DeadCode\Rector\ClassMethod\RemoveEmptyClassMethodRector\Fixture;
4+
5+
use Rector\Tests\DeadCode\Rector\ClassMethod\RemoveEmptyClassMethodRector\Source\TraitWithConstructor;
6+
7+
class SkipConstructFromTrait
8+
{
9+
use TraitWithConstructor;
10+
11+
public function __construct()
12+
{
13+
}
14+
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace Rector\Tests\DeadCode\Rector\ClassMethod\RemoveEmptyClassMethodRector\Source;
6+
7+
class ParentWithoutConstructor
8+
{
9+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace Rector\Tests\DeadCode\Rector\ClassMethod\RemoveEmptyClassMethodRector\Source;
6+
7+
trait TraitWithConstructor
8+
{
9+
public function __construct()
10+
{
11+
return;
12+
}
13+
}

0 commit comments

Comments
 (0)