icecream 0.0.12 → 0.0.13

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: 49d3284c4ec7126ea27315c9fb988eb520b3eea2
4
- data.tar.gz: 3b3418fbaec1abadb22e42cee1b4ccddd04afb48
3
+ metadata.gz: 7c41a810b949595862274851fd9227d389701e47
4
+ data.tar.gz: 850649e15642ca4b892f43f4dd4e9593716b539d
5
5
  SHA512:
6
- metadata.gz: 1325bdda2ddb18ab4dcfa12cbc0abbc22ae674127b04550d4496dbc2b11a71bc6b924e1ad93131e2630fee52b26c077e66116c789681021bd49e77304fd365da
7
- data.tar.gz: 52d8f01795acdadcc07e68e5c2795f5527a7b6aff5277a875cf1e3ecc0a498f931812954500049275ecc94524edc1b86b3baf4d4cbf4a05a85daf2d557007aef
6
+ metadata.gz: 3a32901512cd2bc2d1046168285b3673a016b6abcb78edd609ae2362faaa206c64b905fae7011013048704df585c21b172c6738da3a564c010b202110d8311ba
7
+ data.tar.gz: 42e1b80b43b4641874d30177ee94925587e390e4cc3f2470ff4f9cf9f6cbefa2d0246e8414aeca7a4c6747473f77490c580a704e4b469d7d26d06c41f2383856
data/CHANGES ADDED
@@ -0,0 +1,4 @@
1
+
2
+ ** 0.0.13
3
+ - Adding more tests
4
+ - Adding change log
@@ -1,3 +1,3 @@
1
1
  module IceCream
2
- VERSION = "0.0.12"
2
+ VERSION = "0.0.13"
3
3
  end
@@ -0,0 +1,6 @@
1
+ name = "Açaí-the best flavor-ever"
2
+ calories = 10
3
+ color = nil
4
+ price = 20.5
5
+ extra_description = "Brazilian!"
6
+ resumo = ["acai", 10, :black, 20.5]
@@ -2,3 +2,4 @@ name = "apple"
2
2
  calories = 1500
3
3
  color = :red
4
4
  price = 1.5
5
+ extra_description = "health!"
@@ -2,4 +2,5 @@ name = "chocolate"
2
2
  calories = 150
3
3
  color = :brown
4
4
  price = 15.5
5
+ extra_description = "Super good"
5
6
  resumo = ["chocolate", 150, :brown, 15.5]
@@ -2,3 +2,4 @@ name = "cream"
2
2
  calories = 200
3
3
  color = :yellow
4
4
  price = 17.5
5
+ extra_description = "Cremousssss"
@@ -8,7 +8,7 @@ describe "Icecream" do
8
8
  end
9
9
 
10
10
  it "returns all flavors" do
11
- @fridge.all.should eq [:@apple, :@chocolate, :@cream]
11
+ @fridge.all.should match_array [:@apple, :@chocolate, :@cream, :@acai]
12
12
  end
13
13
 
14
14
  it "has objects for each file in the factory filder" do
@@ -19,6 +19,7 @@ describe "Icecream" do
19
19
  chocolate.color.should eq :brown
20
20
  chocolate.price.should eq 15.5
21
21
  chocolate.calories.should eq 150
22
+ chocolate.extra_description.should eq "Super good"
22
23
  chocolate.resumo.should eq ["chocolate", 150, :brown, 15.5]
23
24
 
24
25
  cream = @fridge.flavor :cream
@@ -26,6 +27,7 @@ describe "Icecream" do
26
27
  cream.name.should eq "cream"
27
28
  cream.color.should eq :yellow
28
29
  cream.price.should eq 17.5
30
+ cream.extra_description.should eq "Cremousssss"
29
31
  cream.calories.should eq 200
30
32
 
31
33
  apple = @fridge.flavor :apple
@@ -33,8 +35,18 @@ describe "Icecream" do
33
35
  apple.name.should eq "apple"
34
36
  apple.color.should eq :red
35
37
  apple.price.should eq 1.5
38
+ apple.extra_description.should eq "health!"
36
39
  apple.calories.should eq 1500
40
+
41
+ apple = @fridge.flavor :acai
42
+ apple.class.should be Acai
43
+ apple.name.should eq "Açaí-the best flavor-ever"
44
+ apple.color.should eq ""
45
+ apple.price.should eq 20.5
46
+ apple.extra_description.should eq "Brazilian!"
47
+ apple.calories.should eq 10
37
48
  end
49
+
38
50
  it "creates a new flavor from an array" do
39
51
  new_flavor = IceCream::IceCream.flavor :Orange, "[name = 'orange', color = :orange, price = 35.5, calories = 3]"
40
52
  new_flavor.class.should be Orange
@@ -43,6 +55,7 @@ describe "Icecream" do
43
55
  new_flavor.price.should eq 35.5
44
56
  new_flavor.calories.should eq 3
45
57
  end
58
+
46
59
  it "merges the objects" do
47
60
  cream = @fridge.flavor :cream
48
61
  complementary_flavor = IceCream::IceCream.flavor :Orange, "[name = 'orange', price = 35.5]"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: icecream
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.12
4
+ version: 0.0.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Camilo Ribeiro
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-13 00:00:00.000000000 Z
11
+ date: 2015-02-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pry
@@ -78,6 +78,7 @@ files:
78
78
  - .rspec
79
79
  - .ruby-version
80
80
  - .travis.yml
81
+ - CHANGES
81
82
  - Gemfile
82
83
  - README.md
83
84
  - Rakefile
@@ -86,6 +87,7 @@ files:
86
87
  - lib/icecream/icecream.rb
87
88
  - lib/icecream/parser.rb
88
89
  - lib/icecream/version.rb
90
+ - spec/flavors/acai.flavor
89
91
  - spec/flavors/apple.flavor
90
92
  - spec/flavors/chocolate.flavor
91
93
  - spec/flavors/cream.flavor
@@ -117,6 +119,7 @@ signing_key:
117
119
  specification_version: 4
118
120
  summary: Simple Factory to the ones who just wanna a factory
119
121
  test_files:
122
+ - spec/flavors/acai.flavor
120
123
  - spec/flavors/apple.flavor
121
124
  - spec/flavors/chocolate.flavor
122
125
  - spec/flavors/cream.flavor