沙盒:可以模拟故障或中断应用程序内购买? [英] Sandbox: Is possible to simulate a failed or interrupted In App Purchase?

查看:146
本文介绍了沙盒:可以模拟故障或中断应用程序内购买?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近在实现应用内购买我的应用程序。好在苹果记录了整个过程非常好。

I have recently implemented In App Purchasing in my app. Good thing Apple has documented the whole process very well.

使用这些文档,我终于能够通过沙盒,这是一个非常方便的功能来测试应用程序内采购。我已经成功地测试我的应用程序,使其反应无论 StoreKit 返回时,我点击了 buyButton

Using those docs, I'm finally able to test In App Purchasing through the Sandbox, which is a very convenient feature. I have successfully tested my app so that it reacts to whatever the StoreKit returns when I tap the buyButton.

现在,这里是我的问题。从文档,它说,沙盘模拟,没有财务的交易过程。所以,我是自由的,因为我想(顺便说一下,我买的耗材,仅耗材),以尽可能多的购买。此外,沙盒将始终模拟交易的成功,不管是什么。那么,是不是可以有沙盒模拟的失败事务,更好的是,一个中断交易?

Now here's my question. From the docs, it says that the Sandbox simulates the transaction process with no financial stuff. So I'm free to buy as much as I want (by the way, I'm buying consumables and only consumables). Also, the Sandbox will ALWAYS simulate a successful transaction, no matter what. So, is it possible to have the Sandbox simulate a failed transaction, and better yet, an interrupted transaction?

我想这样做陷阱可能出现的错误,当这些事件发生的(虽然我读的地方, StoreKit 已处理的),并在屏幕上显示出来(在至少),只是为了告知在交易过程中发生了什么用户。

I want to do that to trap possible errors when those events happen (although I've read somewhere that StoreKit already handles that) and display them on the screen (at the very least), just to inform the user what's happening during the transaction process.

先谢谢了。

推荐答案

一个简单的方法来模拟大量的常见网络交易的问题是从WiFi接入点的背面拔掉网线在各点所用处理。你可以尝试的东西,如拔掉无线广域网线,然后用备用或缆线访问来自可用性在iTunes Connect中删除您的IAP,然后重新启用无线网络连接。

An easy way to simulate lots of common networked transaction problems is to unplug the network cable from the back side of the wifi access point being used at various points in the process. You could try stuff like unplugging the wifi's WAN cable, then use alternate or cabled access to remove your IAP from availability in iTunes Connect, then re-enable wifi access.

这篇关于沙盒:可以模拟故障或中断应用程序内购买?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆