We have moved to GitHub Issues
Created by Shannon Deminick 31 May 2016, 20:49:57 Updated by Stephan 02 Jun 2016, 12:38:18Tags: Unscheduled
Subtask of: U4-5482
We need to be able to pass in the runtime MigrationContext instance to create all of the migrations, we also need to update the MigrationRunner to use the MigrationContext instead of all of it's parts.
I have refactored the runner, etc...
Changes MigrationBase and all sub-classes to have an IMigrationContext as a ctor param. Updates the MigrationResolver to resolve Migration instances with the passed in IMigrationContext value. Simplifies MigrationBase since now we know we have a context to work with, there's no need to GetUp/GetDown Expression methods. Updates the MigrationRunner to use the MigrationContext instead of creating one itself.
reverts change made to remove the 'child container' - this actually works well and doesn't interfere with the main container's scope manager - but uses the built in IServiceContainer.Clone() method instead of our own extension to do that. Ignores the one failing test, need to ask Stephan
The failing test is:
Issue8370Test which is set to ignore. I cannot figure out the error so hoping @zpqrtbnk can.
I have tested running all migrations by forcing an upgrade (i.e. change web config to 7.2), all other tests pass and the migration classes, base classes and runners are much simpler.
code review looks good + it's working = fixed
looking into the test that fails
The failing test is caused by an NPoco issue.
Have reported: https://github.com/schotime/NPoco/issues/282 Have submitted a PR that fixes the issue, waiting for it to be merged.
Marking this issue as fixed, will take care of re-enabling the test when we upgrade NPoco.
Backwards Compatible: False
Due in version: 8.0.0
Sprint: Sprint 16