zunnit 0.4.2 → 0.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/zunnit/version.rb +1 -1
- data/spec/zunnit_spec.rb +7 -3
- metadata +2 -2
data/lib/zunnit/version.rb
CHANGED
data/spec/zunnit_spec.rb
CHANGED
@@ -83,7 +83,10 @@ describe Zunnit do
|
|
83
83
|
it "should return recommendation product for item" do
|
84
84
|
intercept_request_to :get,
|
85
85
|
:action => :recommendation_products_for_item,
|
86
|
-
:params => {
|
86
|
+
:params => {
|
87
|
+
:item_id => "2121",
|
88
|
+
:category => "estilo-de-vida"
|
89
|
+
},
|
87
90
|
:response => {
|
88
91
|
:status => 200,
|
89
92
|
:body => {
|
@@ -102,7 +105,8 @@ describe Zunnit do
|
|
102
105
|
}
|
103
106
|
|
104
107
|
response = Zunnit.api.get :recommendation_products_for_item,
|
105
|
-
:item_id => "2121"
|
108
|
+
:item_id => "2121",
|
109
|
+
:category => "estilo-de-vida"
|
106
110
|
|
107
111
|
validate_response(response, :products)
|
108
112
|
end
|
@@ -156,7 +160,7 @@ describe Zunnit do
|
|
156
160
|
params = options.delete(:params)
|
157
161
|
params = params.merge :api_key => Zunnit.key
|
158
162
|
response = options.delete(:response)
|
159
|
-
uri = URI.parse(Zunnit.url).merge(Zunnit.actions[action])
|
163
|
+
uri = URI.parse(Zunnit.api.url).merge(Zunnit.actions[action])
|
160
164
|
uri.query = params.map {|k,v| "#{k}=#{v}" }.join("&") unless method.to_s =~ /post|put/
|
161
165
|
FakeWeb.register_uri(method, uri, response)
|
162
166
|
end
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: zunnit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.4.
|
5
|
+
version: 0.4.3
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Marcelo Eden
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2011-
|
13
|
+
date: 2011-11-22 00:00:00 -02:00
|
14
14
|
default_executable:
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|