function MigrateSqlIdMapTest::testGetHighestIdInvalid
Same name in other branches
- 8.9.x core/modules/migrate/tests/src/Unit/MigrateSqlIdMapTest.php \Drupal\Tests\migrate\Unit\MigrateSqlIdMapTest::testGetHighestIdInvalid()
- 10 core/modules/migrate/tests/src/Unit/MigrateSqlIdMapTest.php \Drupal\Tests\migrate\Unit\MigrateSqlIdMapTest::testGetHighestIdInvalid()
- 11.x core/modules/migrate/tests/src/Unit/MigrateSqlIdMapTest.php \Drupal\Tests\migrate\Unit\MigrateSqlIdMapTest::testGetHighestIdInvalid()
Tests getHighestId method with invalid data.
@dataProvider getHighestIdInvalidDataProvider
Parameters
array $destination_ids: Array of destination ids.
File
-
core/
modules/ migrate/ tests/ src/ Unit/ MigrateSqlIdMapTest.php, line 1142
Class
- MigrateSqlIdMapTest
- Tests the SQL ID map plugin.
Namespace
Drupal\Tests\migrate\UnitCode
public function testGetHighestIdInvalid(array $destination_ids) {
$this->expectException(\LogicException::class);
$this->expectExceptionMessage('To determine the highest migrated ID the first ID must be an integer');
$this->destinationIds = $destination_ids;
$id_map = $this->getIdMap();
$id_map->getHighestId();
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.