-
Notifications
You must be signed in to change notification settings - Fork 548
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do you have testing stubs? #530
Comments
Hi @ysyyork, Short answer: no. I want to get something tooled around this (and I think it'll happen relatively soon), but we're not shipping any official testing package right now. Longer answer if you're willing to get your hands a bit dirty: the test suite in this repository uses a Committee-based testing stub that's powered by our OpenAPI schema. You could basically vendor in the code found in this file along with the schema, and you'll have a fairly accurate set of testing stubs. I'm going to close this out for now as a dup of #243, but let me know if you have any other questions. |
What’s the answer to this request? Any movement on development? |
@joshm1204 Check out stripe-mock. It's still not as fully-featured of a solution as we'd like to eventually provide (see the README for a detailed list of features and missing features), but it's working as a test solution for a lot of our projects, and it may work for you. |
@brandur-stripe Thanks for linking to stripe-mock. I was just checking it out, too, and have it running locally. As for using it for testing my own projects, is there a recommended way to configure |
@YSavir You can change the base URL used by stripe-ruby: Stripe.api_base = 'http://localhost:12111' |
@ob-stripe awesome, thanks! And thanks for making the stripe gem easy to work with. :) |
@brandur-stripe stripe-mock, looks like a whole server, to avoid excess components it would be nice to have some basic stubs. Is there a way to use stripe-mock without installing a separate server? Is Stripe going to come out with anything like https://github.com/rebelidealist/stripe-ruby-mock? Its more light weight, but the disadvantage of stripe-ruby-mock is that it's not maintained by stripe and it always lagging. stripe-ruby-mock, can run a thin server to persist data, but it's not required to use it. |
Hi @joshm-stripe,
Maybe eventually, but we don't currently have one in the works. One thing we'd need to do for a project like that is make sure we could built it sustainably, as manual maintenance on a like package in seven languages would be a heavy ongoing burden. |
Do you provide testing stubs? Or I have to write by myself?
The text was updated successfully, but these errors were encountered: