->
fields([ 'data' =>
serialize(array_merge_recursive($extensions,
['module' =>
['update_test_no_preexisting' => 0
]])),
]) ->
condition('name', 'core.extension'
) ->
execute();
} /**
* Tests the system module updates with no dependencies installed.
*/
public function testNoPreExistingSchema() { $schema = \Drupal::
service('update.update_hook_registry'
)->
getAllInstalledVersions();
$this->
assertArrayNotHasKey('update_test_no_preexisting',
$schema);
$this->
assertFalse(\Drupal::
state()->
get('update_test_no_preexisting_update_8001', FALSE
));
$update_url = Url::
fromRoute('system.db_update'
);
require_once $this->root . '/core/includes/update.inc';
// The site might be broken at the time so logging in using the UI might
// not work, so we use the API itself.
$this->
writeSettings([ 'settings' =>
[ 'update_free_access' =>
(object) [ 'value' => TRUE,