rack-client 0.3.1.pre.c → 0.3.1.pre.d
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/rack/client/adapter/base.rb +0 -1
- data/lib/rack/client/adapter/simple.rb +13 -4
- data/lib/rack/client/version.rb +1 -1
- metadata +80 -108
- data/spec/core/headers_spec.rb +0 -47
- data/spec/core/headers_spec.rbc +0 -1674
- data/spec/core/response_spec.rb +0 -78
- data/spec/core/response_spec.rbc +0 -2244
- data/spec/handler/em_http_spec.rb +0 -7
- data/spec/handler/em_http_spec.rbc +0 -224
- data/spec/handler/excon_spec.rb +0 -7
- data/spec/handler/excon_spec.rbc +0 -224
- data/spec/handler/net_http_spec.rb +0 -11
- data/spec/handler/net_http_spec.rbc +0 -307
- data/spec/handler/typhoeus_spec.rb +0 -11
- data/spec/handler/typhoeus_spec.rbc +0 -307
- data/spec/helpers/async_helper.rb +0 -31
- data/spec/helpers/async_helper.rbc +0 -843
- data/spec/helpers/em_http_helper.rb +0 -24
- data/spec/helpers/em_http_helper.rbc +0 -663
- data/spec/helpers/excon_helper.rb +0 -13
- data/spec/helpers/excon_helper.rbc +0 -461
- data/spec/helpers/handler_helper.rb +0 -68
- data/spec/helpers/handler_helper.rbc +0 -1769
- data/spec/helpers/net_http_helper.rb +0 -26
- data/spec/helpers/net_http_helper.rbc +0 -806
- data/spec/helpers/sync_helper.rb +0 -9
- data/spec/helpers/sync_helper.rbc +0 -311
- data/spec/helpers/typhoeus_helper.rb +0 -32
- data/spec/helpers/typhoeus_helper.rbc +0 -936
- data/spec/middleware/cache_spec.rb +0 -25
- data/spec/middleware/cache_spec.rbc +0 -712
- data/spec/middleware/cookie_jar_spec.rb +0 -19
- data/spec/middleware/cookie_jar_spec.rbc +0 -614
- data/spec/middleware/etag_spec.rb +0 -10
- data/spec/middleware/etag_spec.rbc +0 -438
- data/spec/middleware/follow_redirects_spec.rb +0 -12
- data/spec/middleware/follow_redirects_spec.rbc +0 -402
- data/spec/middleware/lint_spec.rb +0 -10
- data/spec/middleware/lint_spec.rbc +0 -392
- data/spec/shared/handler_api.rb +0 -33
- data/spec/shared/handler_api.rbc +0 -1340
- data/spec/shared/streamed_response_api.rb +0 -14
- data/spec/shared/streamed_response_api.rbc +0 -508
- data/spec/spec_apps/cache.ru +0 -14
- data/spec/spec_apps/cookie.ru +0 -12
- data/spec/spec_apps/delete.ru +0 -10
- data/spec/spec_apps/get.ru +0 -13
- data/spec/spec_apps/head.ru +0 -10
- data/spec/spec_apps/hello_world.ru +0 -1
- data/spec/spec_apps/redirect.ru +0 -13
- data/spec/spec_apps/stream.ru +0 -9
- data/spec/spec_config.ru +0 -10
- data/spec/spec_helper.rb +0 -22
@@ -1,461 +0,0 @@
|
|
1
|
-
!RBIX
|
2
|
-
0
|
3
|
-
x
|
4
|
-
M
|
5
|
-
1
|
6
|
-
n
|
7
|
-
n
|
8
|
-
x
|
9
|
-
10
|
10
|
-
__script__
|
11
|
-
i
|
12
|
-
28
|
13
|
-
99
|
14
|
-
7
|
15
|
-
0
|
16
|
-
65
|
17
|
-
49
|
18
|
-
1
|
19
|
-
2
|
20
|
-
13
|
21
|
-
99
|
22
|
-
12
|
23
|
-
7
|
24
|
-
2
|
25
|
-
12
|
26
|
-
7
|
27
|
-
3
|
28
|
-
12
|
29
|
-
65
|
30
|
-
12
|
31
|
-
49
|
32
|
-
4
|
33
|
-
4
|
34
|
-
15
|
35
|
-
49
|
36
|
-
2
|
37
|
-
0
|
38
|
-
15
|
39
|
-
2
|
40
|
-
11
|
41
|
-
I
|
42
|
-
6
|
43
|
-
I
|
44
|
-
0
|
45
|
-
I
|
46
|
-
0
|
47
|
-
I
|
48
|
-
0
|
49
|
-
n
|
50
|
-
p
|
51
|
-
5
|
52
|
-
x
|
53
|
-
11
|
54
|
-
ExconHelper
|
55
|
-
x
|
56
|
-
11
|
57
|
-
open_module
|
58
|
-
x
|
59
|
-
15
|
60
|
-
__module_init__
|
61
|
-
M
|
62
|
-
1
|
63
|
-
n
|
64
|
-
n
|
65
|
-
x
|
66
|
-
11
|
67
|
-
ExconHelper
|
68
|
-
i
|
69
|
-
28
|
70
|
-
5
|
71
|
-
66
|
72
|
-
99
|
73
|
-
7
|
74
|
-
0
|
75
|
-
65
|
76
|
-
49
|
77
|
-
1
|
78
|
-
2
|
79
|
-
13
|
80
|
-
99
|
81
|
-
12
|
82
|
-
7
|
83
|
-
2
|
84
|
-
12
|
85
|
-
7
|
86
|
-
3
|
87
|
-
12
|
88
|
-
65
|
89
|
-
12
|
90
|
-
49
|
91
|
-
4
|
92
|
-
4
|
93
|
-
15
|
94
|
-
49
|
95
|
-
2
|
96
|
-
0
|
97
|
-
11
|
98
|
-
I
|
99
|
-
6
|
100
|
-
I
|
101
|
-
0
|
102
|
-
I
|
103
|
-
0
|
104
|
-
I
|
105
|
-
0
|
106
|
-
n
|
107
|
-
p
|
108
|
-
5
|
109
|
-
x
|
110
|
-
4
|
111
|
-
Sync
|
112
|
-
x
|
113
|
-
11
|
114
|
-
open_module
|
115
|
-
x
|
116
|
-
15
|
117
|
-
__module_init__
|
118
|
-
M
|
119
|
-
1
|
120
|
-
n
|
121
|
-
n
|
122
|
-
x
|
123
|
-
4
|
124
|
-
Sync
|
125
|
-
i
|
126
|
-
16
|
127
|
-
5
|
128
|
-
66
|
129
|
-
99
|
130
|
-
7
|
131
|
-
0
|
132
|
-
7
|
133
|
-
1
|
134
|
-
65
|
135
|
-
67
|
136
|
-
49
|
137
|
-
2
|
138
|
-
0
|
139
|
-
49
|
140
|
-
3
|
141
|
-
4
|
142
|
-
11
|
143
|
-
I
|
144
|
-
5
|
145
|
-
I
|
146
|
-
0
|
147
|
-
I
|
148
|
-
0
|
149
|
-
I
|
150
|
-
0
|
151
|
-
n
|
152
|
-
p
|
153
|
-
4
|
154
|
-
x
|
155
|
-
13
|
156
|
-
build_subject
|
157
|
-
M
|
158
|
-
1
|
159
|
-
n
|
160
|
-
n
|
161
|
-
x
|
162
|
-
13
|
163
|
-
build_subject
|
164
|
-
i
|
165
|
-
13
|
166
|
-
45
|
167
|
-
0
|
168
|
-
1
|
169
|
-
43
|
170
|
-
2
|
171
|
-
39
|
172
|
-
3
|
173
|
-
56
|
174
|
-
4
|
175
|
-
50
|
176
|
-
5
|
177
|
-
1
|
178
|
-
11
|
179
|
-
I
|
180
|
-
4
|
181
|
-
I
|
182
|
-
1
|
183
|
-
I
|
184
|
-
0
|
185
|
-
I
|
186
|
-
0
|
187
|
-
I
|
188
|
-
0
|
189
|
-
p
|
190
|
-
6
|
191
|
-
x
|
192
|
-
4
|
193
|
-
Rack
|
194
|
-
n
|
195
|
-
x
|
196
|
-
6
|
197
|
-
Client
|
198
|
-
x
|
199
|
-
9
|
200
|
-
@base_url
|
201
|
-
M
|
202
|
-
1
|
203
|
-
p
|
204
|
-
2
|
205
|
-
x
|
206
|
-
9
|
207
|
-
for_block
|
208
|
-
t
|
209
|
-
n
|
210
|
-
x
|
211
|
-
13
|
212
|
-
build_subject
|
213
|
-
i
|
214
|
-
49
|
215
|
-
57
|
216
|
-
19
|
217
|
-
0
|
218
|
-
15
|
219
|
-
21
|
220
|
-
1
|
221
|
-
0
|
222
|
-
56
|
223
|
-
0
|
224
|
-
50
|
225
|
-
1
|
226
|
-
0
|
227
|
-
15
|
228
|
-
20
|
229
|
-
0
|
230
|
-
45
|
231
|
-
2
|
232
|
-
3
|
233
|
-
43
|
234
|
-
4
|
235
|
-
43
|
236
|
-
5
|
237
|
-
43
|
238
|
-
6
|
239
|
-
13
|
240
|
-
71
|
241
|
-
7
|
242
|
-
47
|
243
|
-
9
|
244
|
-
42
|
245
|
-
47
|
246
|
-
49
|
247
|
-
8
|
248
|
-
0
|
249
|
-
13
|
250
|
-
47
|
251
|
-
49
|
252
|
-
9
|
253
|
-
0
|
254
|
-
15
|
255
|
-
8
|
256
|
-
45
|
257
|
-
49
|
258
|
-
7
|
259
|
-
0
|
260
|
-
49
|
261
|
-
10
|
262
|
-
1
|
263
|
-
11
|
264
|
-
I
|
265
|
-
5
|
266
|
-
I
|
267
|
-
1
|
268
|
-
I
|
269
|
-
1
|
270
|
-
I
|
271
|
-
1
|
272
|
-
n
|
273
|
-
p
|
274
|
-
11
|
275
|
-
M
|
276
|
-
1
|
277
|
-
p
|
278
|
-
2
|
279
|
-
x
|
280
|
-
9
|
281
|
-
for_block
|
282
|
-
t
|
283
|
-
n
|
284
|
-
x
|
285
|
-
13
|
286
|
-
build_subject
|
287
|
-
i
|
288
|
-
13
|
289
|
-
57
|
290
|
-
19
|
291
|
-
0
|
292
|
-
15
|
293
|
-
21
|
294
|
-
1
|
295
|
-
0
|
296
|
-
20
|
297
|
-
0
|
298
|
-
49
|
299
|
-
0
|
300
|
-
1
|
301
|
-
11
|
302
|
-
I
|
303
|
-
4
|
304
|
-
I
|
305
|
-
1
|
306
|
-
I
|
307
|
-
1
|
308
|
-
I
|
309
|
-
1
|
310
|
-
n
|
311
|
-
p
|
312
|
-
1
|
313
|
-
x
|
314
|
-
3
|
315
|
-
use
|
316
|
-
p
|
317
|
-
5
|
318
|
-
I
|
319
|
-
0
|
320
|
-
I
|
321
|
-
5
|
322
|
-
I
|
323
|
-
4
|
324
|
-
I
|
325
|
-
6
|
326
|
-
I
|
327
|
-
d
|
328
|
-
x
|
329
|
-
56
|
330
|
-
/Users/ben/code/rack-client/spec/helpers/excon_helper.rb
|
331
|
-
p
|
332
|
-
1
|
333
|
-
x
|
334
|
-
10
|
335
|
-
middleware
|
336
|
-
x
|
337
|
-
4
|
338
|
-
each
|
339
|
-
x
|
340
|
-
4
|
341
|
-
Rack
|
342
|
-
n
|
343
|
-
x
|
344
|
-
6
|
345
|
-
Client
|
346
|
-
x
|
347
|
-
7
|
348
|
-
Handler
|
349
|
-
x
|
350
|
-
5
|
351
|
-
Excon
|
352
|
-
x
|
353
|
-
3
|
354
|
-
new
|
355
|
-
x
|
356
|
-
8
|
357
|
-
allocate
|
358
|
-
x
|
359
|
-
10
|
360
|
-
initialize
|
361
|
-
x
|
362
|
-
3
|
363
|
-
run
|
364
|
-
p
|
365
|
-
7
|
366
|
-
I
|
367
|
-
0
|
368
|
-
I
|
369
|
-
4
|
370
|
-
I
|
371
|
-
4
|
372
|
-
I
|
373
|
-
5
|
374
|
-
I
|
375
|
-
d
|
376
|
-
I
|
377
|
-
9
|
378
|
-
I
|
379
|
-
31
|
380
|
-
x
|
381
|
-
56
|
382
|
-
/Users/ben/code/rack-client/spec/helpers/excon_helper.rb
|
383
|
-
p
|
384
|
-
1
|
385
|
-
x
|
386
|
-
7
|
387
|
-
builder
|
388
|
-
x
|
389
|
-
3
|
390
|
-
new
|
391
|
-
p
|
392
|
-
5
|
393
|
-
I
|
394
|
-
0
|
395
|
-
I
|
396
|
-
3
|
397
|
-
I
|
398
|
-
0
|
399
|
-
I
|
400
|
-
4
|
401
|
-
I
|
402
|
-
d
|
403
|
-
x
|
404
|
-
56
|
405
|
-
/Users/ben/code/rack-client/spec/helpers/excon_helper.rb
|
406
|
-
p
|
407
|
-
1
|
408
|
-
x
|
409
|
-
11
|
410
|
-
middlewares
|
411
|
-
x
|
412
|
-
17
|
413
|
-
method_visibility
|
414
|
-
x
|
415
|
-
15
|
416
|
-
add_defn_method
|
417
|
-
p
|
418
|
-
3
|
419
|
-
I
|
420
|
-
2
|
421
|
-
I
|
422
|
-
3
|
423
|
-
I
|
424
|
-
10
|
425
|
-
x
|
426
|
-
56
|
427
|
-
/Users/ben/code/rack-client/spec/helpers/excon_helper.rb
|
428
|
-
p
|
429
|
-
0
|
430
|
-
x
|
431
|
-
13
|
432
|
-
attach_method
|
433
|
-
p
|
434
|
-
3
|
435
|
-
I
|
436
|
-
2
|
437
|
-
I
|
438
|
-
2
|
439
|
-
I
|
440
|
-
1c
|
441
|
-
x
|
442
|
-
56
|
443
|
-
/Users/ben/code/rack-client/spec/helpers/excon_helper.rb
|
444
|
-
p
|
445
|
-
0
|
446
|
-
x
|
447
|
-
13
|
448
|
-
attach_method
|
449
|
-
p
|
450
|
-
3
|
451
|
-
I
|
452
|
-
0
|
453
|
-
I
|
454
|
-
1
|
455
|
-
I
|
456
|
-
1c
|
457
|
-
x
|
458
|
-
56
|
459
|
-
/Users/ben/code/rack-client/spec/helpers/excon_helper.rb
|
460
|
-
p
|
461
|
-
0
|
@@ -1,68 +0,0 @@
|
|
1
|
-
module HandlerHelper
|
2
|
-
module Ext
|
3
|
-
|
4
|
-
def async_handler_map
|
5
|
-
{
|
6
|
-
Rack::Client::Handler::EmHttp => EmHttpHelper::Async,
|
7
|
-
Rack::Client::Handler::NetHTTP => NetHTTPHelper::Async,
|
8
|
-
Rack::Client::Handler::Typhoeus => TyphoeusHelper::Async,
|
9
|
-
}
|
10
|
-
end
|
11
|
-
|
12
|
-
def sync_handler_map
|
13
|
-
{
|
14
|
-
Rack::Client::Handler::NetHTTP => NetHTTPHelper::Sync,
|
15
|
-
Rack::Client::Handler::Typhoeus => TyphoeusHelper::Sync,
|
16
|
-
Rack::Client::Handler::Excon => ExconHelper::Sync
|
17
|
-
}
|
18
|
-
end
|
19
|
-
|
20
|
-
def async_handler_context(handler, *middlewares, &block)
|
21
|
-
context "#{handler.name} Asynchronous" do
|
22
|
-
include AsyncHelper
|
23
|
-
include async_handler_map[handler]
|
24
|
-
|
25
|
-
|
26
|
-
subject { build_subject(*middlewares) }
|
27
|
-
|
28
|
-
around do |group|
|
29
|
-
run_around(group) if respond_to?(:run_around)
|
30
|
-
end
|
31
|
-
|
32
|
-
instance_eval(&block)
|
33
|
-
end
|
34
|
-
end
|
35
|
-
|
36
|
-
def sync_handler_context(handler, *middlewares, &block)
|
37
|
-
context "#{handler.name} Synchronous" do
|
38
|
-
include SyncHelper
|
39
|
-
include sync_handler_map[handler]
|
40
|
-
|
41
|
-
subject { build_subject(*middlewares) }
|
42
|
-
|
43
|
-
instance_eval(&block)
|
44
|
-
end
|
45
|
-
end
|
46
|
-
|
47
|
-
def handler_contexts(*middlewares, &block)
|
48
|
-
async_handler_contexts(*middlewares, &block)
|
49
|
-
sync_handler_contexts(*middlewares, &block)
|
50
|
-
end
|
51
|
-
|
52
|
-
def async_handler_contexts(*middlewares, &block)
|
53
|
-
async_handler_map.keys.each do |handler|
|
54
|
-
async_handler_context(handler, *middlewares, &block)
|
55
|
-
end
|
56
|
-
end
|
57
|
-
|
58
|
-
def sync_handler_contexts(*middlewares, &block)
|
59
|
-
sync_handler_map.keys.each do |handler|
|
60
|
-
sync_handler_context(handler, *middlewares, &block)
|
61
|
-
end
|
62
|
-
end
|
63
|
-
end
|
64
|
-
|
65
|
-
def self.included(context)
|
66
|
-
context.extend Ext
|
67
|
-
end
|
68
|
-
end
|