adrienverge / localstripe

A fake but stateful Stripe server that you can run locally, for testing purposes.
GNU General Public License v3.0
192 stars 59 forks source link

Add payment_method to customer creation endpoint #183

Closed meshy closed 3 years ago

meshy commented 3 years ago

Stripe's customer creation endpoint accepts a payment_method parameter. This adds the parameter to the localstripe mock.

Ref: https://stripe.com/docs/api/customers/create#create_customer-payment_method

meshy commented 3 years ago

I wasn't sure if delegating to PaymentMethod._api_attach was the optimal approach. Please let me know if there's anything I can do to improve this!

meshy commented 3 years ago

Hi @meshy! Thanks for this contribution :+1: Just a few comments but it looks good to me.

It's a pleasure -- thanks for this great project!

Comments addressed!

bravier commented 3 years ago

Nice! Can you squash the commits into one?

meshy commented 3 years ago

Can you squash the commits into one?

Done!

meshy commented 3 years ago

Thanks for the quick turn-around on reviews! :slightly_smiling_face: