You are here

public function ContentTranslationUISkipTest::testUICheckSkip in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/content_translation/tests/src/Functional/ContentTranslationUISkipTest.php \Drupal\Tests\content_translation\Functional\ContentTranslationUISkipTest::testUICheckSkip()
  2. 10 core/modules/content_translation/tests/src/Functional/ContentTranslationUISkipTest.php \Drupal\Tests\content_translation\Functional\ContentTranslationUISkipTest::testUICheckSkip()

Tests the content_translation_ui_skip key functionality.

File

core/modules/content_translation/tests/src/Functional/ContentTranslationUISkipTest.php, line 29

Class

ContentTranslationUISkipTest
Tests the content translation UI check skip.

Namespace

Drupal\Tests\content_translation\Functional

Code

public function testUICheckSkip() {
  $admin_user = $this
    ->drupalCreateUser([
    'translate any entity',
    'administer content translation',
    'administer languages',
  ]);
  $this
    ->drupalLogin($admin_user);

  // Visit the content translation.
  $this
    ->drupalGet('admin/config/regional/content-language');

  // Check the message regarding UI integration.
  $this
    ->assertSession()
    ->pageTextContains('Test entity - Translatable skip UI check');
  $this
    ->assertSession()
    ->pageTextContains('Test entity - Translatable check UI (Translation is not supported)');
}