You are here

protected function LingotekNodeBulkDisassociateTest::createAndTranslateNodeWithLinks in Lingotek Translation 8

2 calls to LingotekNodeBulkDisassociateTest::createAndTranslateNodeWithLinks()
LingotekNodeBulkDisassociateTest::testNodeDisassociate in src/Tests/LingotekNodeBulkDisassociateTest.php
Tests that a node can be translated using the links on the management page.
LingotekNodeBulkDisassociateTest::testNodeDisassociateWithRemovalOfRemoteDocument in src/Tests/LingotekNodeBulkDisassociateTest.php
Tests that a node can be disassociated and the remote document will be removed.

File

src/Tests/LingotekNodeBulkDisassociateTest.php, line 151

Class

LingotekNodeBulkDisassociateTest
Tests translating a node using the bulk management form.

Namespace

Drupal\lingotek\Tests

Code

protected function createAndTranslateNodeWithLinks() {
  $this
    ->goToContentBulkManagementForm();
  $basepath = \Drupal::request()
    ->getBasePath();

  // Clicking English must init the upload of content.
  $this
    ->clickLink('EN');
  $this
    ->assertText('Node Llamas are cool has been uploaded.');

  // There is a link for checking status.
  $this
    ->clickLink('EN');
  $this
    ->assertText('The import for node Llamas are cool is complete.');

  // Request the Spanish translation.
  $this
    ->clickLink('ES');
  $this
    ->assertText("Locale 'es_ES' was added as a translation target for node Llamas are cool.");

  // Check status of the Spanish translation.
  $this
    ->clickLink('ES');
  $this
    ->assertText('The es_ES translation for node Llamas are cool is ready for download.');

  // Download the Spanish translation.
  $this
    ->clickLink('ES');
  $this
    ->assertText('The translation of node Llamas are cool into es_ES has been downloaded.');
}