public virtual ApiTransactionResponseModel MapBOToModel( BOTransaction boTransaction) { var model = new ApiTransactionResponseModel(); model.SetProperties(boTransaction.Id, boTransaction.Amount, boTransaction.GatewayConfirmationNumber, boTransaction.TransactionStatusId); return(model); }
public void MapResponseToRequest() { var mapper = new ApiTransactionModelMapper(); var model = new ApiTransactionResponseModel(); model.SetProperties(1, 1m, "A", 1); ApiTransactionRequestModel response = mapper.MapResponseToRequest(model); response.Amount.Should().Be(1m); response.GatewayConfirmationNumber.Should().Be("A"); response.TransactionStatusId.Should().Be(1); }