klarna-checkout 1.1.2 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b171d07a02e73e397bdbd37a9d98005e4e820e7f
4
- data.tar.gz: b83100462a3715a474eafcebd762bc8a5b436e33
3
+ metadata.gz: 85f81bcdfc8b0b29935fa8a8c78588e1b6c6da64
4
+ data.tar.gz: 7c17e895833e3549824685a7a95ab7ae14216619
5
5
  SHA512:
6
- metadata.gz: 4302033685d53f8a921597f3bde504b6ce900fc764bd63465d2c15f115a9eba08441c7fe4ca0a684b4b109d14ea1fe989ceb2db902b493377dbc48ac0208a2f8
7
- data.tar.gz: 5e8b8dd0b8869771256bf4961a8e2914a89967b1fb0b84069d0541dd0db5feb98ff90df77c5057ea79e310ddb3daca29069f0f7f567f654f43c99c25e4e0d98b
6
+ metadata.gz: 066f19e7711dda039ae7999b0332e5a59cad1b42d3eb39fd70c90a75b55fafa3e9f2a41dc4e9d6250fdf5cb29308ef88d8c9fb540f97abcd670481ae0d2750aa
7
+ data.tar.gz: 355445fd9799f09b86952da608b25c665b8d9d71109d617f4227989d6d7713ae87181d414da54470fa4a5d2118b21c3aada92833ad4b19d0731a3bbe3d4f4bd7
@@ -32,7 +32,8 @@ module Klarna
32
32
  :locale => @locale,
33
33
  :cart => @cart.as_json,
34
34
  :gui => (@gui && @gui.as_json),
35
- :merchant => @merchant.as_json
35
+ :merchant => @merchant.as_json,
36
+ :shipping_address => (@shipping_address && @shipping_address.as_json)
36
37
  })
37
38
  if id || json[:gui].nil?
38
39
  json.delete(:gui)
@@ -1,5 +1,5 @@
1
1
  module Klarna
2
2
  module Checkout
3
- VERSION = "1.1.2"
3
+ VERSION = "1.1.3"
4
4
  end
5
5
  end
@@ -180,6 +180,14 @@ describe Klarna::Checkout::Order do
180
180
  checkout_uri: 'http://www.example.com/checkout',
181
181
  confirmation_uri: 'http://www.example.com/confirmation_uri',
182
182
  push_uri: 'http://www.example.com/push'
183
+ },
184
+ shipping_address: {
185
+ street_address: 'Example Street 1',
186
+ postal_code: '3045',
187
+ city: 'Drammen',
188
+ country: 'NO',
189
+ email: 'test@example.com',
190
+ phone: '99988777'
183
191
  }
184
192
  end
185
193
 
@@ -238,6 +246,17 @@ describe Klarna::Checkout::Order do
238
246
 
239
247
  it_behaves_like "it's not included when order has ID"
240
248
  end
249
+
250
+ describe "shipping_address" do
251
+ subject { json_hash[:shipping_address] }
252
+
253
+ its([:street_address]) { should eq 'Example Street 1' }
254
+ its([:postal_code]) { should eq '3045' }
255
+ its([:city]) { should eq 'Drammen' }
256
+ its([:country]) { should eq 'NO' }
257
+ its([:email]) { should eq 'test@example.com' }
258
+ its([:phone]) { should eq '99988777' }
259
+ end
241
260
  end
242
261
 
243
262
  describe "#to_json" do
@@ -1,5 +1,5 @@
1
1
  require 'klarna/checkout/version'
2
2
 
3
3
  describe Klarna::Checkout::VERSION do
4
- it { should eq '1.1.2' }
4
+ it { should eq '1.1.3' }
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: klarna-checkout
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Theodor Tonum
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-03-17 00:00:00.000000000 Z
11
+ date: 2014-03-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday