You are here

public function HelpTopicTwigTest::testText in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/help_topics/tests/src/Unit/HelpTopicTwigTest.php \Drupal\Tests\help_topics\Unit\HelpTopicTwigTest::testText()

@covers ::getBody @covers ::getLabel

File

core/modules/help_topics/tests/src/Unit/HelpTopicTwigTest.php, line 56

Class

HelpTopicTwigTest
Unit test for the HelpTopicTwig class.

Namespace

Drupal\Tests\help_topics\Unit

Code

public function testText() {
  $this
    ->assertEquals($this->helpTopic
    ->getBody(), [
    '#markup' => self::PLUGIN_INFORMATION['body'],
  ]);
  $this
    ->assertEquals($this->helpTopic
    ->getLabel(), self::PLUGIN_INFORMATION['label']);
}