You are here

public function MigrateIngredient71Test::testIngredient in Recipe 8.2

Tests the Drupal 7 ingredient to Drupal 8 migration.

File

modules/ingredient/tests/src/Kernel/Migrate/recipe71/MigrateIngredient71Test.php, line 48

Class

MigrateIngredient71Test
@covers \Drupal\ingredient\Plugin\migrate\destination\EntityIngredient @covers \Drupal\ingredient\Plugin\migrate\source\recipe1x\Ingredient @group recipe

Namespace

Drupal\Tests\ingredient\Kernel\Migrate\recipe71

Code

public function testIngredient() {
  $ingredients = Database::getConnection('default', 'migrate')
    ->select('recipe_ingredient', 'i')
    ->fields('i')
    ->execute()
    ->fetchAll();
  foreach ($ingredients as $source) {
    $this
      ->assertEntity($source->id, $source->name);
  }
}