mirror of
https://github.com/Sonarr/Sonarr.git
synced 2026-04-22 22:16:13 -04:00
Fixed some tests.
This commit is contained in:
@@ -11,20 +11,13 @@ namespace NzbDrone.Core.Test.Framework
|
||||
{
|
||||
protected override TestDatabase WithTestDb(Action<MigrationBase> beforeMigration)
|
||||
{
|
||||
var factory = Mocker.Resolve<DbFactory>();
|
||||
|
||||
var database = factory.Create(MigrationType, m =>
|
||||
return base.WithTestDb(m =>
|
||||
{
|
||||
if (m.GetType() == typeof(TMigration))
|
||||
{
|
||||
beforeMigration(m);
|
||||
}
|
||||
});
|
||||
|
||||
var testDb = new TestDatabase(database);
|
||||
Mocker.SetConstant(database);
|
||||
|
||||
return testDb;
|
||||
}
|
||||
|
||||
[SetUp]
|
||||
|
||||
Reference in New Issue
Block a user