Add tag count assertion

> Failed asserting that actual size 0 matches expected size 3.
This commit is contained in:
Oliver Davies 2024-01-18 13:14:26 +00:00
parent a6d9e9a524
commit 22d61485fd

View file

@ -56,7 +56,9 @@ final class PostBuilderTest extends EntityKernelTestBase {
self::assertInstanceOf(NodeInterface::class, $node);
self::assertSame('post', $node->bundle());
$node->get('field_tags');
$tags = $node->get('field_tags')->referencedEntities();
self::assertCount(3, $tags);
}
}