Skip to content

Commit

Permalink
SDK-2934: Exclude autowire classes from deadcode
Browse files Browse the repository at this point in the history
  • Loading branch information
vol4onok committed Jul 24, 2023
1 parent dd5d598 commit 0646f42
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Checker/DeadCode/DeadCodeFinder.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,8 @@ protected function getAllExtendedCoreClasses(string $path): array
'!*Bootstrap.php',
'!*Interface.php',
'!*QueryContainer.php',
'!*Repository.php',
'!*EntityManager.php',

Check warning on line 127 in src/Checker/DeadCode/DeadCodeFinder.php

View check run for this annotation

Codecov / codecov/patch

src/Checker/DeadCode/DeadCodeFinder.php#L126-L127

Added lines #L126 - L127 were not covered by tests
'!*DependencyInjector.php',
];
foreach ($this->getFinderIterator($path, $patterns) as $file) {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?php

namespace SprykerSdkTest\ValidProject\Pyz\Zed\DeadClass\Model;

use Spryker\Zed\DeadClass as SprykerDeadClass;

class AclEntityManager extends SprykerDeadClass
{

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?php

namespace SprykerSdkTest\ValidProject\Pyz\Zed\DeadClass\Model;

use Spryker\Zed\DeadClass as SprykerDeadClass;

class AclRepository extends SprykerDeadClass
{

}

0 comments on commit 0646f42

Please sign in to comment.