You are here

protected function TmgmtExtensionSuitTestBase::translateJobItems in TMGMT Extension Suite 8.2

Same name and namespace in other branches
  1. 8.3 tests/src/Functional/TmgmtExtensionSuitTestBase.php \Drupal\Tests\tmgmt_extension_suit\Functional\TmgmtExtensionSuitTestBase::translateJobItems()

Translates job items (marks as "needs review").

Parameters

array $jobItemIds:

1 call to TmgmtExtensionSuitTestBase::translateJobItems()
CheckStatusTest::testCheckStatus in tests/src/Functional/CheckStatusTest.php
Test tmgmt_extension_suit_add_to_check_status() function.

File

tests/src/Functional/TmgmtExtensionSuitTestBase.php, line 151

Class

TmgmtExtensionSuitTestBase
Basic class for tmgmt extension module.

Namespace

Drupal\Tests\tmgmt_extension_suit\Functional

Code

protected function translateJobItems(array $jobItemIds) {
  foreach ($jobItemIds as $jobItemId) {
    $jobItem = JobItem::load($jobItemId);
    $jobItem
      ->setState(JobItem::STATE_REVIEW);
    $jobItem
      ->save();
  }
}