I've got a Kotlin project that will be dealing with the webhooks calls made by Stripe.
I'd like to have some integration tests. While it's easy to do that manually by launching Stripe CLI and listen for events + mock some events, I'd like to have that automated.
Feature
I don't believe such thing is possible from the Java SDK and all the fixtures seems to be in stripe-cli project (which is legit ofc).
But I wonder what's my best option to achieve this:
Have a test file starting up the Stripe CLI
Start listening using Stripe CLI
Mock some calls using Stripe CLI
Assert that whatever is needed in my program was correctly called
Maybe there's already a proper way of doing that and I missed it? But I think this CLI is really handy and the logic behind it could be used for more things than using it manually eventually? (as a testing sdk for example)
Problem
I've got a Kotlin project that will be dealing with the webhooks calls made by Stripe.
I'd like to have some integration tests. While it's easy to do that manually by launching Stripe CLI and listen for events + mock some events, I'd like to have that automated.
Feature
I don't believe such thing is possible from the Java SDK and all the fixtures seems to be in stripe-cli project (which is legit ofc).
But I wonder what's my best option to achieve this:
Maybe there's already a proper way of doing that and I missed it? But I think this CLI is really handy and the logic behind it could be used for more things than using it manually eventually? (as a testing sdk for example)