You are here

public function DrushTest::testFailingFieldsSourceThrowsException in Migrate Tools 8.5

Same name and namespace in other branches
  1. 8.4 tests/src/Kernel/DrushTest.php \Drupal\Tests\migrate_tools\Kernel\DrushTest::testFailingFieldsSourceThrowsException()

Tests that a failing fields source throws an exception (i.e. exit code).

File

tests/src/Kernel/DrushTest.php, line 282

Class

DrushTest
Tests for the Drush 9 commands.

Namespace

Drupal\Tests\migrate_tools\Kernel

Code

public function testFailingFieldsSourceThrowsException() : void {
  $this
    ->expectException(\Exception::class);
  $this
    ->expectExceptionMessage('Migration does_not_exist does not exist');
  $this->commands
    ->fieldsSource('does_not_exist');
}