public DBasePersistenceServiceGenericsTest() { this.container = new UnityContainer(); this.container.RegisterType <IImgBoardContext, ImgBoardTestContext>(new HierarchicalLifetimeManager()); this.container.RegisterType <ICategoryRepository, CategoryRepository>(); this.container.RegisterType <ICommentRepository, CommentRepository>(); this.container.RegisterType <IImageRepository, ImageRepository>(); this.container.RegisterType <ITagRepository, TagRepository>(); this.container.RegisterType <ICategoryRepository, CategoryRepository>(); this.container.RegisterType <IUserRepository, UserRepository>(); this.container.RegisterType <IBaseMainService, PersistenceService>(); this.dataSet = new PersistentMainDataSet(); this.connection = new SqlConnection(DatabaseConfiguration.MainConnectionString); this.categoriesSqlHelper = new CategoriesSqlHelper(this.connection); this.category = new DbCategory { Title = "Category Title" }; }
public UsersTest() { Configuration.InversionOfControl.Initialize(); // dirty trick this.dataSet = new PersistentMainDataSet(); }
public DBaseGenericRepositoryTest() { this.dataSet = new PersistentMainDataSet(); }