Пример #1
0
        public GetLocalAreasHandlerTests()
        {
            context       = A.Fake <WeeeContext>();
            authorization = A.Fake <IWeeeAuthorization>();
            mapper        = A.Fake <LocalAreaMap>();

            A.CallTo(() => context.LocalAreas).Returns(dbHelper.GetAsyncEnabledDbSet(new List <LocalArea>
            {
                new LocalArea()
                {
                    Name = "North", CompetentAuthorityId = Guid.NewGuid(), Id = Guid.NewGuid()
                },
                new LocalArea()
                {
                    Name = "East", CompetentAuthorityId = Guid.NewGuid(), Id = Guid.NewGuid()
                },
                new LocalArea()
                {
                    Name = "South", CompetentAuthorityId = Guid.NewGuid(), Id = Guid.NewGuid()
                },
                new LocalArea()
                {
                    Name = "West", CompetentAuthorityId = Guid.NewGuid(), Id = Guid.NewGuid()
                },
            }));

            handler = new GetLocalAreasHandler(context, authorization, mapper);
        }
Пример #2
0
 public LocalAreaMapTests()
 {
     mapper = new LocalAreaMap();
 }