Skip to content

Commit d7ff279

Browse files
committed
Fix tests
1 parent 7d1eb25 commit d7ff279

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

tests/Functional/Schema/SchemaManagerTest.php

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,11 @@ public function testIntrospectTableWithDotInIndexNames(): void
286286
->setTypeName(Types::INTEGER)
287287
->create(),
288288
)
289+
->setPrimaryKeyConstraint(
290+
PrimaryKeyConstraint::editor()
291+
->setUnquotedColumnNames('id')
292+
->create(),
293+
)
289294
->create();
290295

291296
$this->dropAndCreateTable($table);
@@ -305,28 +310,27 @@ public function testIntrospectTableWithDotInIndexNames(): void
305310
->setPrimaryKeyConstraint(
306311
PrimaryKeyConstraint::editor()
307312
->setUnquotedColumnNames('id')
308-
->setQuotedName('pk.example.id')
309313
->create(),
310314
)
311315
->setForeignKeyConstraints(
312316
ForeignKeyConstraint::editor()
313317
->setUnquotedReferencingColumnNames('user_id')
314-
->setReferencedTableName('test_user')
318+
->setUnquotedReferencedTableName('test_user')
315319
->setUnquotedReferencedColumnNames('id')
316320
->setQuotedName('fk.example.user_id')
317321
->create(),
318322
)
319-
->setIndexes([Index::editor()
323+
->setIndexes(
324+
Index::editor()
320325
->setQuotedName('idx.example.id')
321326
->setUnquotedColumnNames('id', 'user_id')
322327
->create(),
323-
])
328+
)
324329
->create();
325330
$this->dropAndCreateTable($tableTo);
326331

327332
$table = $this->schemaManager->introspectTable('example');
328333
self::assertCount(2, $table->getColumns());
329-
self::assertSame('pk.example.id', $table->getPrimaryKeyConstraint()->getObjectName()->toString());
330334
self::assertSame('fk.example.user_id', $table->getForeignKey('fk.example.user_id')->getName());
331335
self::assertSame('idx.example.id', $table->getIndex('idx.example.id')->getName());
332336
}

0 commit comments

Comments
 (0)