Exemplo n.º 1
0
 public MapController(IMapper mapper, IUnitOfWork unitOfWork, IOfficeMapService officeMapService)
 {
     _mapper             = mapper;
     _officeMapService   = officeMapService;
     _floorRepository    = unitOfWork.GetRepository <Floor>();
     _officeRepository   = unitOfWork.GetRepository <Office>();
     _roomTypeRepository = unitOfWork.GetRepository <RoomType>();
 }
Exemplo n.º 2
0
        public void TestInitializer()
        {
            var uow        = Substitute.For <IUnitOfWork2>();
            var unitOfWork = Substitute.For <IUnitOfWork>();

            _usersDbSet = Substitute.For <DbSet <ApplicationUser>, IQueryable <ApplicationUser>, IDbAsyncEnumerable <ApplicationUser> >();
            _usersDbSet.SetDbSetDataForAsync(MockUsers());

            uow.GetDbSet <ApplicationUser>().Returns(_usersDbSet);
            var mapper      = Substitute.For <IMapper>();
            var roleService = Substitute.For <IRoleService>();

            MockRoleService(roleService);

            _officeMapService = new OfficeMapService(mapper, unitOfWork, uow, roleService);
        }
Exemplo n.º 3
0
 public EventController(
     IMapper mapper,
     IEventService eventService,
     IEventListingService eventListingService,
     IEventUtilitiesService eventUtilitiesService,
     IEventParticipationService eventParticipationService,
     IEventCalendarService calendarService,
     IEventExportService eventExportService,
     IPostService postService,
     IOfficeMapService officeMapService,
     IAsyncRunner asyncRunner)
 {
     _mapper                    = mapper;
     _eventService              = eventService;
     _eventListingService       = eventListingService;
     _eventUtilitiesService     = eventUtilitiesService;
     _eventParticipationService = eventParticipationService;
     _calendarService           = calendarService;
     _eventExportService        = eventExportService;
     _postService               = postService;
     _officeMapService          = officeMapService;
     _asyncRunner               = asyncRunner;
 }