You are here

public function ContactFormMatcherTest::testMatcherWidthDefaultConfiguration in Linkit 8.5

Tests contact form matcher.

File

tests/src/Kernel/Matchers/ContactFormMatcherTest.php, line 51

Class

ContactFormMatcherTest
Tests contact form matcher.

Namespace

Drupal\Tests\linkit\Kernel\Matchers

Code

public function testMatcherWidthDefaultConfiguration() {

  /** @var \Drupal\linkit\MatcherInterface $plugin */
  $plugin = $this->manager
    ->createInstance('entity:contact_form', []);
  $suggestions = $plugin
    ->execute('Lorem');
  $this
    ->assertEquals(1, count($suggestions
    ->getSuggestions()), 'Correct number of suggestions');
}