public function BambooTwigTokenTest::testSubstituteToken in Bamboo Twig 8.3
Same name and namespace in other branches
- 8.5 tests/src/Functional/BambooTwigTokenTest.php \Drupal\Tests\bamboo_twig\Functional\BambooTwigTokenTest::testSubstituteToken()
 - 8.2 tests/src/Functional/BambooTwigTokenTest.php \Drupal\Tests\bamboo_twig\Functional\BambooTwigTokenTest::testSubstituteToken()
 - 8.4 tests/src/Functional/BambooTwigTokenTest.php \Drupal\Tests\bamboo_twig\Functional\BambooTwigTokenTest::testSubstituteToken()
 
@covers Drupal\bamboo_twig_token\TwigExtension\Token::substituteToken
File
- tests/
src/ Functional/ BambooTwigTokenTest.php, line 45  
Class
- BambooTwigTokenTest
 - Tests Token twig filters and functions.
 
Namespace
Drupal\Tests\bamboo_twig\FunctionalCode
public function testSubstituteToken() {
  $this
    ->drupalGet('/bamboo-twig-token');
  $this
    ->assertElementPresent('.test-token div.token-site');
  $this
    ->assertElementContains('.test-token div.token-site', 'Drupal');
  $this
    ->assertElementPresent('.test-token div.token-node');
  $this
    ->assertElementContains('.test-token div.token-node', 'Hello, world!');
}