How to simulate purchase interruption in Xcode 12?

I have an issue with an app in the store, where someone trying to purchase with a expired credit card in the account, causes some kind of problem with the eventual purchase being recognized in my application after they fix billing.

I was trying to test this scenario in Xcode 12, using the new StoreKit configuration files - I set up a configuration with a product, then selected "Enable interrupted Purchase" in the editor menu.

When I made a purchase with that on, I eventually got back an error transaction in my StoreKit transaction listener. But I'm not sure if that is right, wouldn't it be "deferred" if the user went to go correct billing info? Also I see no way in Xcode to continue the purchase flow from an interruption, it just seems to send the error transaction then it is done - so I can't test the full scenario of correcting the billing issue and completing the purchase.

In the documentation for testing common StoreKit scenarios here:

https://developer.apple.com/documentation/storekit/in-app_purchase/testing_at_all_stages_of_development_with_xcode_and_sandbox

It explicitly says this can be done with StoreKit testing in Xcode:

"Test a failed purchase attempt when payment authorization failed"

So I am looking to see if I am testing the right thing, or there is something else I need to do to test a payment authorization failed flow.

Thanks!
In developer forum posting https://developer.apple.com/forums/thread/653144 I discuss the interrupted purchase flow. Your finding that there is an initial failed transaction is inline with how things actually work. I've not had a chance yet to work with the Xcode Test process, but I suspect you should just continue - if possible - until the successful purchase indication is processed. Hopefully one of the StoreKit Test engineers can expand on the correct test process.

rich kubota - rkubota@apple.com
developer technical support CoreOS/Hardware/MFI
Once the initial purchase fails, you can simulate the customer resolving the issue via the new transaction management UI in Xcode . The steps to do this are outlined in the "Test an Interrupted Purchase" section located here: https://developer.apple.com/documentation/storekit/in-app_purchase/testing_in-app_purchases_in_xcode.
How to simulate purchase interruption in Xcode 12?
 
 
Q