public async Task <OrderTransactionResponse> GetOrderTransactionAsync(string orderId, CancellationToken ct = default(CancellationToken)) { return(await this.ProcessAsync <OrderTransactionResponse>( PayUClientUrlBuilder.BuildOrderTransactionsUrl(this.settings.Url, this.settings.ApiVersion, orderId), HttpMethod.Get, ct)); }
public OrderTransactionResponse GetOrderTransaction(string orderId) { return(this.Process <OrderTransactionResponse>( PayUClientUrlBuilder.BuildOrderTransactionsUrl(this.settings.Url, this.settings.ApiVersion, orderId), HttpMethod.Get)); }
public static void BuildOrderTransactionsUrl_CorrectParameters_CorrectBuildedUrl() { Assert.Equal(new Uri("http://localhost:3000/api/v2.1/orders/orderId/transactions"), PayUClientUrlBuilder.BuildOrderTransactionsUrl("http://localhost:3000", "v2.1", "orderId")); }
public static void BuildOrderTransactionsUrl_NullEmptyApiVersion_ThrowsArgumentException(string apiVersion, string orderId) { Assert.Throws <ArgumentException>(() => PayUClientUrlBuilder.BuildOrderTransactionsUrl("http://localhost:3000", apiVersion, orderId)); }