function ContentTranslationWorkflowsTest::assertNoSharedElements

Same name in other branches
  1. 9 core/modules/content_translation/tests/src/Functional/ContentTranslationWorkflowsTest.php \Drupal\Tests\content_translation\Functional\ContentTranslationWorkflowsTest::assertNoSharedElements()
  2. 10 core/modules/content_translation/tests/src/Functional/ContentTranslationWorkflowsTest.php \Drupal\Tests\content_translation\Functional\ContentTranslationWorkflowsTest::assertNoSharedElements()
  3. 11.x core/modules/content_translation/tests/src/Functional/ContentTranslationWorkflowsTest.php \Drupal\Tests\content_translation\Functional\ContentTranslationWorkflowsTest::assertNoSharedElements()

Assert that the current page does not contain shared form elements.

1 call to ContentTranslationWorkflowsTest::assertNoSharedElements()
ContentTranslationWorkflowsTest::doTestWorkflows in core/modules/content_translation/tests/src/Functional/ContentTranslationWorkflowsTest.php
Checks that workflows have the expected behaviors for the given user.

File

core/modules/content_translation/tests/src/Functional/ContentTranslationWorkflowsTest.php, line 262

Class

ContentTranslationWorkflowsTest
Tests the content translation workflows for the test entity.

Namespace

Drupal\Tests\content_translation\Functional

Code

protected function assertNoSharedElements() {
    $language_none = LanguageInterface::LANGCODE_NOT_SPECIFIED;
    return $this->assertNoFieldByXPath("//input[@name='field_test_text[{$language_none}][0][value]']", NULL, 'Shared elements are not available on the translation form.');
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.