You are here

protected function BlockContentTranslationUITest::getEditValues in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/block_content/tests/src/Functional/BlockContentTranslationUITest.php \Drupal\Tests\block_content\Functional\BlockContentTranslationUITest::getEditValues()
  2. 9 core/modules/block_content/tests/src/Functional/BlockContentTranslationUITest.php \Drupal\Tests\block_content\Functional\BlockContentTranslationUITest::getEditValues()

Returns an edit array containing the values to be posted.

File

core/modules/block_content/tests/src/Functional/BlockContentTranslationUITest.php, line 93

Class

BlockContentTranslationUITest
Tests the block content translation UI.

Namespace

Drupal\Tests\block_content\Functional

Code

protected function getEditValues($values, $langcode, $new = FALSE) {
  $edit = parent::getEditValues($values, $langcode, $new);
  foreach ($edit as $property => $value) {
    if ($property == 'info') {
      $edit['info[0][value]'] = $value;
      unset($edit[$property]);
    }
  }
  return $edit;
}