public function LingotekNodeManageTranslationTabTest::testResetAssignJobIds in Lingotek Translation 3.3.x
Same name and namespace in other branches
- 8.2 tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 4.0.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 3.0.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 3.1.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 3.2.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 3.4.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 3.5.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 3.6.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 3.7.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
- 3.8.x tests/src/Functional/LingotekNodeManageTranslationTabTest.php \Drupal\Tests\lingotek\Functional\LingotekNodeManageTranslationTabTest::testResetAssignJobIds()
Tests that can we reset assignation of job ids with the bulk operation.
File
- tests/
src/ Functional/ LingotekNodeManageTranslationTabTest.php, line 642
Class
- LingotekNodeManageTranslationTabTest
- Tests translating a node using the bulk management form.
Namespace
Drupal\Tests\lingotek\FunctionalCode
public function testResetAssignJobIds() {
// Create a couple of content.
$edit = [];
$edit['title[0][value]'] = 'Llamas are cool';
$edit['body[0][value]'] = 'Llamas are very cool';
$edit['langcode[0][value]'] = 'en';
$edit['field_tags[target_id]'] = implode(',', [
'Camelid',
'Herbivorous',
]);
$edit['lingotek_translation_management[lingotek_translation_profile]'] = 'manual';
$this
->saveAndPublishNodeForm($edit);
$this
->goToContentBulkManagementForm();
// I can init the upload of content.
$this
->assertLingotekUploadLink(1, 'node');
$this
->assertLingotekUploadLink(1, 'taxonomy_term', NULL, 'node');
// Canceling resets.
$edit = [
'table[taxonomy_term:1]' => TRUE,
$this
->getBulkOperationFormName() => $this
->getBulkOperationNameForAssignJobId('node'),
];
$this
->drupalPostForm(NULL, $edit, $this
->getApplyActionsButtonLabel());
$this
->assertText('Camelid');
$this
->assertNoText('Llamas are cool');
$this
->goToContentBulkManagementForm();
$edit = [
'table[node:1]' => TRUE,
$this
->getBulkOperationFormName() => $this
->getBulkOperationNameForAssignJobId('node'),
];
$this
->drupalPostForm(NULL, $edit, $this
->getApplyActionsButtonLabel());
$this
->assertNoText('Camelid');
$this
->assertText('Llamas are cool');
}