private InitiateThirdPartyProcessorPayment CreatePaymentCommand(PricedOrder order) { // TODO: should add the line items? var description = "Registration for " + this.ConferenceAlias.Name; var totalAmount = order.Total; var paymentCommand = new InitiateThirdPartyProcessorPayment { PaymentId = Guid.NewGuid(), ConferenceId = this.ConferenceAlias.Id, PaymentSourceId = order.OrderId, Description = description, TotalAmount = totalAmount }; return paymentCommand; }
public void WhenTheComandForInitiateThePaymentIsSent() { var paymentCommand = new InitiateThirdPartyProcessorPayment { PaymentId = Guid.NewGuid(), ConferenceId = registerToConference.ConferenceId, PaymentSourceId = orderId, Description = "test", TotalAmount = 249 }; paymentId = paymentCommand.PaymentId; commandBus.Send(paymentCommand); }