Beispiel #1
0
 public UnitOfWorkMem()
 {
     context          = new VideoAppContext();
     VideoRepository  = new VideoRepositoryEFMemory(context);
     GenreRepository  = new GenreRepository(context);
     RentalRepository = new RentalRepository(context);
 }
 public UnitOfWork()
 {
     context = new VideoAppContext();
     context.Database.EnsureCreated();
     VideoRepository = new VideoRepositoryEFMemory(context);
     GenreRepository = new GenreRepo(context);
 }
 public UnitOfWork()
 {
     context = new VideoAppContext();
     // context.Database.EnsureDeleted();
     context.Database.EnsureCreated();
     VideoRepository = new VideoRepositoryEFMemory(context);
     OrderRepository = new OrderRepository(context);
 }
Beispiel #4
0
        public UnitOfWorkMem()
        {
            context = new InMemoryContext();
            context.Database.EnsureCreated();

            VideoRepository  = new VideoRepositoryEFMemory(context);
            GenreRepository  = new GenreRepository(context);
            RentalRepository = new RentalRepository(context);
        }
Beispiel #5
0
 public UnitOfWork()
 {
     context         = new VideoAppContext();
     VideoRepository = new VideoRepositoryEFMemory(context);
     OrderRepository = new OrderRepository(context);
 }
 public UnitOfWorkMem()
 {
     context         = new InMemoryContext();
     VideoRepository = new VideoRepositoryEFMemory(context);
     GenreRepository = new GenreRepoEFMemory(context);
 }
Beispiel #7
0
 public UnitOfWork()
 {
     context              = new VideoShackContext();
     VideoRepository      = new VideoRepositoryEFMemory(context);
     CollectionRepository = new CollectionRepository(context);
 }