public virtual async void TestDelete()
        {
            var builder = new WebHostBuilder()
                          .UseEnvironment("Production")
                          .UseStartup <TestStartup>();
            TestServer testServer = new TestServer(builder);
            var        client     = new ApiClient(testServer.CreateClient());

            client.SetBearerToken(JWTTestHelper.GenerateBearerToken());
            ApplicationDbContext context = testServer.Host.Services.GetService(typeof(ApplicationDbContext)) as ApplicationDbContext;

            ICustomerService service = testServer.Host.Services.GetService(typeof(ICustomerService)) as ICustomerService;
            var model = new ApiCustomerServerRequestModel();

            model.SetProperties("B", "B", "B", "B");
            CreateResponse <ApiCustomerServerResponseModel> createdResponse = await service.Create(model);

            createdResponse.Success.Should().BeTrue();

            ActionResponse deleteResult = await client.CustomerDeleteAsync(2);

            deleteResult.Success.Should().BeTrue();
            ApiCustomerServerResponseModel verifyResponse = await service.Get(2);

            verifyResponse.Should().BeNull();
        }
        public void MapServerRequestToResponse()
        {
            var mapper = new ApiCustomerServerModelMapper();
            var model  = new ApiCustomerServerRequestModel();

            model.SetProperties("A", "A", "A", "A");
            ApiCustomerServerResponseModel response = mapper.MapServerRequestToResponse(1, model);

            response.Should().NotBeNull();
            response.Email.Should().Be("A");
            response.FirstName.Should().Be("A");
            response.LastName.Should().Be("A");
            response.Phone.Should().Be("A");
        }
        public void CreatePatch()
        {
            var mapper = new ApiCustomerServerModelMapper();
            var model  = new ApiCustomerServerRequestModel();

            model.SetProperties("A", "A", "A", "A");

            JsonPatchDocument <ApiCustomerServerRequestModel> patch = mapper.CreatePatch(model);
            var response = new ApiCustomerServerRequestModel();

            patch.ApplyTo(response);
            response.Email.Should().Be("A");
            response.FirstName.Should().Be("A");
            response.LastName.Should().Be("A");
            response.Phone.Should().Be("A");
        }