You are here

public function FreelinkingTest::testLongTip in Freelinking 8.3

Same name and namespace in other branches
  1. 4.0.x tests/src/Unit/Plugin/Filter/FreelinkingTest.php \Drupal\Tests\freelinking\Unit\Plugin\Filter\FreelinkingTest::testLongTip()

Asserts that a long tip is returned.

File

tests/src/Unit/Plugin/Filter/FreelinkingTest.php, line 121

Class

FreelinkingTest
Tests the freelinking plugin.

Namespace

Drupal\Tests\freelinking\Unit\Plugin\Filter

Code

public function testLongTip() {
  $expectedText = <<<EOF
<p>Freelinking helps you easily create HTML links. Links take the form of <code>[[indicator:target|Title]].</code><br />
Below is a list of available types of freelinks you may use, organized as <strong>Plugin Name</strong>: [<em>indicator</em>].</p>
<ul><li><strong>Dummy</strong> [<em>indicator</em>]: tip</li></ul>
EOF;
  $expected = new TranslatableMarkup($expectedText, [], [], $this->translationInterfaceMock);
  $this
    ->assertEquals($expected, $this->filter
    ->tips(TRUE));
}