You are here

public function GlossifyBaseTest::testParseTooltipMatch in Glossify 8

@covers ::parseTooltipMatch @dataProvider parseTooltipMatchData

File

tests/src/Unit/GlossifyBaseTest.php, line 19

Class

GlossifyBaseTest
@coversDefaultClass \Drupal\glossify\GlossifyBase

Namespace

Drupal\Tests\glossify\Unit

Code

public function testParseTooltipMatch($text, $terms, $case_sensitivity, $first_only, $displaytype, $urlpattern, $output) {

  // Instantiate dummy object.
  $dummyTooltip = new DummyTooltip($terms, $case_sensitivity, $first_only, $displaytype, $urlpattern);
  $replacement = $dummyTooltip
    ->process($text, 'nl');
  $this
    ->assertEquals($replacement, $output);
}