function DependencyOrderingTest::testUpdateOrderingSingleModule in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/system/src/Tests/Update/DependencyOrderingTest.php \Drupal\system\Tests\Update\DependencyOrderingTest::testUpdateOrderingSingleModule()
Test that updates within a single module run in the correct order.
File
- core/
modules/ system/ src/ Tests/ Update/ DependencyOrderingTest.php, line 34 - Contains \Drupal\system\Tests\Update\DependencyOrderingTest.
Class
- DependencyOrderingTest
- Tests that update functions are run in the proper order.
Namespace
Drupal\system\Tests\UpdateCode
function testUpdateOrderingSingleModule() {
$starting_updates = array(
'update_test_1' => 8001,
);
$expected_updates = array(
'update_test_1_update_8001',
'update_test_1_update_8002',
'update_test_1_update_8003',
);
$actual_updates = array_keys(update_resolve_dependencies($starting_updates));
$this
->assertEqual($expected_updates, $actual_updates, 'Updates within a single module run in the correct order.');
}