stripe_local 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -9,9 +9,11 @@ describe StripeLocal::Customer do
9
9
  it "can normalize a customer on create" do
10
10
  Stripe::Customer.should_receive( :create ).and_return stripe_customer
11
11
  stripe_customer.should_receive :update_subscription
12
- StripeLocal::Customer.should_receive( :create ).with( stripe_customer ).and_call_original
13
- StripeLocal::Customer.should_receive( :normalize ).with( stripe_customer ).and_call_original
14
- client.signup( card: "token", plan: "plan" )
12
+ StripeLocal::Customer.should_receive( :create ).and_call_original
13
+ StripeLocal::Customer.should_receive( :normalize ).and_call_original
14
+ client.signup( {card: "token", plan: "plan"} )
15
+
16
+ client.reload.customer.id.should eq "cus_123"
15
17
  end
16
18
 
17
19
  it "refers to StripeLocal mattr_accessor for application level model_class" do
@@ -42,7 +42,7 @@
42
42
  "canceled_at": null,
43
43
  "current_period_end": 1381431124,
44
44
  "current_period_start": 1378839124,
45
- "customer": "",
45
+ "customer": "cus_123",
46
46
  "ended_at": null,
47
47
  "id": "su_102Y2J1Cmf55uWiekSeb7fb0",
48
48
  "object": "subscription",
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stripe_local
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andy Cohen