mattsta / stripe-erlang

Erlang interface to the stripe.com API
27 stars 23 forks source link

Customer pagination support #11

Closed jaredmorrow closed 9 years ago

jaredmorrow commented 9 years ago

The get_all_customers was tested using our helium stripe API key, but didn't want to have that key exposed to the upstream repo, so the listing of all customers was removed from the tests. This is due to the fact that the API key present in the eunit tests point at an account with thousands of customers and it causes timeouts in eunit unless the timeout is set to many minutes.

Testing is currently broken once again I think due to an API change regarding transfers. I've fixed these tests once already, but will leave the current failures as an exercise for the upstream maintainers since I didn't change the code at all.

mattsta commented 9 years ago

Thanks for the new feature! It's now added and stripe-erlang is bumped to 0.8.0 and all tests are passing.

I merged all your commits with no changes, but I did squash/flatten/fixup six of them down to one since there were some write->undo->redo->fix cycles in there.

Thanks for testing on your large production data too. It's always great to have more production-facing test runs instead of only relying on the designed-for-testing test suite tests.

and last, but certainly least, I fixed the latest transfer test breakage too. It was due to this API update:

Transfers in test mode now require sufficient funds in your available test mode balance. This brings the test environment behavior into line with the live environment. To adds funds directly to your available test mode balance (bypassing the pending balance), you can use the special test card number 4000 0000 0000 0077.

(basically, they stopped giving test accounts unlimited test money, so now you have to materialize an imaginary test account balance from their magic funding-with-no-account-holds-or-transfer-delays card.)

jaredmorrow commented 9 years ago

Awesome to hear and sorry I didn't squash myself, I typically do, but must have slipped my mind. Thanks for making a solid library, it certainly saved me a lot of time not having to write one myself.