public HomeController( IWallPostsService wallPostsService, IEventsService eventsService) { this.wallPostsService = wallPostsService; this.eventsService = eventsService; }
public EventsService( IDeletableEntityRepository <Event> eventsRepository, IWallPostsService postsService, IDeletableEntityRepository <Post> postRepository) { this.eventsRepository = eventsRepository; this.postsService = postsService; this.postRepository = postRepository; }
public ListsService( IDeletableEntityRepository <List> listRepository, IDeletableEntityRepository <ListItem> listItemRepository, IWallPostsService postsService, IDeletableEntityRepository <Post> postRepository) { this.listRepository = listRepository; this.listItemRepository = listItemRepository; this.postsService = postsService; this.postRepository = postRepository; }
public EventServiceTests() { var options = new DbContextOptionsBuilder <ApplicationDbContext>() .UseInMemoryDatabase(Guid.NewGuid().ToString()).Options; this.dbContext = new ApplicationDbContext(options); this.eventsRepository = new EfDeletableEntityRepository <Event>(this.dbContext); this.postRepository = new EfDeletableEntityRepository <Post>(this.dbContext); AutoMapperConfig.RegisterMappings(typeof(TestEventViewModel).Assembly); this.postsService = new Mock <IWallPostsService>().Object; }
public PhotoAlbumsService( IDeletableEntityRepository <Album> albumRepository, IDeletableEntityRepository <Picture> pictureRepository, IWallPostsService postsService, IDeletableEntityRepository <Post> postRepository, ICloudinaryService cloudinaryService) { this.albumRepository = albumRepository; this.pictureRepository = pictureRepository; this.postsService = postsService; this.postRepository = postRepository; this.cloudinaryService = cloudinaryService; }
public PhotoAlbumsServiceTests() { var options = new DbContextOptionsBuilder <ApplicationDbContext>() .UseInMemoryDatabase(Guid.NewGuid().ToString()).Options; this.dbContext = new ApplicationDbContext(options); this.albumRepository = new EfDeletableEntityRepository <Album>(this.dbContext); this.postRepository = new EfDeletableEntityRepository <Post>(this.dbContext); this.pictureRepository = new EfDeletableEntityRepository <Picture>(this.dbContext); this.postsService = new Mock <IWallPostsService>().Object; this.cloudinaryService = new Mock <ICloudinaryService>().Object; AutoMapperConfig.RegisterMappings(typeof(TestAlbumViewModel).Assembly); }