public function BambooTwigI18nTest::testCurrentLang in Bamboo Twig 8.5
Same name and namespace in other branches
- 8.2 tests/src/Functional/BambooTwigI18nTest.php \Drupal\Tests\bamboo_twig\Functional\BambooTwigI18nTest::testCurrentLang()
- 8.3 tests/src/Functional/BambooTwigI18nTest.php \Drupal\Tests\bamboo_twig\Functional\BambooTwigI18nTest::testCurrentLang()
- 8.4 tests/src/Functional/BambooTwigI18nTest.php \Drupal\Tests\bamboo_twig\Functional\BambooTwigI18nTest::testCurrentLang()
@covers Drupal\bamboo_twig_i18n\TwigExtension\I18n::getCurrentLanguage
File
- tests/
src/ Functional/ BambooTwigI18nTest.php, line 82
Class
- BambooTwigI18nTest
- Tests I18n twig filters and functions.
Namespace
Drupal\Tests\bamboo_twig\FunctionalCode
public function testCurrentLang() {
$this
->drupalGet('/bamboo-twig-i18n');
$this
->assertElementContains('.test-i18n div.i18n-current-lang', 'en');
$this
->drupalGet('/fr/bamboo-twig-i18n');
$this
->assertElementContains('.test-i18n div.i18n-current-lang', 'fr');
}