mirror of
https://github.com/rectorphp/rector.git
synced 2025-02-21 01:41:00 +01:00
use data provider [skip ci]
This commit is contained in:
parent
6081373d39
commit
71893e2725
@ -7,19 +7,28 @@ use Rector\Testing\PHPUnit\AbstractRectorTestCase;
|
||||
|
||||
final class AddUuidToEntityWhereMissingRectorTest extends AbstractRectorTestCase
|
||||
{
|
||||
public function test(): void
|
||||
/**
|
||||
* @dataProvider provideDataForTest()
|
||||
*/
|
||||
public function test(string $file): void
|
||||
{
|
||||
$this->doTestFiles([
|
||||
__DIR__ . '/Fixture/fixture.php.inc',
|
||||
__DIR__ . '/Fixture/already_has_constructor.php.inc',
|
||||
__DIR__ . '/Fixture/process_string_id.php.inc',
|
||||
__DIR__ . '/Fixture/with_parent_constructor.php.inc',
|
||||
__DIR__ . '/Fixture/add_single_table_inheritance.php.inc',
|
||||
__DIR__ . '/Fixture/add_single_table_inheritance_with_identifier.php.inc',
|
||||
// skip
|
||||
__DIR__ . '/Fixture/skip_id_with_uuid_type.php.inc',
|
||||
__DIR__ . '/Fixture/skip_id_with_uuid_binary_type.php.inc',
|
||||
]);
|
||||
$this->doTestFile($file);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string[]
|
||||
*/
|
||||
public function provideDataForTest(): iterable
|
||||
{
|
||||
yield [__DIR__ . '/Fixture/fixture.php.inc'];
|
||||
yield [__DIR__ . '/Fixture/already_has_constructor.php.inc'];
|
||||
yield [__DIR__ . '/Fixture/process_string_id.php.inc'];
|
||||
yield [__DIR__ . '/Fixture/with_parent_constructor.php.inc'];
|
||||
yield [__DIR__ . '/Fixture/add_single_table_inheritance.php.inc'];
|
||||
yield [__DIR__ . '/Fixture/add_single_table_inheritance_with_identifier.php.inc'];
|
||||
// skip
|
||||
yield [__DIR__ . '/Fixture/skip_id_with_uuid_type.php.inc'];
|
||||
yield [__DIR__ . '/Fixture/skip_id_with_uuid_binary_type.php.inc'];
|
||||
}
|
||||
|
||||
protected function getRectorClass(): string
|
||||
|
Loading…
x
Reference in New Issue
Block a user