sucker 1.0.0.beta.4 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (71) hide show
  1. data/CHANGELOG.md +12 -2
  2. data/README.md +5 -2
  3. data/lib/sucker.rbc +341 -0
  4. data/lib/sucker/request.rb +1 -1
  5. data/lib/sucker/request.rbc +2481 -0
  6. data/lib/sucker/response.rb +19 -7
  7. data/lib/sucker/response.rbc +1554 -0
  8. data/lib/sucker/version.rb +2 -2
  9. data/lib/sucker/version.rbc +130 -0
  10. data/spec/fixtures/asins.txt +9406 -406
  11. data/spec/fixtures/cassette_library/integration/alternate_versions.yml +27 -0
  12. data/spec/fixtures/cassette_library/integration/errors.yml +27 -0
  13. data/spec/fixtures/cassette_library/integration/france.yml +27 -0
  14. data/spec/fixtures/cassette_library/integration/images.yml +27 -0
  15. data/spec/fixtures/cassette_library/integration/item_lookup/multiple.yml +27 -0
  16. data/spec/fixtures/cassette_library/integration/item_lookup/single.yml +27 -0
  17. data/spec/fixtures/cassette_library/integration/item_search.yml +27 -0
  18. data/spec/fixtures/cassette_library/integration/japan.yml +27 -0
  19. data/spec/fixtures/cassette_library/integration/keyword_search.yml +27 -0
  20. data/spec/fixtures/cassette_library/integration/kindle.yml +27 -0
  21. data/spec/fixtures/cassette_library/integration/kindle_2.yml +27 -0
  22. data/spec/fixtures/cassette_library/integration/multiple_locales.yml +157 -0
  23. data/spec/fixtures/cassette_library/integration/power_search.yml +27 -0
  24. data/spec/fixtures/cassette_library/integration/related_items/child.yml +27 -0
  25. data/spec/fixtures/cassette_library/integration/related_items/parent.yml +27 -0
  26. data/spec/fixtures/cassette_library/integration/seller_listings_search.yml +27 -0
  27. data/spec/fixtures/cassette_library/integration/twenty_items.yml +27 -0
  28. data/spec/fixtures/cassette_library/unit/sucker/request.yml +29 -0
  29. data/spec/fixtures/cassette_library/unit/sucker/response.yml +27 -0
  30. data/spec/integration/alternate_versions_spec.rb +28 -20
  31. data/spec/integration/alternate_versions_spec.rbc +843 -0
  32. data/spec/integration/errors_spec.rb +10 -6
  33. data/spec/integration/errors_spec.rbc +964 -0
  34. data/spec/integration/france_spec.rb +33 -25
  35. data/spec/integration/france_spec.rbc +1012 -0
  36. data/spec/integration/images_spec.rb +32 -24
  37. data/spec/integration/images_spec.rbc +1047 -0
  38. data/spec/integration/item_lookup_spec.rb +11 -3
  39. data/spec/integration/item_lookup_spec.rbc +1723 -0
  40. data/spec/integration/item_search_spec.rb +6 -2
  41. data/spec/integration/item_search_spec.rbc +926 -0
  42. data/spec/integration/japan_spec.rb +27 -19
  43. data/spec/integration/japan_spec.rbc +849 -0
  44. data/spec/integration/keyword_search_spec.rb +5 -0
  45. data/spec/integration/keyword_search_spec.rbc +838 -0
  46. data/spec/integration/kindle_spec.rb +13 -5
  47. data/spec/integration/kindle_spec.rbc +1425 -0
  48. data/spec/integration/multiple_locales_spec.rb +34 -26
  49. data/spec/integration/multiple_locales_spec.rbc +1090 -0
  50. data/spec/integration/power_search_spec.rb +5 -0
  51. data/spec/integration/power_search_spec.rbc +838 -0
  52. data/spec/integration/related_items_spec.rb +41 -29
  53. data/spec/integration/related_items_spec.rbc +1228 -0
  54. data/spec/integration/seller_listing_search_spec.rb +3 -0
  55. data/spec/integration/seller_listing_search_spec.rbc +852 -0
  56. data/spec/integration/twenty_items_spec.rb +41 -34
  57. data/spec/integration/twenty_items_spec.rbc +1166 -0
  58. data/spec/spec_helper.rbc +231 -0
  59. data/spec/support/amazon.yml +3 -0
  60. data/spec/support/amazon.yml.example +1 -0
  61. data/spec/support/amazon_credentials.rbc +154 -0
  62. data/spec/support/asins.rb +6 -1
  63. data/spec/support/asins.rbc +335 -0
  64. data/spec/support/vcr.rbc +360 -0
  65. data/spec/unit/sucker/request_spec.rb +57 -23
  66. data/spec/unit/sucker/request_spec.rbc +4031 -0
  67. data/spec/unit/sucker/response_spec.rb +100 -26
  68. data/spec/unit/sucker/response_spec.rbc +3787 -0
  69. data/spec/unit/sucker_spec.rb +5 -1
  70. data/spec/unit/sucker_spec.rbc +299 -0
  71. metadata +94 -12
@@ -1,9 +1,13 @@
1
1
  require "spec_helper"
2
2
 
3
3
  describe Sucker do
4
- context ".new" do
4
+
5
+ describe ".new" do
6
+
5
7
  it "returns a Request object" do
6
8
  Sucker.new.should be_an_instance_of Sucker::Request
7
9
  end
10
+
8
11
  end
12
+
9
13
  end
@@ -0,0 +1,299 @@
1
+ !RBIX
2
+ 0
3
+ x
4
+ M
5
+ 1
6
+ n
7
+ n
8
+ x
9
+ 10
10
+ __script__
11
+ i
12
+ 22
13
+ 5
14
+ 7
15
+ 0
16
+ 64
17
+ 47
18
+ 49
19
+ 1
20
+ 1
21
+ 15
22
+ 5
23
+ 45
24
+ 2
25
+ 3
26
+ 56
27
+ 4
28
+ 47
29
+ 50
30
+ 5
31
+ 1
32
+ 15
33
+ 2
34
+ 11
35
+ I
36
+ 3
37
+ I
38
+ 0
39
+ I
40
+ 0
41
+ I
42
+ 0
43
+ n
44
+ p
45
+ 6
46
+ s
47
+ 11
48
+ spec_helper
49
+ x
50
+ 7
51
+ require
52
+ x
53
+ 6
54
+ Sucker
55
+ n
56
+ M
57
+ 1
58
+ p
59
+ 2
60
+ x
61
+ 9
62
+ for_block
63
+ t
64
+ n
65
+ x
66
+ 9
67
+ __block__
68
+ i
69
+ 11
70
+ 5
71
+ 7
72
+ 0
73
+ 64
74
+ 56
75
+ 1
76
+ 47
77
+ 50
78
+ 2
79
+ 1
80
+ 11
81
+ I
82
+ 4
83
+ I
84
+ 0
85
+ I
86
+ 0
87
+ I
88
+ 0
89
+ I
90
+ -2
91
+ p
92
+ 3
93
+ s
94
+ 4
95
+ .new
96
+ M
97
+ 1
98
+ p
99
+ 2
100
+ x
101
+ 9
102
+ for_block
103
+ t
104
+ n
105
+ x
106
+ 9
107
+ __block__
108
+ i
109
+ 11
110
+ 5
111
+ 7
112
+ 0
113
+ 64
114
+ 56
115
+ 1
116
+ 47
117
+ 50
118
+ 2
119
+ 1
120
+ 11
121
+ I
122
+ 4
123
+ I
124
+ 0
125
+ I
126
+ 0
127
+ I
128
+ 0
129
+ I
130
+ -2
131
+ p
132
+ 3
133
+ s
134
+ 24
135
+ returns a Request object
136
+ M
137
+ 1
138
+ p
139
+ 2
140
+ x
141
+ 9
142
+ for_block
143
+ t
144
+ n
145
+ x
146
+ 9
147
+ __block__
148
+ i
149
+ 38
150
+ 45
151
+ 0
152
+ 1
153
+ 13
154
+ 71
155
+ 2
156
+ 47
157
+ 9
158
+ 21
159
+ 47
160
+ 49
161
+ 3
162
+ 0
163
+ 13
164
+ 47
165
+ 49
166
+ 4
167
+ 0
168
+ 15
169
+ 8
170
+ 24
171
+ 49
172
+ 2
173
+ 0
174
+ 5
175
+ 45
176
+ 0
177
+ 5
178
+ 43
179
+ 6
180
+ 47
181
+ 49
182
+ 7
183
+ 1
184
+ 49
185
+ 8
186
+ 1
187
+ 11
188
+ I
189
+ 4
190
+ I
191
+ 0
192
+ I
193
+ 0
194
+ I
195
+ 0
196
+ I
197
+ -2
198
+ p
199
+ 9
200
+ x
201
+ 6
202
+ Sucker
203
+ n
204
+ x
205
+ 3
206
+ new
207
+ x
208
+ 8
209
+ allocate
210
+ x
211
+ 10
212
+ initialize
213
+ n
214
+ x
215
+ 7
216
+ Request
217
+ x
218
+ 17
219
+ be_an_instance_of
220
+ x
221
+ 6
222
+ should
223
+ p
224
+ 5
225
+ I
226
+ 0
227
+ I
228
+ 7
229
+ I
230
+ 0
231
+ I
232
+ 8
233
+ I
234
+ 26
235
+ x
236
+ 47
237
+ /Users/snl/code/sucker/spec/unit/sucker_spec.rb
238
+ p
239
+ 0
240
+ x
241
+ 2
242
+ it
243
+ p
244
+ 5
245
+ I
246
+ 0
247
+ I
248
+ 5
249
+ I
250
+ 0
251
+ I
252
+ 7
253
+ I
254
+ b
255
+ x
256
+ 47
257
+ /Users/snl/code/sucker/spec/unit/sucker_spec.rb
258
+ p
259
+ 0
260
+ x
261
+ 8
262
+ describe
263
+ p
264
+ 5
265
+ I
266
+ 0
267
+ I
268
+ 3
269
+ I
270
+ 0
271
+ I
272
+ 5
273
+ I
274
+ b
275
+ x
276
+ 47
277
+ /Users/snl/code/sucker/spec/unit/sucker_spec.rb
278
+ p
279
+ 0
280
+ x
281
+ 8
282
+ describe
283
+ p
284
+ 5
285
+ I
286
+ 0
287
+ I
288
+ 1
289
+ I
290
+ 9
291
+ I
292
+ 3
293
+ I
294
+ 16
295
+ x
296
+ 47
297
+ /Users/snl/code/sucker/spec/unit/sucker_spec.rb
298
+ p
299
+ 0
metadata CHANGED
@@ -1,15 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sucker
3
3
  version: !ruby/object:Gem::Version
4
- hash: 62196363
5
- prerelease: true
4
+ hash: 23
5
+ prerelease: false
6
6
  segments:
7
7
  - 1
8
8
  - 0
9
9
  - 0
10
- - beta
11
- - 4
12
- version: 1.0.0.beta.4
10
+ version: 1.0.0
13
11
  platform: ruby
14
12
  authors:
15
13
  - Hakan Ensari
@@ -18,7 +16,7 @@ autorequire:
18
16
  bindir: bin
19
17
  cert_chain: []
20
18
 
21
- date: 2010-10-28 00:00:00 +01:00
19
+ date: 2010-11-04 00:00:00 +01:00
22
20
  default_executable:
23
21
  dependencies:
24
22
  - !ruby/object:Gem::Dependency
@@ -192,35 +190,80 @@ extra_rdoc_files: []
192
190
 
193
191
  files:
194
192
  - lib/sucker/request.rb
193
+ - lib/sucker/request.rbc
195
194
  - lib/sucker/response.rb
195
+ - lib/sucker/response.rbc
196
196
  - lib/sucker/version.rb
197
+ - lib/sucker/version.rbc
197
198
  - lib/sucker.rb
199
+ - lib/sucker.rbc
198
200
  - LICENSE
199
201
  - README.md
200
202
  - CHANGELOG.md
201
203
  - spec/fixtures/asins.txt
204
+ - spec/fixtures/cassette_library/integration/alternate_versions.yml
205
+ - spec/fixtures/cassette_library/integration/errors.yml
206
+ - spec/fixtures/cassette_library/integration/france.yml
207
+ - spec/fixtures/cassette_library/integration/images.yml
208
+ - spec/fixtures/cassette_library/integration/item_lookup/multiple.yml
209
+ - spec/fixtures/cassette_library/integration/item_lookup/single.yml
210
+ - spec/fixtures/cassette_library/integration/item_search.yml
211
+ - spec/fixtures/cassette_library/integration/japan.yml
212
+ - spec/fixtures/cassette_library/integration/keyword_search.yml
213
+ - spec/fixtures/cassette_library/integration/kindle.yml
214
+ - spec/fixtures/cassette_library/integration/kindle_2.yml
215
+ - spec/fixtures/cassette_library/integration/multiple_locales.yml
216
+ - spec/fixtures/cassette_library/integration/power_search.yml
217
+ - spec/fixtures/cassette_library/integration/related_items/child.yml
218
+ - spec/fixtures/cassette_library/integration/related_items/parent.yml
219
+ - spec/fixtures/cassette_library/integration/seller_listings_search.yml
220
+ - spec/fixtures/cassette_library/integration/twenty_items.yml
221
+ - spec/fixtures/cassette_library/unit/sucker/request.yml
222
+ - spec/fixtures/cassette_library/unit/sucker/response.yml
202
223
  - spec/integration/alternate_versions_spec.rb
224
+ - spec/integration/alternate_versions_spec.rbc
203
225
  - spec/integration/errors_spec.rb
226
+ - spec/integration/errors_spec.rbc
204
227
  - spec/integration/france_spec.rb
228
+ - spec/integration/france_spec.rbc
205
229
  - spec/integration/images_spec.rb
230
+ - spec/integration/images_spec.rbc
206
231
  - spec/integration/item_lookup_spec.rb
232
+ - spec/integration/item_lookup_spec.rbc
207
233
  - spec/integration/item_search_spec.rb
234
+ - spec/integration/item_search_spec.rbc
208
235
  - spec/integration/japan_spec.rb
236
+ - spec/integration/japan_spec.rbc
209
237
  - spec/integration/keyword_search_spec.rb
238
+ - spec/integration/keyword_search_spec.rbc
210
239
  - spec/integration/kindle_spec.rb
240
+ - spec/integration/kindle_spec.rbc
211
241
  - spec/integration/multiple_locales_spec.rb
242
+ - spec/integration/multiple_locales_spec.rbc
212
243
  - spec/integration/power_search_spec.rb
244
+ - spec/integration/power_search_spec.rbc
213
245
  - spec/integration/related_items_spec.rb
246
+ - spec/integration/related_items_spec.rbc
214
247
  - spec/integration/seller_listing_search_spec.rb
248
+ - spec/integration/seller_listing_search_spec.rbc
215
249
  - spec/integration/twenty_items_spec.rb
250
+ - spec/integration/twenty_items_spec.rbc
216
251
  - spec/spec_helper.rb
252
+ - spec/spec_helper.rbc
253
+ - spec/support/amazon.yml
217
254
  - spec/support/amazon.yml.example
218
255
  - spec/support/amazon_credentials.rb
256
+ - spec/support/amazon_credentials.rbc
219
257
  - spec/support/asins.rb
258
+ - spec/support/asins.rbc
220
259
  - spec/support/vcr.rb
260
+ - spec/support/vcr.rbc
221
261
  - spec/unit/sucker/request_spec.rb
262
+ - spec/unit/sucker/request_spec.rbc
222
263
  - spec/unit/sucker/response_spec.rb
264
+ - spec/unit/sucker/response_spec.rbc
223
265
  - spec/unit/sucker_spec.rb
266
+ - spec/unit/sucker_spec.rbc
224
267
  has_rdoc: true
225
268
  homepage: http://gloss.papercavalier.com/sucker
226
269
  licenses: []
@@ -242,14 +285,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
242
285
  required_rubygems_version: !ruby/object:Gem::Requirement
243
286
  none: false
244
287
  requirements:
245
- - - ">"
288
+ - - ">="
246
289
  - !ruby/object:Gem::Version
247
- hash: 25
290
+ hash: 3
248
291
  segments:
249
- - 1
250
- - 3
251
- - 1
252
- version: 1.3.1
292
+ - 0
293
+ version: "0"
253
294
  requirements: []
254
295
 
255
296
  rubyforge_project: sucker
@@ -259,25 +300,66 @@ specification_version: 3
259
300
  summary: A Ruby wrapper to the Amazon Product Advertising API
260
301
  test_files:
261
302
  - spec/fixtures/asins.txt
303
+ - spec/fixtures/cassette_library/integration/alternate_versions.yml
304
+ - spec/fixtures/cassette_library/integration/errors.yml
305
+ - spec/fixtures/cassette_library/integration/france.yml
306
+ - spec/fixtures/cassette_library/integration/images.yml
307
+ - spec/fixtures/cassette_library/integration/item_lookup/multiple.yml
308
+ - spec/fixtures/cassette_library/integration/item_lookup/single.yml
309
+ - spec/fixtures/cassette_library/integration/item_search.yml
310
+ - spec/fixtures/cassette_library/integration/japan.yml
311
+ - spec/fixtures/cassette_library/integration/keyword_search.yml
312
+ - spec/fixtures/cassette_library/integration/kindle.yml
313
+ - spec/fixtures/cassette_library/integration/kindle_2.yml
314
+ - spec/fixtures/cassette_library/integration/multiple_locales.yml
315
+ - spec/fixtures/cassette_library/integration/power_search.yml
316
+ - spec/fixtures/cassette_library/integration/related_items/child.yml
317
+ - spec/fixtures/cassette_library/integration/related_items/parent.yml
318
+ - spec/fixtures/cassette_library/integration/seller_listings_search.yml
319
+ - spec/fixtures/cassette_library/integration/twenty_items.yml
320
+ - spec/fixtures/cassette_library/unit/sucker/request.yml
321
+ - spec/fixtures/cassette_library/unit/sucker/response.yml
262
322
  - spec/integration/alternate_versions_spec.rb
323
+ - spec/integration/alternate_versions_spec.rbc
263
324
  - spec/integration/errors_spec.rb
325
+ - spec/integration/errors_spec.rbc
264
326
  - spec/integration/france_spec.rb
327
+ - spec/integration/france_spec.rbc
265
328
  - spec/integration/images_spec.rb
329
+ - spec/integration/images_spec.rbc
266
330
  - spec/integration/item_lookup_spec.rb
331
+ - spec/integration/item_lookup_spec.rbc
267
332
  - spec/integration/item_search_spec.rb
333
+ - spec/integration/item_search_spec.rbc
268
334
  - spec/integration/japan_spec.rb
335
+ - spec/integration/japan_spec.rbc
269
336
  - spec/integration/keyword_search_spec.rb
337
+ - spec/integration/keyword_search_spec.rbc
270
338
  - spec/integration/kindle_spec.rb
339
+ - spec/integration/kindle_spec.rbc
271
340
  - spec/integration/multiple_locales_spec.rb
341
+ - spec/integration/multiple_locales_spec.rbc
272
342
  - spec/integration/power_search_spec.rb
343
+ - spec/integration/power_search_spec.rbc
273
344
  - spec/integration/related_items_spec.rb
345
+ - spec/integration/related_items_spec.rbc
274
346
  - spec/integration/seller_listing_search_spec.rb
347
+ - spec/integration/seller_listing_search_spec.rbc
275
348
  - spec/integration/twenty_items_spec.rb
349
+ - spec/integration/twenty_items_spec.rbc
276
350
  - spec/spec_helper.rb
351
+ - spec/spec_helper.rbc
352
+ - spec/support/amazon.yml
277
353
  - spec/support/amazon.yml.example
278
354
  - spec/support/amazon_credentials.rb
355
+ - spec/support/amazon_credentials.rbc
279
356
  - spec/support/asins.rb
357
+ - spec/support/asins.rbc
280
358
  - spec/support/vcr.rb
359
+ - spec/support/vcr.rbc
281
360
  - spec/unit/sucker/request_spec.rb
361
+ - spec/unit/sucker/request_spec.rbc
282
362
  - spec/unit/sucker/response_spec.rb
363
+ - spec/unit/sucker/response_spec.rbc
283
364
  - spec/unit/sucker_spec.rb
365
+ - spec/unit/sucker_spec.rbc