public function FacetTest::testDescription in Facets 8
Tests for getters that don't have setters.
@covers ::getDescription @covers ::getName
File
- tests/
src/ Kernel/ Entity/ FacetTest.php, line 50
Class
- FacetTest
- Class FacetTest.
Namespace
Drupal\Tests\facets\Kernel\EntityCode
public function testDescription() {
$entity = new Facet([
'description' => 'Owls',
], 'facets_facet');
$this
->assertEquals('Owls', $entity
->getDescription());
$entity = new Facet([
'description' => 'Owls',
'name' => 'owl',
], 'facets_facet');
$this
->assertEquals('owl', $entity
->getName());
}