Exemplo n.º 1
0
        public void MapBOToModelList()
        {
            var      mapper = new BOLApiKeyMapper();
            BOApiKey bo     = new BOApiKey();

            bo.SetProperties("A", "A", DateTimeOffset.Parse("1/1/1987 12:00:00 AM"), "A", "A");
            List <ApiApiKeyResponseModel> response = mapper.MapBOToModel(new List <BOApiKey>()
            {
                { bo }
            });

            response.Count.Should().Be(1);
        }
Exemplo n.º 2
0
        public void MapBOToModel()
        {
            var      mapper = new BOLApiKeyMapper();
            BOApiKey bo     = new BOApiKey();

            bo.SetProperties("A", "A", DateTimeOffset.Parse("1/1/1987 12:00:00 AM"), "A", "A");
            ApiApiKeyResponseModel response = mapper.MapBOToModel(bo);

            response.ApiKeyHashed.Should().Be("A");
            response.Created.Should().Be(DateTimeOffset.Parse("1/1/1987 12:00:00 AM"));
            response.Id.Should().Be("A");
            response.JSON.Should().Be("A");
            response.UserId.Should().Be("A");
        }