chiketto 0.3.0 → 0.3.1

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: a8cb265433f878c1e6fc45a09bcce53bf0d351eb
4
- data.tar.gz: 96565f16f1e8fb81feadfa080b999a1df750d1d5
3
+ metadata.gz: 1b70dd062de74bb8aeaaa5e3eeb047e900ae138d
4
+ data.tar.gz: 7d06835feb2cb0869f896cc4a14e3f51a766aaa4
5
5
  SHA512:
6
- metadata.gz: a39155cbf2e0d066464e95a540a020845d0ae29dd64bea4777d44849729cd0b982aac649025e836a6a5eccbc4601e2716a3c647af80cef01673050c058f109bd
7
- data.tar.gz: d5d4ad738a85eef6767802c251898813abc1800459dc10093b66b875454ffa98798a21ca4097ad44d5f769f3db2ee098abff13af95e496c1e558448456cfb425
6
+ metadata.gz: 5389b9e437c0c44ccf7f2643dd01e90919c0408c16eaceef33ce9736f9bd9fa8b1fd57a9342a255b51c0f2731943dd70f40049e9a1f2f662e62ebdb66a158077
7
+ data.tar.gz: 6019d8aa094986af4ee88f571352e348ae957ed9bacb4d01a764582bde50ea2b0f60f1b4049d8578d5cbe962b4abfcd8ec32305a8adac1b3f019e45b8d9e30cc
@@ -5,12 +5,13 @@ module Chiketto
5
5
  :region,
6
6
  :address_1,
7
7
  :address_2,
8
+ :postal_code,
8
9
  :country_name,
9
10
  :longitude,
10
11
  :latitude
11
12
 
12
13
  def to_s
13
- [@address_1, @address_2, @city, @region, @country].
14
+ [@address_1, @address_2, @city, @region, @postal_code, @country].
14
15
  reject { |p| p.nil? }.join(', ')
15
16
  end
16
17
  end
@@ -1,3 +1,3 @@
1
1
  module Chiketto
2
- VERSION = "0.3.0"
2
+ VERSION = "0.3.1"
3
3
  end
data/test/address_test.rb CHANGED
@@ -7,6 +7,7 @@ class AddressTest < MiniTest::Test
7
7
  'region' => 'CA',
8
8
  'address_1' => '651 Brannan',
9
9
  'address_2' => 'Suite 110',
10
+ 'postal_code' => '12345',
10
11
  'country_name' => 'United States',
11
12
  'latitude' => '42.3618641',
12
13
  'longitude' => '-71.0905626'
@@ -18,17 +19,18 @@ class AddressTest < MiniTest::Test
18
19
  assert_respond_to @address, :region
19
20
  assert_respond_to @address, :address_1
20
21
  assert_respond_to @address, :address_2
22
+ assert_respond_to @address, :postal_code
21
23
  assert_respond_to @address, :country_name
22
24
  assert_respond_to @address, :longitude
23
25
  assert_respond_to @address, :latitude
24
26
  end
25
27
 
26
28
  def test_responds_to_string_method
27
- assert_equal '651 Brannan, Suite 110, San Francisco, CA, US', @address.to_s
29
+ assert_equal '651 Brannan, Suite 110, San Francisco, CA, 12345, US', @address.to_s
28
30
  end
29
31
 
30
32
  def test_does_not_include_blanks_in_string
31
33
  @address.region = nil
32
- assert_equal '651 Brannan, Suite 110, San Francisco, US', @address.to_s
34
+ assert_equal '651 Brannan, Suite 110, San Francisco, 12345, US', @address.to_s
33
35
  end
34
36
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chiketto
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Radford