rest_baby 0.2 → 0.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.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/ChangeLog +6 -1
  3. data/Gemfile +3 -1
  4. data/cucumber.yml +1 -1
  5. data/doc/MockRestService.html +5 -13
  6. data/doc/RestBaby/Client.html +13 -13
  7. data/doc/RestBaby.html +1 -1
  8. data/doc/_index.html +4 -45
  9. data/doc/class_list.html +1 -1
  10. data/doc/css/style.css +1 -1
  11. data/doc/feature_list.html +39 -39
  12. data/doc/file.README.html +5 -5
  13. data/doc/frames.html +5 -7
  14. data/doc/index.html +5 -5
  15. data/doc/js/app.js +7 -2
  16. data/doc/method_list.html +20 -26
  17. data/doc/requirements/features/headers/header_options.html +45 -33
  18. data/doc/requirements/features/headers.html +5 -4
  19. data/doc/requirements/features/print_response.html +26 -138
  20. data/doc/requirements/features/rest_client.html +23 -23
  21. data/doc/requirements/features.html +9 -8
  22. data/doc/requirements/step_transformers.html +206 -222
  23. data/doc/requirements/tags/authentication.html +3 -3
  24. data/doc/requirements/tags/core.html +3 -3
  25. data/doc/requirements/tags/delete.html +3 -3
  26. data/doc/requirements/tags/extended.html +3 -3
  27. data/doc/requirements/tags/get.html +3 -3
  28. data/doc/requirements/tags/headers.html +3 -3
  29. data/doc/requirements/tags/post.html +3 -3
  30. data/doc/requirements/tags/print.html +3 -3
  31. data/doc/requirements/tags/put.html +3 -3
  32. data/doc/requirements/tags/wip.html +187 -0
  33. data/doc/requirements/tags.html +40 -39
  34. data/doc/requirements.html +10 -9
  35. data/doc/step_list.html +166 -210
  36. data/doc/stepdefinition_list.html +36 -36
  37. data/doc/tag_list.html +12 -6
  38. data/doc/top-level-namespace.html +5 -14
  39. data/features/headers/header_options.feature +9 -9
  40. data/features/print_response.feature +0 -25
  41. data/features/step_definitions/header_steps.rb +8 -3
  42. data/features/step_definitions/rest_client_steps.rb +1 -6
  43. data/features/support/env.rb +0 -1
  44. data/features/support/mock_rest_service.rb +1 -5
  45. data/lib/rest_baby/version.rb +1 -1
  46. data/lib/rest_baby.rb +143 -88
  47. data/rest_baby.gemspec +2 -2
  48. metadata +28 -30
  49. data/doc/PinchRestService.html +0 -349
  50. data/features/support/pinch_rest_service.rb +0 -21
@@ -1,349 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
- <title>
7
- Class: PinchRestService
8
-
9
- &mdash; Documentation by YARD 0.8.7
10
-
11
- </title>
12
-
13
- <link rel="stylesheet" href="css/style.css" type="text/css" charset="utf-8" />
14
-
15
- <link rel="stylesheet" href="css/common.css" type="text/css" charset="utf-8" />
16
-
17
- <link rel="stylesheet" href="css/cucumber.css" type="text/css" charset="utf-8" />
18
-
19
- <script type="text/javascript" charset="utf-8">
20
- hasFrames = window.top.frames.main ? true : false;
21
- relpath = '';
22
- framesUrl = "frames.html#!" + escape(window.location.href);
23
- </script>
24
-
25
-
26
- <script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
27
-
28
- <script type="text/javascript" charset="utf-8" src="js/app.js"></script>
29
-
30
- <script type="text/javascript" charset="utf-8" src="js/cucumber.js"></script>
31
-
32
-
33
- </head>
34
- <body>
35
- <div id="header">
36
- <div id="menu">
37
-
38
- <a href="_index.html">Index (P)</a> &raquo;
39
-
40
-
41
- <span class="title">PinchRestService</span>
42
-
43
-
44
- <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
45
- </div>
46
-
47
- <div id="search">
48
-
49
- <a class="full_list_link" id="feature_list_link"
50
- href="feature_list.html">
51
- Features
52
- </a>
53
-
54
- <a class="full_list_link" id="featuredirectories_list_link"
55
- href="featuredirectories_list.html">
56
- Features by Directory
57
- </a>
58
-
59
- <a class="full_list_link" id="tag_list_link"
60
- href="tag_list.html">
61
- Tags
62
- </a>
63
-
64
- <a class="full_list_link" id="step_list_link"
65
- href="step_list.html">
66
- Steps
67
- </a>
68
-
69
- <a class="full_list_link" id="stepdefinition_list_link"
70
- href="stepdefinition_list.html">
71
- Step Defs
72
- </a>
73
-
74
- <a class="full_list_link" id="class_list_link"
75
- href="class_list.html">
76
- Class List
77
- </a>
78
-
79
- <a class="full_list_link" id="method_list_link"
80
- href="method_list.html">
81
- Method List
82
- </a>
83
-
84
- <a class="full_list_link" id="file_list_link"
85
- href="file_list.html">
86
- File List
87
- </a>
88
-
89
- </div>
90
- <div class="clear"></div>
91
- </div>
92
-
93
- <iframe id="search_frame"></iframe>
94
-
95
- <div id="content"><h1>Class: PinchRestService
96
-
97
-
98
-
99
- </h1>
100
-
101
- <dl class="box">
102
-
103
- <dt class="r1">Inherits:</dt>
104
- <dd class="r1">
105
- <span class="inheritName">Object</span>
106
-
107
- <ul class="fullTree">
108
- <li>Object</li>
109
-
110
- <li class="next">PinchRestService</li>
111
-
112
- </ul>
113
- <a href="#" class="inheritanceTree">show all</a>
114
-
115
- </dd>
116
-
117
-
118
-
119
-
120
-
121
-
122
-
123
-
124
-
125
- <dt class="r2 last">Defined in:</dt>
126
- <dd class="r2 last">features/support/pinch_rest_service.rb</dd>
127
-
128
- </dl>
129
- <div class="clear"></div>
130
-
131
-
132
-
133
-
134
-
135
-
136
-
137
-
138
-
139
- <h2>
140
- Instance Method Summary
141
- <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
142
- </h2>
143
-
144
- <ul class="summary">
145
-
146
- <li class="public ">
147
- <span class="summary_signature">
148
-
149
- <a href="#close-instance_method" title="#close (instance method)">- (Object) <strong>close</strong> </a>
150
-
151
-
152
-
153
- </span>
154
-
155
-
156
-
157
-
158
-
159
-
160
-
161
-
162
-
163
- <span class="summary_desc"><div class='inline'></div></span>
164
-
165
- </li>
166
-
167
-
168
- <li class="public ">
169
- <span class="summary_signature">
170
-
171
- <a href="#initialize-instance_method" title="#initialize (instance method)">- (PinchRestService) <strong>initialize</strong>(host, port) </a>
172
-
173
-
174
-
175
- </span>
176
-
177
-
178
- <span class="note title constructor">constructor</span>
179
-
180
-
181
-
182
-
183
-
184
-
185
-
186
-
187
- <span class="summary_desc"><div class='inline'>
188
- <p>A new instance of PinchRestService.</p>
189
- </div></span>
190
-
191
- </li>
192
-
193
-
194
- <li class="public ">
195
- <span class="summary_signature">
196
-
197
- <a href="#store_msg-instance_method" title="#store_msg (instance method)">- (Object) <strong>store_msg</strong>(path, message) </a>
198
-
199
-
200
-
201
- </span>
202
-
203
-
204
-
205
-
206
-
207
-
208
-
209
-
210
-
211
- <span class="summary_desc"><div class='inline'></div></span>
212
-
213
- </li>
214
-
215
-
216
- </ul>
217
-
218
-
219
- <div id="constructor_details" class="method_details_list">
220
- <h2>Constructor Details</h2>
221
-
222
- <div class="method_details first">
223
- <h3 class="signature first" id="initialize-instance_method">
224
-
225
- - (<tt><span class='object_link'><a href="" title="PinchRestService (class)">PinchRestService</a></span></tt>) <strong>initialize</strong>(host, port)
226
-
227
-
228
-
229
-
230
-
231
- </h3><div class="docstring">
232
- <div class="discussion">
233
-
234
- <p>Returns a new instance of PinchRestService</p>
235
-
236
-
237
- </div>
238
- </div>
239
- <div class="tags">
240
-
241
-
242
- </div><table class="source_code">
243
- <tr>
244
- <td>
245
- <pre class="lines">
246
-
247
-
248
- 5
249
- 6
250
- 7
251
- 8
252
- 9
253
- 10
254
- 11</pre>
255
- </td>
256
- <td>
257
- <pre class="code"><span class="info file"># File 'features/support/pinch_rest_service.rb', line 5</span>
258
-
259
- <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_host'>host</span><span class='comma'>,</span> <span class='id identifier rubyid_port'>port</span><span class='rparen'>)</span>
260
- <span class='ivar'>@host</span> <span class='op'>=</span> <span class='id identifier rubyid_host'>host</span>
261
- <span class='ivar'>@port</span> <span class='op'>=</span> <span class='id identifier rubyid_port'>port</span>
262
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_start_service'>start_service</span> <span class='ivar'>@host</span><span class='comma'>,</span> <span class='ivar'>@port</span>
263
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_connect'>connect</span> <span class='ivar'>@host</span><span class='comma'>,</span> <span class='ivar'>@port</span>
264
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_messages_directory'>messages_directory</span> <span class='op'>=</span> <span class='const'>File</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='const'>File</span><span class='period'>.</span><span class='id identifier rubyid_dirname'>dirname</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>.</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>..</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>..</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>features</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>messages</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span>
265
- <span class='kw'>end</span></pre>
266
- </td>
267
- </tr>
268
- </table>
269
- </div>
270
-
271
- </div>
272
-
273
-
274
- <div id="instance_method_details" class="method_details_list">
275
- <h2>Instance Method Details</h2>
276
-
277
-
278
- <div class="method_details first">
279
- <h3 class="signature first" id="close-instance_method">
280
-
281
- - (<tt>Object</tt>) <strong>close</strong>
282
-
283
-
284
-
285
-
286
-
287
- </h3><table class="source_code">
288
- <tr>
289
- <td>
290
- <pre class="lines">
291
-
292
-
293
- 17
294
- 18
295
- 19</pre>
296
- </td>
297
- <td>
298
- <pre class="code"><span class="info file"># File 'features/support/pinch_rest_service.rb', line 17</span>
299
-
300
- <span class='kw'>def</span> <span class='id identifier rubyid_close'>close</span>
301
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_stop_service'>stop_service</span>
302
- <span class='kw'>end</span></pre>
303
- </td>
304
- </tr>
305
- </table>
306
- </div>
307
-
308
- <div class="method_details ">
309
- <h3 class="signature " id="store_msg-instance_method">
310
-
311
- - (<tt>Object</tt>) <strong>store_msg</strong>(path, message)
312
-
313
-
314
-
315
-
316
-
317
- </h3><table class="source_code">
318
- <tr>
319
- <td>
320
- <pre class="lines">
321
-
322
-
323
- 13
324
- 14
325
- 15</pre>
326
- </td>
327
- <td>
328
- <pre class="code"><span class="info file"># File 'features/support/pinch_rest_service.rb', line 13</span>
329
-
330
- <span class='kw'>def</span> <span class='id identifier rubyid_store_msg'>store_msg</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='id identifier rubyid_message'>message</span><span class='rparen'>)</span>
331
- <span class='id identifier rubyid_store'>store</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='id identifier rubyid_message'>message</span>
332
- <span class='kw'>end</span></pre>
333
- </td>
334
- </tr>
335
- </table>
336
- </div>
337
-
338
- </div>
339
-
340
- </div>
341
-
342
- <div id="footer">
343
- Generated on Tue Aug 6 23:42:42 2013 by
344
- <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
345
- 0.8.7 (ruby-2.0.0).
346
- </div>
347
-
348
- </body>
349
- </html>
@@ -1,21 +0,0 @@
1
- include PinchHitter
2
-
3
- class PinchRestService
4
-
5
- def initialize(host, port)
6
- @host = host
7
- @port = port
8
- self.start_service @host, @port
9
- self.connect @host, @port
10
- self.messages_directory = File.join(File.dirname('.'), "..", "..", 'features', 'messages')
11
- end
12
-
13
- def store_msg(path, message)
14
- store path, message
15
- end
16
-
17
- def close
18
- self.stop_service
19
- end
20
-
21
- end