MigrateUpdateTest.php in Commerce Migrate 3.1.x
File
modules/ubercart/tests/src/Functional/MigrateUpdateTest.php
View source
<?php
namespace Drupal\Tests\commerce_migrate_ubercart\Functional;
use Drupal\FunctionalTests\Update\UpdatePathTestBase;
class MigrateUpdateTest extends UpdatePathTestBase {
protected $defaultTheme = 'stark';
protected function setDatabaseDumpFiles() {
$this->databaseDumpFiles = [
DRUPAL_ROOT . '/core/modules/system/tests/fixtures/update/drupal-8.8.0.bare.standard.php.gz',
__DIR__ . '/../../fixtures/drupal-8-update-8201.php',
];
}
public function testUpdateTableNames() {
foreach ([
'migration_group',
'migration',
] as $entity_type) {
$definition = \Drupal::entityTypeManager()
->getDefinition($entity_type);
\Drupal::entityDefinitionUpdateManager()
->installEntityType($definition);
}
$this
->runUpdates();
$this
->assertTrue(\Drupal::database()
->schema()
->fieldExists('migrate_map_d7_field', 'sourceid3'));
}
}