#How to test other edge cases of subscriptions?

1 messages · Page 1 of 1 (latest)

opaque badge
#

we can test the success n failure case by using the success n fail cards, but what about other edge cases of pending , on hold , cancelled , and other edge cases , specially for subscriptions?

tired hornetBOT
# opaque badge we can test the success n failure case by using the success n fail cards, but wh...

To test various edge cases for subscriptions using Dodo Payments, you can utilize specific test scenarios and card numbers designed for different outcomes. Here’s how you can approach testing for pending, on hold, cancelled, and other subscription-related edge cases:

  1. Pending Payments:

    • Use a test card that simulates a pending payment. This scenario can occur when a payment is initiated but not yet completed. Check how your application handles this state and whether it correctly updates the user interface to reflect the pending status.
  2. On Hold Subscriptions:

    • For subscriptions that are put on hold (e.g., due to failed renewals), you can simulate this by using a test card that triggers a failure during the renewal process. Ensure your application can handle this state by notifying users and providing options for resolving the issue.
  3. Cancelled Subscriptions:

    • To test cancelled subscriptions, you can use a test scenario where a subscription is manually cancelled after being active. Verify that your application correctly updates the subscription status and informs the user about the cancellation.
  4. Other Edge Cases:

    • For scenarios like disputes or refunds, you can simulate these events using the appropriate test cards or by triggering specific webhook events. Ensure your application can handle these cases by providing the necessary user feedback and updating records accordingly.
  5. Webhook Testing:

    • Implement webhook handlers for various subscription events (e.g., subscription.on_hold, subscription.cancelled). Use test webhooks to simulate these events and verify that your application reacts appropriately.

By covering these edge cases in your testing, you can ensure that your application is robust and can handle various subscription states effectively. If you need specific test card numbers or further guidance on implementing these tests, refer to the Dodo Payments documentation or support resources.

tired hornetBOT
opaque badge
#

ps + how to setup ways for the user to cancel the subscription?

lyric marten
lyric marten