Code Duplication    Length = 12-12 lines in 2 locations

Tests/Unit/Fixture/TestPackage/IndexMigration.php 1 location

@@ 9-20 (lines=12) @@
6
use RDV\Bundle\MigrationBundle\Migration\Migration;
7
use RDV\Bundle\MigrationBundle\Migration\QueryBag;
8
9
class IndexMigration implements Migration
10
{
11
    /**
12
     * {@inheritdoc}
13
     */
14
    public function up(Schema $schema, QueryBag $queries)
15
    {
16
        $table = $schema->createTable('index_table');
17
        $table->addColumn('key', 'string', ['length' => 255]);
18
        $table->addIndex(['key'], 'index');
19
    }
20
}
21

Tests/Unit/Fixture/TestPackage/InvalidIndexMigration.php 1 location

@@ 9-20 (lines=12) @@
6
use RDV\Bundle\MigrationBundle\Migration\Migration;
7
use RDV\Bundle\MigrationBundle\Migration\QueryBag;
8
9
class InvalidIndexMigration implements Migration
10
{
11
    /**
12
     * {@inheritdoc}
13
     */
14
    public function up(Schema $schema, QueryBag $queries)
15
    {
16
        $table = $schema->createTable('index_table');
17
        $table->addColumn('key', 'string', ['length' => 500]);
18
        $table->addIndex(['key'], 'index');
19
    }
20
}
21