You are here

public function SkipRowIfNotSetTest::testRowSkipWithoutMessage in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/migrate/tests/src/Unit/process/SkipRowIfNotSetTest.php \Drupal\Tests\migrate\Unit\process\SkipRowIfNotSetTest::testRowSkipWithoutMessage()
  2. 9 core/modules/migrate/tests/src/Unit/process/SkipRowIfNotSetTest.php \Drupal\Tests\migrate\Unit\process\SkipRowIfNotSetTest::testRowSkipWithoutMessage()

Tests that a skip row exception without a message is raised.

@covers ::transform

File

core/modules/migrate/tests/src/Unit/process/SkipRowIfNotSetTest.php, line 21

Class

SkipRowIfNotSetTest
Tests the skip row if not set process plugin.

Namespace

Drupal\Tests\migrate\Unit\process

Code

public function testRowSkipWithoutMessage() {
  $configuration = [
    'index' => 'some_key',
  ];
  $process = new SkipRowIfNotSet($configuration, 'skip_row_if_not_set', []);
  $this
    ->expectException(MigrateSkipRowException::class);
  $process
    ->transform('', $this->migrateExecutable, $this->row, 'destination_property');
}