$expected['initial'
] = "Upgrade a site by importing its files and the data from its database into a clean and empty new install of Drupal
$destination_site_version.";
$expected['incremental'
] = "An upgrade has already been performed on this site.";
foreach (['/upgrade', '/upgrade/incremental'
] as $expected) { if ($expected === '/upgrade/incremental'
) { // Set a performed time to signify an incremental migration. The time
// value is a UNIX timestamp.
$state->
set('migrate_drupal_ui.performed', 1
);
} // Test that an invalid step to any form goes to the correct first form.
$store->
set('step', 'foo'
);
$this->
assertFirstForm($session,
$expected);
// Test that an undefined step to any form goes to the correct first form.
$store->
delete('step'
);
$this->
assertFirstForm($session,
$expected);
// For forms that require data from the private store, test that when that
// data is missing the correct first page is displayed.
// The Id conflict form requires the migrations array.
$store->
delete('migrations'
);
$store->
set('step', 'idconflict'
);
$this->
drupalGet('/upgrade/idconflict'
);
$session->
addressEquals($expected);