public void Should_Retrieve_IyziLinks_With_Pagination() { PagingRequest pagingRequest = new PagingRequest(); pagingRequest.Page = 1; pagingRequest.Count = 1; pagingRequest.Locale = Locale.TR.ToString(); pagingRequest.ConversationId = "123456789"; ResponsePagingData <IyziLinkItem> response = IyziLink.RetrieveAll(pagingRequest, options); PrintResponse(response); Assert.AreEqual(Status.SUCCESS.ToString(), response.Status); Assert.AreEqual(Locale.TR.ToString(), response.Locale); Assert.AreEqual("123456789", response.ConversationId); Assert.NotNull(response.SystemTime); Assert.AreEqual(1, response.Data.Items.Count); Assert.AreEqual(1, response.Data.CurrentPage); }
public void Should_Retrieve_IyziLinks_With_Pagination() { IyziLinkSaveRequest request = new IyziLinkSaveRequest(); request.Locale = Locale.TR.ToString(); request.ConversationId = "123456789"; request.Name = "ft-name"; request.Description = "ft-description"; request.Base64EncodedImage = "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8H8BwGwAF0QIs4BDpAAAAAABJRU5ErkJggg=="; request.Price = "1"; request.Currency = Currency.TRY.ToString(); request.AddressIgnorable = false; request.SoldLimit = 1; request.InstallmentRequested = false; IyziLink.Create(request, _options); PagingRequest pagingRequest = new PagingRequest(); pagingRequest.Page = 1; pagingRequest.Count = 1; pagingRequest.Locale = Locale.TR.ToString(); pagingRequest.ConversationId = "123456789"; ResponsePagingData <IyziLinkItem> response = IyziLink.RetrieveAll(pagingRequest, _options); PrintResponse(response); Assert.AreEqual(Status.SUCCESS.ToString(), response.Status); Assert.AreEqual(Locale.TR.ToString(), response.Locale); Assert.AreEqual("123456789", response.ConversationId); Assert.NotNull(response.SystemTime); Assert.AreEqual(1, response.Data.Items.Count); Assert.AreEqual(1, response.Data.CurrentPage); }