public void TestInitialize()
        {
            RepositoryTestsHelper.Init(Consts.Collections.FlowCollectionName);
            var flowOdataProvider = new Mock <IFlowOdataProvider>().Object;

            _repository = new FlowReadRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)), flowOdataProvider);
        }
예제 #2
0
        public void TestInitialize()
        {
#if DEBUG
            RepositoryTestsHelper.Init();
            _finder = new UserFinder(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)));
#endif
        }
        public void TestInitialize()
        {
            RepositoryTestsHelper.Init(Consts.Collections.Teams);
            ITeamOdataProvider odataProvider = new TeamOdataProvider();

            _repository = new TeamReadRepository(new Teams.Infrastructure.DataAccess.Configurations.Impl.PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)), odataProvider);
        }
예제 #4
0
        public void TestInitialize()
        {
            RepositoryTestsHelper.Init("WorkOrders");
            IModelConverter modelConverter = new ModelConverter(new TypeConverterProvider(), new DateTimeProvider());

            _repository       = new WorkOrderWriteRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)), modelConverter);
            _dateTimeProvider = new DateTimeProvider();
        }
        public void TestInitialize()
        {
            var config = new MapperConfiguration(cfg =>
            {
                cfg.AddProfile <DomainToClassProfile>();
                cfg.AddProfile <ClassToDomainProfile>();
            });
            var mapper = new Mapper(config);

            RepositoryTestsHelper.Init(Consts.Collections.OperatorActivityCollectionName);
            _repository = new OperatorActivityWriteRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)), mapper);
        }
예제 #6
0
        public void TestInitialize()
        {
            var odataProvider = new Mock <ILocationOdataProvider>().Object;
            var config        = new MapperConfiguration(cfg =>
            {
                cfg.AddProfile <DomainToClassProfile>();
                cfg.AddProfile <ClassToDomainProfile>();
            });
            var mapper = new Mapper(config);

            RepositoryTestsHelper.Init(Consts.Collections.LocationCollectionName);
            _repository = new LocationReadRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)), odataProvider, mapper);
        }
        public void TestInitialize()
        {
            RepositoryTestsHelper.Init(Consts.Collections.OperatorActivityCollectionName);
            var odataProviderMock = new Mock <IOperatorActivityOdataProvider>();

            odataProviderMock.Setup(x => x.GetFilterPredicate(It.IsAny <string>())).Returns((object o) => null);
            var odataProvider = odataProviderMock.Object;

            var config = new MapperConfiguration(cfg =>
            {
                cfg.AddProfile <DomainToClassProfile>();
                cfg.AddProfile <ClassToDomainProfile>();
            });

            mapper          = new Mapper(config);
            _readRepository = new OperatorActivityReadRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)), odataProvider, mapper);
        }
예제 #8
0
 public void TestInitalize()
 {
     RepositoryTestsHelper.Init(Consts.Collections.SourceCollectionName);
     _repository = new SourceReadRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)));
 }
예제 #9
0
 public void TestInitialize()
 {
     RepositoryTestsHelper.Init(Consts.Collections.Operators);
     _repository = new OperatorWriteRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)));
 }
 public void TestInitialize()
 {
     RepositoryTestsHelper.Init(Consts.Collections.TypePlanningCollectionName);
     _repository = new TypePlanningWriteRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)));
 }
 public void TestInitialize()
 {
     RepositoryTestsHelper.Init("Concepts");
     _repository = new ConceptWriteRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)));
 }
 public void TestInitialize()
 {
     RepositoryTestsHelper.Init(Consts.Collections.BusinessUnitCollectionName);
     _repository = new BusinessUnitWriteRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)));
 }
 public void TestInitialize()
 {
     RepositoryTestsHelper.Init(Consts.Collections.StorageStatusCollectionName);
     _repository = new StorageStatusWriteRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)));
 }
 public void TestInitialize()
 {
     RepositoryTestsHelper.Init(Consts.Collections.OperationalDepartmentCollectionName);
     _repository = new OperationalDepartmentReadRepository(new PersistenceContext(new PersistenceConfiguration(RepositoryTestsHelper.ConnectionString)));
 }