/// <summary> /// Define base tests fixture. /// </summary> public BaseTestsFixture() { Context = ApplicationContextFactory.Create(); var configurationProvider = new MapperConfiguration(cfg => { cfg.AddProfile <SaleProfile>(); }); Mapper = configurationProvider.CreateMapper(); }
/// <summary> /// Define base tests fixture. /// </summary> public BaseTestsFixture() { Context = ApplicationContextFactory.Create(); var configurationProvider = new MapperConfiguration(cfg => { cfg.AddProfile <AuthorProfile>(); cfg.AddProfile <TopicProfile>(); cfg.AddProfile <PostProfile>(); cfg.AddProfile <CommentProfile>(); }); Mapper = configurationProvider.CreateMapper(); }
/// <summary> /// Разрушить контекст. /// </summary> public void Dispose() { ApplicationContextFactory.Destroy(Context); }