mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-18 21:34:28 -04:00
moved rootdir to eloquera
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using NUnit.Framework;
|
||||
using NzbDrone.Common;
|
||||
using NzbDrone.Core.Datastore;
|
||||
|
||||
namespace NzbDrone.Core.Test.Framework
|
||||
@@ -23,11 +24,11 @@ namespace NzbDrone.Core.Test.Framework
|
||||
{
|
||||
if (memory)
|
||||
{
|
||||
_db = new EloqueraDbFactory().CreateMemoryDb();
|
||||
_db = new EloqueraDbFactory(new EnvironmentProvider()).CreateMemoryDb();
|
||||
}
|
||||
else
|
||||
{
|
||||
_db = new EloqueraDbFactory().Create(Guid.NewGuid().ToString());
|
||||
_db = new EloqueraDbFactory(new EnvironmentProvider()).Create();
|
||||
}
|
||||
|
||||
Mocker.SetConstant(Db);
|
||||
|
||||
@@ -28,6 +28,32 @@ namespace NzbDrone.Core.Test.Framework
|
||||
|
||||
}
|
||||
|
||||
public abstract class CoreTest<TSubject> : CoreTest
|
||||
{
|
||||
private TSubject _subject;
|
||||
|
||||
|
||||
protected TSubject Subject
|
||||
{
|
||||
get
|
||||
{
|
||||
if (_subject == null)
|
||||
{
|
||||
_subject = Mocker.Resolve<TSubject>();
|
||||
}
|
||||
|
||||
return _subject;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
protected void InitiateSubject()
|
||||
{
|
||||
_subject = Mocker.Resolve<TSubject>();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public abstract class SqlCeTest : CoreTest
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user