Skip to content

Commit 301515c

Browse files
committed
One To One inverse index
1 parent 653773d commit 301515c

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

tests/TDBMAbstractServiceTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,8 @@ private static function initSchema(Connection $connection): void
438438
->column('artist_id')->references('artists')->comment('@JsonKey("feat") @JsonInclude');
439439

440440
$db->table('object_base')
441-
->column('id')->integer()->primaryKey()->autoIncrement();
441+
->column('id')->integer()->primaryKey()->autoIncrement()
442+
->column('label')->string();
442443
$db->table('object_inherited')
443444
->column('id')->integer()->primaryKey()->autoIncrement()
444445
->column('object_base_id')->references('object_base')->unique()->comment('@JsonCollection');

tests/TDBMDaoGeneratorTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2086,7 +2086,7 @@ public function testOneToOneInverseRelationGetter(): void
20862086
{
20872087
$objectBaseDao = new ObjectBaseDao($this->tdbmService);
20882088
$objectInheritedDao = new ObjectInheritedDao($this->tdbmService);
2089-
$objectBase = new ObjectBaseBean();
2089+
$objectBase = new ObjectBaseBean('label');
20902090
$objectBaseDao->save($objectBase);
20912091
$this->assertNull($objectBase->getObjectInherited());
20922092
$objectInherited = new ObjectInheritedBean($objectBase);

0 commit comments

Comments
 (0)