public function LingotekNodeBulkDebugTest::testDebugExportError in Lingotek Translation 3.7.x
Same name and namespace in other branches
- 8.2 tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 4.0.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 3.0.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 3.1.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 3.2.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 3.3.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 3.4.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 3.5.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 3.6.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
- 3.8.x tests/src/Functional/LingotekNodeBulkDebugTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeBulkDebugTest::testDebugExportError()
File
- tests/
src/ Functional/ LingotekNodeBulkDebugTest.php, line 112
Class
- LingotekNodeBulkDebugTest
- Tests debugging a node using the bulk management form.
Namespace
Drupal\Tests\lingotek\FunctionalCode
public function testDebugExportError() {
// Login as admin.
$this
->drupalLogin($this->rootUser);
// Create a node.
$node = Node::create([
'title' => 'Llamas are cool',
'type' => 'article',
]);
$node
->save();
/** @var \Drupal\lingotek\LingotekContentTranslationServiceInterface $translation_service */
$translation_service = \Drupal::service('lingotek.content_translation');
$translation_service
->deleteMetadata($node);
// Enable the debug operations.
$this
->drupalGet('admin/lingotek/settings');
$this
->drupalPostForm(NULL, [], t('Enable debug operations'));
$this
->goToContentBulkManagementForm();
$key = $this
->getBulkSelectionKey('en', 1);
$edit = [
$key => TRUE,
$this
->getBulkOperationFormName() => 'debug.export',
];
$this
->drupalPostForm(NULL, $edit, $this
->getApplyActionsButtonLabel());
$this
->assertText('The Article Llamas are cool has no profile assigned so it was not processed.');
$this
->assertNoText('Exports available');
}