mirror of
https://github.com/rectorphp/rector.git
synced 2024-06-01 00:40:52 +00:00
[DeprecationExtractor] deprecatinos wont be in tests
This commit is contained in:
parent
0b4da17102
commit
594422ccb3
|
@ -55,9 +55,6 @@ final class DeprecationExtractor
|
|||
}
|
||||
|
||||
/**
|
||||
* @todo duplicated method to
|
||||
* @see \Rector\Console\Command\ReconstructCommand, extract to class
|
||||
*
|
||||
* @param string[] $directories
|
||||
* @return SplFileInfo[] array
|
||||
*/
|
||||
|
@ -66,7 +63,7 @@ final class DeprecationExtractor
|
|||
$finder = Finder::create()
|
||||
->files()
|
||||
->name('*.php')
|
||||
->exclude('Tests') // obscure code, not common in /app
|
||||
->exclude(['tests', 'Tests']) // deprecations won't be in tests
|
||||
->in($directories);
|
||||
|
||||
return iterator_to_array($finder->getIterator());
|
||||
|
|
|
@ -6,6 +6,9 @@ use Rector\DeprecationExtractor\Contract\Deprecation\DeprecationInterface;
|
|||
|
||||
final class MessageToDeprecationTransformer
|
||||
{
|
||||
/**
|
||||
* @todo require some context
|
||||
*/
|
||||
public function transform(string $message): DeprecationInterface
|
||||
{
|
||||
dump($message);
|
||||
|
|
|
@ -38,12 +38,6 @@ final class MessageToDeprecationTransformerTest extends AbstractContainerAwareTe
|
|||
]);
|
||||
|
||||
$deprecationMessages = $this->deprecationCollector->getDeprecationMessages();
|
||||
dump($deprecationMessages);
|
||||
die;
|
||||
|
||||
// $this->messageToDeprecationTransformer->transform();
|
||||
|
||||
// @todo
|
||||
$this->assertSame(1, 1);
|
||||
$this->assertCount(17, $deprecationMessages);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user