Use UseSqlServer in tests
This commit is contained in:
parent
2209b2e933
commit
9b188a047d
|
|
@ -5,6 +5,7 @@ using Microsoft.AspNet.Builder;
|
|||
using Microsoft.AspNet.Diagnostics;
|
||||
using Microsoft.AspNet.Diagnostics.Entity;
|
||||
using Microsoft.AspNet.Identity;
|
||||
using Microsoft.Data.Entity;
|
||||
using Microsoft.Framework.Caching.Memory;
|
||||
using Microsoft.Framework.ConfigurationModel;
|
||||
using Microsoft.Framework.DependencyInjection;
|
||||
|
|
@ -44,7 +45,8 @@ namespace MusicStore
|
|||
{
|
||||
services.AddEntityFramework()
|
||||
.AddSqlServer()
|
||||
.AddDbContext<MusicStoreContext>();
|
||||
.AddDbContext<MusicStoreContext>(options =>
|
||||
options.UseSqlServer(Configuration.Get("Data:DefaultConnection:ConnectionString")));
|
||||
}
|
||||
|
||||
// Add Identity services to the services container
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ using Microsoft.AspNet.Builder;
|
|||
using Microsoft.AspNet.Diagnostics;
|
||||
using Microsoft.AspNet.Diagnostics.Entity;
|
||||
using Microsoft.AspNet.Identity;
|
||||
using Microsoft.Data.Entity;
|
||||
using Microsoft.Framework.Caching.Memory;
|
||||
using Microsoft.Framework.ConfigurationModel;
|
||||
using Microsoft.Framework.DependencyInjection;
|
||||
|
|
@ -61,7 +62,8 @@ namespace MusicStore
|
|||
{
|
||||
services.AddEntityFramework()
|
||||
.AddSqlServer()
|
||||
.AddDbContext<MusicStoreContext>();
|
||||
.AddDbContext<MusicStoreContext>(options =>
|
||||
options.UseSqlServer(Configuration.Get("Data:DefaultConnection:ConnectionString")));
|
||||
}
|
||||
|
||||
// Add Identity services to the services container
|
||||
|
|
|
|||
Loading…
Reference in New Issue