Testing Your Integration
Testing Best Practices
We recommend that you test your integration end to end in the sandbox environment before deploying in production. This means that you should test from the POS application UI to invoke API calls to the Braintree card reader, complete payment using test cards, check the Braintree control panel and validate the solution works end to end, including the unhappy path flows.
In order to make sure your application can handle various context status' use the amounts in the table below to simulate different scenarios in the Braintree sandbox environment.
Testing with Digital Wallets
The Braintree sandbox does not allow for testing of digital wallets on the Braintree dev kit readers. The behavior of these payments methods is exactly the same as contactless cards from both an API perspective and from a UX/UI perspective.
Transaction amounts
When working with in-store transactions in the sandbox environment, you can pass specific amounts to simulate different context status'. Transactions performed with the test amounts below will end with the corresponding Context Status and Payment Status.
Amount |
Context Status |
Payment Status |
0.01 - 1999.99 |
COMPLETE |
SUBMITTED_FOR_SETTLEMENT |
1004.00 |
COMPLETE |
SUBMITTED_FOR_SETTLEMENT |
2000.00 - 2999.99 |
FAILED |
PROCESSOR_DECLINED |
3000.00 - 3000.99 |
FAILED |
FAILED |
5001.00 |
FAILED |
GATEWAY_REJECTED |
5002.00 and up (except 9000.00) |
COMPLETE |
SUBMITTED_FOR_SETTLEMENT |
9000.00 (insert card to test) |
FAILED |
VOIDED |
Simulating Processor Responses
Braintree will also return raw processor response codes in the API response. You may want to parse and consume these detailed processor response codes to provide detailed reason codes to your cashier or accounting team.
Integration Readiness Questionnaire
It is most important to test all of the the use cases relevant to your business, however, it is also critical that your integration meets the most basic requirements to function properly once you deploy to the production environment. The questions below are meant as a gut check to make sure you are meeting those requirements and using best development practices: