Skip to content

Commit

Permalink
test: add failing test case for proxy and association
Browse files Browse the repository at this point in the history
  • Loading branch information
nikophil committed Nov 6, 2024
1 parent edf287e commit 536eea6
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions tests/Integration/ORM/ProxyEntityFactoryRelationshipTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,4 +134,16 @@ public function cannot_use_assert_persisted_when_entity_has_changes(): void
$this->expectException(RefreshObjectFailed::class);
$contact->_assertPersisted();
}

/**
* @test
*/
public function can_add_and_save_association(): void
{
$category = $this->categoryFactory()->create();

$contact = $this->contactFactory()->withoutPersisting()->create();
$category->addContact($contact);
$category->_save();
}
}

0 comments on commit 536eea6

Please sign in to comment.