public QueryTestFixture() { Context = SurveyContextFactory.Create(); SurveyContextFactory.SeedSampleData(Context); var configurationProvider = new MapperConfiguration(cfg => { cfg.AddProfile <MappingProfile>(); }); Mapper = configurationProvider.CreateMapper(); }
public CommandTestBase() { var configurationProvider = new MapperConfiguration(cfg => { cfg.AddProfile <MappingProfile>(); }); Mapper = configurationProvider.CreateMapper(); Context = SurveyContextFactory.Create(); var mockUserService = new Mock <IUserService>(); mockUserService.Setup(service => service.GetUserInfo(It.IsAny <CancellationToken>())) .ReturnsAsync(new TestUser()); UserService = mockUserService.Object; SurveyContextFactory.SeedSampleData(Context); }
public void Dispose() { SurveyContextFactory.Destroy(Context); }