rest_baby 0.8 → 1.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.
- checksums.yaml +4 -4
- data/.rubocop.yml +0 -1
- data/ChangeLog +12 -2
- data/Gemfile +2 -0
- data/Rakefile +7 -1
- data/doc/MockRestService.html +204 -31
- data/doc/RestBaby/Client.html +686 -246
- data/doc/RestBaby.html +6 -7
- data/doc/_index.html +6 -19
- data/doc/class_list.html +6 -2
- data/doc/css/style.css +2 -1
- data/doc/feature_list.html +82 -55
- data/doc/featuredirectories_list.html +25 -32
- data/doc/file.README.html +6 -6
- data/doc/file_list.html +5 -1
- data/doc/frames.html +5 -7
- data/doc/index.html +6 -6
- data/doc/js/app.js +7 -2
- data/doc/js/full_list.js +4 -1
- data/doc/method_list.html +41 -25
- data/doc/requirements/features/header_options.html +81 -45
- data/doc/requirements/features/print_response.html +42 -148
- data/doc/requirements/features/rest_client.html +38 -30
- data/doc/requirements/features/url_parameter.html +342 -0
- data/doc/requirements/features.html +42 -39
- data/doc/requirements/step_transformers.html +524 -321
- data/doc/requirements/tags/authentication.html +8 -8
- data/doc/requirements/tags/core.html +4 -4
- data/doc/requirements/tags/delete.html +4 -4
- data/doc/requirements/tags/extended.html +12 -12
- data/doc/requirements/tags/get.html +6 -6
- data/doc/requirements/tags/header.S1.html +160 -0
- data/doc/requirements/tags/header.S2.html +160 -0
- data/doc/requirements/tags/header.S3.html +160 -0
- data/doc/requirements/tags/header.S4.html +160 -0
- data/doc/requirements/tags/header.html +160 -0
- data/doc/requirements/tags/headers.html +7 -16
- data/doc/requirements/tags/parameter.S1.html +160 -0
- data/doc/requirements/tags/parameter.html +160 -0
- data/doc/requirements/tags/post.html +10 -10
- data/doc/requirements/tags/print.S1.html +160 -0
- data/doc/requirements/tags/print.S2.html +160 -0
- data/doc/requirements/tags/print.S3.html +160 -0
- data/doc/requirements/tags/print.S4.html +160 -0
- data/doc/requirements/tags/print.html +4 -4
- data/doc/requirements/tags/put.html +4 -4
- data/doc/requirements/tags/rest.S1.html +160 -0
- data/doc/requirements/tags/rest.S2.html +160 -0
- data/doc/requirements/tags/rest.S3.html +160 -0
- data/doc/requirements/tags/rest.S4.html +160 -0
- data/doc/requirements/tags.html +97 -57
- data/doc/requirements.html +43 -38
- data/doc/step_list.html +204 -189
- data/doc/stepdefinition_list.html +69 -35
- data/doc/tag_list.html +100 -6
- data/doc/top-level-namespace.html +79 -13
- data/features/step_definitions/rest_client_steps.rb +4 -4
- data/lib/rest_baby/version.rb +1 -1
- data/lib/rest_baby.rb +1 -1
- metadata +46 -31
- data/Gemfile.lock +0 -68
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Step Definitions and Transforms
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7
|
9
|
+
— Documentation by YARD 0.8.7.6
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -19,7 +19,7 @@
|
|
19
19
|
<script type="text/javascript" charset="utf-8">
|
20
20
|
hasFrames = window.top.frames.main ? true : false;
|
21
21
|
relpath = '../';
|
22
|
-
framesUrl = "../frames.html#!"
|
22
|
+
framesUrl = "../frames.html#!requirements/step_transformers.html";
|
23
23
|
</script>
|
24
24
|
|
25
25
|
|
@@ -96,9 +96,9 @@
|
|
96
96
|
<div class="title">Step Definitions & Transforms</div>
|
97
97
|
|
98
98
|
<div class="summary">
|
99
|
-
<div>
|
99
|
+
<div>16<a href="#step_definitions">Step Definitions</a></div>
|
100
100
|
<div>0<a href="#step_transforms">Step Transforms</a></div>
|
101
|
-
<div>
|
101
|
+
<div>4<a href="#undefined_steps">Undefined Steps</a></div>
|
102
102
|
</div>
|
103
103
|
|
104
104
|
</div><div class="title">
|
@@ -118,7 +118,7 @@
|
|
118
118
|
<div class="transformer stepdefinition
|
119
119
|
|
120
120
|
">
|
121
|
-
<a name="
|
121
|
+
<a name="step_definition10-stepdefinition"></a>
|
122
122
|
<div class="title">
|
123
123
|
<span class="pre">Given</span>
|
124
124
|
<span class="name">/^I am a rest client$/</span>
|
@@ -133,7 +133,7 @@
|
|
133
133
|
<div class="details">
|
134
134
|
|
135
135
|
<div class="meta" style="clear: right;">
|
136
|
-
<div class="file">features/step_definitions/rest_client_steps.rb:
|
136
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:41</div>
|
137
137
|
</div>
|
138
138
|
|
139
139
|
<!-- Comments -->
|
@@ -147,13 +147,13 @@
|
|
147
147
|
<table class="source_code">
|
148
148
|
<tr>
|
149
149
|
<td>
|
150
|
-
<pre class="lines">
|
151
|
-
|
152
|
-
|
150
|
+
<pre class="lines">41
|
151
|
+
42
|
152
|
+
43</pre>
|
153
153
|
</td>
|
154
154
|
<td>
|
155
155
|
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I am a rest client$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span>
|
156
|
-
|
156
|
+
<span class='ivar'>@restbaby</span> <span class='op'>=</span> <span class='const'>Client</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='ivar'>@protocol</span><span class='embexpr_end'>}</span><span class='tstring_content'>://</span><span class='embexpr_beg'>#{</span><span class='ivar'>@server</span><span class='embexpr_end'>}</span><span class='tstring_content'>:</span><span class='embexpr_beg'>#{</span><span class='ivar'>@port</span><span class='embexpr_end'>}</span><span class='embexpr_beg'>#{</span><span class='ivar'>@path</span><span class='embexpr_end'>}</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span>
|
157
157
|
<span class='kw'>end</span></pre>
|
158
158
|
</td>
|
159
159
|
</tr>
|
@@ -163,7 +163,7 @@
|
|
163
163
|
<!-- Matching Step Instances -->
|
164
164
|
|
165
165
|
<div class='showSteps'>
|
166
|
-
[<a href='#' class='toggleSteps' alt="
|
166
|
+
[<a href='#' class='toggleSteps' alt="13 steps">Hide 13 steps</a>]
|
167
167
|
</div>
|
168
168
|
|
169
169
|
<div class="steps">
|
@@ -179,29 +179,31 @@
|
|
179
179
|
</span>
|
180
180
|
</div>
|
181
181
|
|
182
|
-
<a class="definition" style="clear: right;" href="features/
|
182
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:8</a>
|
183
183
|
|
184
|
-
<a class="definition" style="clear: right;" href="features/
|
184
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:17</a>
|
185
185
|
|
186
|
-
<a class="definition" style="clear: right;" href="features/
|
186
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:29</a>
|
187
187
|
|
188
|
-
<a class="definition" style="clear: right;" href="features/
|
188
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:41</a>
|
189
189
|
|
190
|
-
<a class="definition" style="clear: right;" href="features/
|
190
|
+
<a class="definition" style="clear: right;" href="features/url_parameter.html">features/url_parameter.feature:8</a>
|
191
191
|
|
192
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
192
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:11</a>
|
193
193
|
|
194
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
194
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:23</a>
|
195
195
|
|
196
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
196
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:38</a>
|
197
197
|
|
198
|
-
<a class="definition" style="clear: right;" href="features/
|
198
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:53</a>
|
199
199
|
|
200
|
-
<a class="definition" style="clear: right;" href="features/
|
200
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:9</a>
|
201
201
|
|
202
|
-
<a class="definition" style="clear: right;" href="features/
|
202
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:24</a>
|
203
203
|
|
204
|
-
<a class="definition" style="clear: right;" href="features/
|
204
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:39</a>
|
205
|
+
|
206
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:49</a>
|
205
207
|
|
206
208
|
<div style="clear: both;"></div>
|
207
209
|
</div>
|
@@ -220,7 +222,7 @@
|
|
220
222
|
<div class="transformer stepdefinition
|
221
223
|
|
222
224
|
">
|
223
|
-
<a name="
|
225
|
+
<a name="step_definition15-stepdefinition"></a>
|
224
226
|
<div class="title">
|
225
227
|
<span class="pre">Then</span>
|
226
228
|
<span class="name">/^I receive the expected message$/</span>
|
@@ -235,7 +237,7 @@
|
|
235
237
|
<div class="details">
|
236
238
|
|
237
239
|
<div class="meta" style="clear: right;">
|
238
|
-
<div class="file">features/step_definitions/rest_client_steps.rb:
|
240
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:73</div>
|
239
241
|
</div>
|
240
242
|
|
241
243
|
<!-- Comments -->
|
@@ -249,15 +251,15 @@
|
|
249
251
|
<table class="source_code">
|
250
252
|
<tr>
|
251
253
|
<td>
|
252
|
-
<pre class="lines">
|
253
|
-
|
254
|
-
|
255
|
-
|
254
|
+
<pre class="lines">73
|
255
|
+
74
|
256
|
+
75
|
257
|
+
76</pre>
|
256
258
|
</td>
|
257
259
|
<td>
|
258
260
|
<pre class="code"><span class='const'>Then</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I receive the expected message$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span>
|
259
|
-
|
260
|
-
|
261
|
+
<span class='id identifier rubyid_expect'>expect</span><span class='lparen'>(</span><span class='ivar'>@response</span><span class='period'>.</span><span class='id identifier rubyid_code'>code</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_to'>to</span> <span class='id identifier rubyid_eq'>eq</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>200</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
|
262
|
+
<span class='id identifier rubyid_expect'>expect</span><span class='lparen'>(</span><span class='ivar'>@response</span><span class='period'>.</span><span class='id identifier rubyid_body'>body</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_to'>to</span> <span class='id identifier rubyid_eq'>eq</span><span class='lparen'>(</span><span class='const'>DEFAULT_MSG</span><span class='rparen'>)</span>
|
261
263
|
<span class='kw'>end</span></pre>
|
262
264
|
</td>
|
263
265
|
</tr>
|
@@ -283,29 +285,29 @@
|
|
283
285
|
</span>
|
284
286
|
</div>
|
285
287
|
|
286
|
-
<a class="definition" style="clear: right;" href="features/
|
288
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:10</a>
|
287
289
|
|
288
|
-
<a class="definition" style="clear: right;" href="features/
|
290
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:22</a>
|
289
291
|
|
290
|
-
<a class="definition" style="clear: right;" href="features/
|
292
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:34</a>
|
291
293
|
|
292
|
-
<a class="definition" style="clear: right;" href="features/
|
294
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:43</a>
|
293
295
|
|
294
296
|
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:13</a>
|
295
297
|
|
296
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
298
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:28</a>
|
297
299
|
|
298
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
300
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:43</a>
|
299
301
|
|
300
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
302
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:55</a>
|
301
303
|
|
302
|
-
<a class="definition" style="clear: right;" href="features/
|
304
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:13</a>
|
303
305
|
|
304
|
-
<a class="definition" style="clear: right;" href="features/
|
306
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:32</a>
|
305
307
|
|
306
|
-
<a class="definition" style="clear: right;" href="features/
|
308
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:42</a>
|
307
309
|
|
308
|
-
<a class="definition" style="clear: right;" href="features/
|
310
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:52</a>
|
309
311
|
|
310
312
|
<div style="clear: both;"></div>
|
311
313
|
</div>
|
@@ -324,7 +326,7 @@
|
|
324
326
|
<div class="transformer stepdefinition
|
325
327
|
|
326
328
|
">
|
327
|
-
<a name="
|
329
|
+
<a name="step_definition7-stepdefinition"></a>
|
328
330
|
<div class="title">
|
329
331
|
<span class="pre">Given</span>
|
330
332
|
<span class="name">/^I have a web service$/</span>
|
@@ -339,7 +341,7 @@
|
|
339
341
|
<div class="details">
|
340
342
|
|
341
343
|
<div class="meta" style="clear: right;">
|
342
|
-
<div class="file">features/step_definitions/rest_client_steps.rb:
|
344
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:4</div>
|
343
345
|
</div>
|
344
346
|
|
345
347
|
<!-- Comments -->
|
@@ -353,18 +355,18 @@
|
|
353
355
|
<table class="source_code">
|
354
356
|
<tr>
|
355
357
|
<td>
|
356
|
-
<pre class="lines">
|
357
|
-
4
|
358
|
+
<pre class="lines">4
|
358
359
|
5
|
359
360
|
6
|
360
361
|
7
|
361
|
-
8
|
362
|
+
8
|
363
|
+
9</pre>
|
362
364
|
</td>
|
363
365
|
<td>
|
364
366
|
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have a web service$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span>
|
365
|
-
|
366
|
-
|
367
|
-
|
367
|
+
<span class='ivar'>@protocol</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>http</span><span class='tstring_end'>'</span></span>
|
368
|
+
<span class='ivar'>@server</span> <span class='op'>=</span> <span class='const'>FigNewton</span><span class='period'>.</span><span class='id identifier rubyid_server'>server</span>
|
369
|
+
<span class='ivar'>@port</span> <span class='op'>=</span> <span class='const'>FigNewton</span><span class='period'>.</span><span class='id identifier rubyid_port'>port</span>
|
368
370
|
<span class='ivar'>@mockservice</span> <span class='op'>=</span> <span class='const'>MockRestService</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@server</span><span class='comma'>,</span> <span class='ivar'>@port</span><span class='comma'>,</span> <span class='ivar'>@protocol</span><span class='rparen'>)</span>
|
369
371
|
<span class='kw'>end</span></pre>
|
370
372
|
</td>
|
@@ -375,7 +377,7 @@
|
|
375
377
|
<!-- Matching Step Instances -->
|
376
378
|
|
377
379
|
<div class='showSteps'>
|
378
|
-
[<a href='#' class='toggleSteps' alt="
|
380
|
+
[<a href='#' class='toggleSteps' alt="12 steps">Hide 12 steps</a>]
|
379
381
|
</div>
|
380
382
|
|
381
383
|
<div class="steps">
|
@@ -391,27 +393,29 @@
|
|
391
393
|
</span>
|
392
394
|
</div>
|
393
395
|
|
394
|
-
<a class="definition" style="clear: right;" href="features/
|
396
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:6</a>
|
395
397
|
|
396
|
-
<a class="definition" style="clear: right;" href="features/
|
398
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:15</a>
|
397
399
|
|
398
|
-
<a class="definition" style="clear: right;" href="features/
|
400
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:27</a>
|
399
401
|
|
400
|
-
<a class="definition" style="clear: right;" href="features/
|
402
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:39</a>
|
401
403
|
|
402
|
-
<a class="definition" style="clear: right;" href="features/
|
404
|
+
<a class="definition" style="clear: right;" href="features/url_parameter.html">features/url_parameter.feature:6</a>
|
403
405
|
|
404
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
406
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:6</a>
|
407
|
+
|
408
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:18</a>
|
405
409
|
|
406
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
410
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:33</a>
|
407
411
|
|
408
|
-
<a class="definition" style="clear: right;" href="features/
|
412
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:48</a>
|
409
413
|
|
410
|
-
<a class="definition" style="clear: right;" href="features/
|
414
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:6</a>
|
411
415
|
|
412
|
-
<a class="definition" style="clear: right;" href="features/
|
416
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:18</a>
|
413
417
|
|
414
|
-
<a class="definition" style="clear: right;" href="features/
|
418
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:37</a>
|
415
419
|
|
416
420
|
<div style="clear: both;"></div>
|
417
421
|
</div>
|
@@ -430,7 +434,7 @@
|
|
430
434
|
<div class="transformer stepdefinition
|
431
435
|
|
432
436
|
">
|
433
|
-
<a name="
|
437
|
+
<a name="step_definition11-stepdefinition"></a>
|
434
438
|
<div class="title">
|
435
439
|
<span class="pre">When</span>
|
436
440
|
<span class="name">/^I "(GET|DELETE)" from the web service$/</span>
|
@@ -445,7 +449,7 @@
|
|
445
449
|
<div class="details">
|
446
450
|
|
447
451
|
<div class="meta" style="clear: right;">
|
448
|
-
<div class="file">features/step_definitions/rest_client_steps.rb:
|
452
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:45</div>
|
449
453
|
</div>
|
450
454
|
|
451
455
|
<!-- Comments -->
|
@@ -459,25 +463,23 @@
|
|
459
463
|
<table class="source_code">
|
460
464
|
<tr>
|
461
465
|
<td>
|
462
|
-
<pre class="lines">
|
463
|
-
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
32</pre>
|
466
|
+
<pre class="lines">45
|
467
|
+
46
|
468
|
+
47
|
469
|
+
48
|
470
|
+
49
|
471
|
+
50
|
472
|
+
51
|
473
|
+
52</pre>
|
471
474
|
</td>
|
472
475
|
<td>
|
473
476
|
<pre class="code"><span class='const'>When</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I "(GET|DELETE)" from the web service$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_type'>type</span><span class='op'>|</span>
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
<span class='kw'>end</span>
|
477
|
+
<span class='kw'>case</span> <span class='id identifier rubyid_type'>type</span><span class='period'>.</span><span class='id identifier rubyid_downcase'>downcase</span>
|
478
|
+
<span class='kw'>when</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>get</span><span class='tstring_end'>'</span></span>
|
479
|
+
<span class='ivar'>@response</span> <span class='op'>=</span> <span class='ivar'>@restbaby</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span>
|
480
|
+
<span class='kw'>when</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>delete</span><span class='tstring_end'>'</span></span>
|
481
|
+
<span class='ivar'>@response</span> <span class='op'>=</span> <span class='ivar'>@restbaby</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span>
|
482
|
+
<span class='kw'>end</span>
|
481
483
|
<span class='kw'>end</span></pre>
|
482
484
|
</td>
|
483
485
|
</tr>
|
@@ -496,22 +498,22 @@
|
|
496
498
|
<div class="step odd">
|
497
499
|
<div>
|
498
500
|
<span class="predicate">
|
499
|
-
|
501
|
+
When
|
500
502
|
</span>
|
501
503
|
<span class="defined">
|
502
504
|
I "<span class='match'>GET</span>" from the web service
|
503
505
|
</span>
|
504
506
|
</div>
|
505
507
|
|
506
|
-
<a class="definition" style="clear: right;" href="features/
|
508
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:9</a>
|
507
509
|
|
508
|
-
<a class="definition" style="clear: right;" href="features/
|
510
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:12</a>
|
509
511
|
|
510
|
-
<a class="definition" style="clear: right;" href="features/
|
512
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:12</a>
|
511
513
|
|
512
|
-
<a class="definition" style="clear: right;" href="features/
|
514
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:41</a>
|
513
515
|
|
514
|
-
<a class="definition" style="clear: right;" href="features/
|
516
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:51</a>
|
515
517
|
|
516
518
|
<div style="clear: both;"></div>
|
517
519
|
</div>
|
@@ -526,9 +528,9 @@
|
|
526
528
|
</span>
|
527
529
|
</div>
|
528
530
|
|
529
|
-
<a class="definition" style="clear: right;" href="features/
|
531
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:42</a>
|
530
532
|
|
531
|
-
<a class="definition" style="clear: right;" href="features/
|
533
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:54</a>
|
532
534
|
|
533
535
|
<div style="clear: both;"></div>
|
534
536
|
</div>
|
@@ -547,12 +549,12 @@
|
|
547
549
|
<div class="transformer stepdefinition
|
548
550
|
|
549
551
|
">
|
550
|
-
<a name="
|
552
|
+
<a name="step_definition12-stepdefinition"></a>
|
551
553
|
<div class="title">
|
552
|
-
<span class="pre">
|
553
|
-
<span class="name">/^I
|
554
|
+
<span class="pre">When</span>
|
555
|
+
<span class="name">/^I "(PUT|POST)" to the web service with the following$/</span>
|
554
556
|
<div style="float: right;">
|
555
|
-
<a href="http://rubular.com/?regex=%2F%5EI
|
557
|
+
<a href="http://rubular.com/?regex=%2F%5EI+%22%28PUT%7CPOST%29%22+to+the+web+service+with+the+following%24%2F" target="_blank">Rubular</a>
|
556
558
|
|
557
559
|
|
558
560
|
</div>
|
@@ -562,7 +564,7 @@
|
|
562
564
|
<div class="details">
|
563
565
|
|
564
566
|
<div class="meta" style="clear: right;">
|
565
|
-
<div class="file">features/step_definitions/rest_client_steps.rb:
|
567
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:54</div>
|
566
568
|
</div>
|
567
569
|
|
568
570
|
<!-- Comments -->
|
@@ -576,15 +578,27 @@
|
|
576
578
|
<table class="source_code">
|
577
579
|
<tr>
|
578
580
|
<td>
|
579
|
-
<pre class="lines">
|
580
|
-
|
581
|
-
|
582
|
-
|
581
|
+
<pre class="lines">54
|
582
|
+
55
|
583
|
+
56
|
584
|
+
57
|
585
|
+
58
|
586
|
+
59
|
587
|
+
60
|
588
|
+
61
|
589
|
+
62
|
590
|
+
63</pre>
|
583
591
|
</td>
|
584
592
|
<td>
|
585
|
-
<pre class="code"><span class='const'>
|
586
|
-
|
587
|
-
|
593
|
+
<pre class="code"><span class='const'>When</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I "(PUT|POST)" to the web service with the following$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> \
|
594
|
+
<span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_message'>message</span><span class='op'>|</span>
|
595
|
+
<span class='ivar'>@message</span> <span class='op'>=</span> <span class='id identifier rubyid_message'>message</span><span class='period'>.</span><span class='id identifier rubyid_strip'>strip</span>
|
596
|
+
<span class='kw'>case</span> <span class='id identifier rubyid_type'>type</span><span class='period'>.</span><span class='id identifier rubyid_downcase'>downcase</span>
|
597
|
+
<span class='kw'>when</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>put</span><span class='tstring_end'>'</span></span>
|
598
|
+
<span class='ivar'>@response</span> <span class='op'>=</span> <span class='ivar'>@restbaby</span><span class='period'>.</span><span class='id identifier rubyid_put'>put</span><span class='lparen'>(</span><span class='ivar'>@message</span><span class='rparen'>)</span>
|
599
|
+
<span class='kw'>when</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>post</span><span class='tstring_end'>'</span></span>
|
600
|
+
<span class='ivar'>@response</span> <span class='op'>=</span> <span class='ivar'>@restbaby</span><span class='period'>.</span><span class='id identifier rubyid_post'>post</span><span class='lparen'>(</span><span class='ivar'>@message</span><span class='rparen'>)</span>
|
601
|
+
<span class='kw'>end</span>
|
588
602
|
<span class='kw'>end</span></pre>
|
589
603
|
</td>
|
590
604
|
</tr>
|
@@ -594,7 +608,7 @@
|
|
594
608
|
<!-- Matching Step Instances -->
|
595
609
|
|
596
610
|
<div class='showSteps'>
|
597
|
-
[<a href='#' class='toggleSteps' alt="
|
611
|
+
[<a href='#' class='toggleSteps' alt="5 steps">Hide 5 steps</a>]
|
598
612
|
</div>
|
599
613
|
|
600
614
|
<div class="steps">
|
@@ -603,18 +617,16 @@
|
|
603
617
|
<div class="step odd">
|
604
618
|
<div>
|
605
619
|
<span class="predicate">
|
606
|
-
|
620
|
+
When
|
607
621
|
</span>
|
608
622
|
<span class="defined">
|
609
|
-
I
|
623
|
+
I "<span class='match'>PUT</span>" to the web service with the following
|
610
624
|
</span>
|
611
625
|
</div>
|
612
626
|
|
613
|
-
<a class="definition" style="clear: right;" href="features/
|
614
|
-
|
615
|
-
<a class="definition" style="clear: right;" href="features/headers/header_options.html">features/headers/header_options.feature:42</a>
|
627
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:18</a>
|
616
628
|
|
617
|
-
<a class="definition" style="clear: right;" href="features/
|
629
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:24</a>
|
618
630
|
|
619
631
|
<div style="clear: both;"></div>
|
620
632
|
</div>
|
@@ -622,44 +634,18 @@
|
|
622
634
|
<div class="step even">
|
623
635
|
<div>
|
624
636
|
<span class="predicate">
|
625
|
-
|
637
|
+
When
|
626
638
|
</span>
|
627
639
|
<span class="defined">
|
628
|
-
I
|
640
|
+
I "<span class='match'>POST</span>" to the web service with the following
|
629
641
|
</span>
|
630
642
|
</div>
|
631
643
|
|
632
|
-
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:
|
644
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:30</a>
|
633
645
|
|
634
|
-
<
|
635
|
-
</div>
|
636
|
-
|
637
|
-
<div class="step odd">
|
638
|
-
<div>
|
639
|
-
<span class="predicate">
|
640
|
-
And
|
641
|
-
</span>
|
642
|
-
<span class="defined">
|
643
|
-
I have "<span class='match'>POST</span>" service for "<span class='match'>/test</span>"
|
644
|
-
</span>
|
645
|
-
</div>
|
646
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:39</a>
|
646
647
|
|
647
|
-
<a class="definition" style="clear: right;" href="features/
|
648
|
-
|
649
|
-
<div style="clear: both;"></div>
|
650
|
-
</div>
|
651
|
-
|
652
|
-
<div class="step even">
|
653
|
-
<div>
|
654
|
-
<span class="predicate">
|
655
|
-
And
|
656
|
-
</span>
|
657
|
-
<span class="defined">
|
658
|
-
I have "<span class='match'>DELETE</span>" service for "<span class='match'>/test</span>"
|
659
|
-
</span>
|
660
|
-
</div>
|
661
|
-
|
662
|
-
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:36</a>
|
648
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:28</a>
|
663
649
|
|
664
650
|
<div style="clear: both;"></div>
|
665
651
|
</div>
|
@@ -678,12 +664,12 @@
|
|
678
664
|
<div class="transformer stepdefinition
|
679
665
|
|
680
666
|
">
|
681
|
-
<a name="
|
667
|
+
<a name="step_definition8-stepdefinition"></a>
|
682
668
|
<div class="title">
|
683
|
-
<span class="pre">
|
684
|
-
<span class="name">/^I "(PUT|POST)"
|
669
|
+
<span class="pre">Given</span>
|
670
|
+
<span class="name">/^I have "(GET|PUT|POST|DELETE)" service for "([^"]*)"$/</span>
|
685
671
|
<div style="float: right;">
|
686
|
-
<a href="http://rubular.com/?regex=%2F%5EI+%22%
|
672
|
+
<a href="http://rubular.com/?regex=%2F%5EI+have+%22%28GET%7CPUT%7CPOST%7CDELETE%29%22+service+for+%22%28%5B%5E%22%5D%2A%29%22%24%2F" target="_blank">Rubular</a>
|
687
673
|
|
688
674
|
|
689
675
|
</div>
|
@@ -693,7 +679,7 @@
|
|
693
679
|
<div class="details">
|
694
680
|
|
695
681
|
<div class="meta" style="clear: right;">
|
696
|
-
<div class="file">features/step_definitions/rest_client_steps.rb:
|
682
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:11</div>
|
697
683
|
</div>
|
698
684
|
|
699
685
|
<!-- Comments -->
|
@@ -707,23 +693,27 @@
|
|
707
693
|
<table class="source_code">
|
708
694
|
<tr>
|
709
695
|
<td>
|
710
|
-
<pre class="lines">
|
711
|
-
|
712
|
-
|
713
|
-
|
714
|
-
|
715
|
-
|
716
|
-
|
717
|
-
|
696
|
+
<pre class="lines">11
|
697
|
+
12
|
698
|
+
13
|
699
|
+
14
|
700
|
+
15
|
701
|
+
16
|
702
|
+
17
|
703
|
+
18
|
704
|
+
19
|
705
|
+
20</pre>
|
718
706
|
</td>
|
719
707
|
<td>
|
720
|
-
<pre class="code"><span class='const'>
|
721
|
-
|
722
|
-
|
723
|
-
|
724
|
-
|
725
|
-
|
726
|
-
|
708
|
+
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have "(GET|PUT|POST|DELETE)" service for "([^"]*)"$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='op'>|</span>
|
709
|
+
<span class='ivar'>@path</span> <span class='op'>=</span> <span class='id identifier rubyid_path'>path</span>
|
710
|
+
<span class='kw'>if</span> <span class='id identifier rubyid_type'>type</span> <span class='op'>==</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>GET</span><span class='tstring_end'>'</span></span>
|
711
|
+
<span class='id identifier rubyid_create_get'>create_get</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span>
|
712
|
+
<span class='kw'>else</span>
|
713
|
+
<span class='ivar'>@path</span> <span class='op'>=</span> <span class='id identifier rubyid_path'>path</span>
|
714
|
+
<span class='ivar'>@mockservice</span><span class='period'>.</span><span class='id identifier rubyid_store_msg'>store_msg</span><span class='lparen'>(</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='const'>DEFAULT_MSG</span><span class='comma'>,</span>
|
715
|
+
<span class='lbrace'>{</span><span class='rbrace'>}</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='const'>DEFAULT_RESPONSE</span><span class='rparen'>)</span>
|
716
|
+
<span class='kw'>end</span>
|
727
717
|
<span class='kw'>end</span></pre>
|
728
718
|
</td>
|
729
719
|
</tr>
|
@@ -745,15 +735,41 @@
|
|
745
735
|
And
|
746
736
|
</span>
|
747
737
|
<span class="defined">
|
748
|
-
I "<span class='match'>
|
738
|
+
I have "<span class='match'>GET</span>" service for "<span class='match'>/test</span>"
|
739
|
+
</span>
|
740
|
+
</div>
|
741
|
+
|
742
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:7</a>
|
743
|
+
|
744
|
+
<div style="clear: both;"></div>
|
745
|
+
</div>
|
746
|
+
|
747
|
+
<div class="step even">
|
748
|
+
<div>
|
749
|
+
<span class="predicate">
|
750
|
+
And
|
751
|
+
</span>
|
752
|
+
<span class="defined">
|
753
|
+
I have "<span class='match'>PUT</span>" service for "<span class='match'>/test</span>"
|
749
754
|
</span>
|
750
755
|
</div>
|
751
756
|
|
752
|
-
<a class="definition" style="clear: right;" href="features/
|
757
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:16</a>
|
753
758
|
|
754
|
-
<
|
759
|
+
<div style="clear: both;"></div>
|
760
|
+
</div>
|
761
|
+
|
762
|
+
<div class="step odd">
|
763
|
+
<div>
|
764
|
+
<span class="predicate">
|
765
|
+
And
|
766
|
+
</span>
|
767
|
+
<span class="defined">
|
768
|
+
I have "<span class='match'>POST</span>" service for "<span class='match'>/test</span>"
|
769
|
+
</span>
|
770
|
+
</div>
|
755
771
|
|
756
|
-
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:
|
772
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:28</a>
|
757
773
|
|
758
774
|
<div style="clear: both;"></div>
|
759
775
|
</div>
|
@@ -761,16 +777,29 @@
|
|
761
777
|
<div class="step even">
|
762
778
|
<div>
|
763
779
|
<span class="predicate">
|
764
|
-
|
780
|
+
And
|
765
781
|
</span>
|
766
782
|
<span class="defined">
|
767
|
-
I "<span class='match'>
|
783
|
+
I have "<span class='match'>DELETE</span>" service for "<span class='match'>/test</span>"
|
768
784
|
</span>
|
769
785
|
</div>
|
770
786
|
|
771
|
-
<a class="definition" style="clear: right;" href="features/
|
787
|
+
<a class="definition" style="clear: right;" href="features/rest_client.html">features/rest_client.feature:40</a>
|
772
788
|
|
773
|
-
<
|
789
|
+
<div style="clear: both;"></div>
|
790
|
+
</div>
|
791
|
+
|
792
|
+
<div class="step odd">
|
793
|
+
<div>
|
794
|
+
<span class="predicate">
|
795
|
+
And
|
796
|
+
</span>
|
797
|
+
<span class="defined">
|
798
|
+
I have "<span class='match'>GET</span>" service for "<span class='match'>/test?first=1&second=2&third=3</span>"
|
799
|
+
</span>
|
800
|
+
</div>
|
801
|
+
|
802
|
+
<a class="definition" style="clear: right;" href="features/url_parameter.html">features/url_parameter.feature:7</a>
|
774
803
|
|
775
804
|
<div style="clear: both;"></div>
|
776
805
|
</div>
|
@@ -789,12 +818,12 @@
|
|
789
818
|
<div class="transformer stepdefinition
|
790
819
|
|
791
820
|
">
|
792
|
-
<a name="
|
821
|
+
<a name="step_definition9-stepdefinition"></a>
|
793
822
|
<div class="title">
|
794
823
|
<span class="pre">Given</span>
|
795
|
-
<span class="name">/^I have "(GET|PUT|POST|DELETE)" service for "(
|
824
|
+
<span class="name">/^I have "(GET|PUT|POST|DELETE)" service for "([^"]*)" as follows$/</span>
|
796
825
|
<div style="float: right;">
|
797
|
-
<a href="http://rubular.com/?regex=%2F%5EI+have+%22%28GET%7CPUT%7CPOST%7CDELETE%29%22+service+for+%22%28
|
826
|
+
<a href="http://rubular.com/?regex=%2F%5EI+have+%22%28GET%7CPUT%7CPOST%7CDELETE%29%22+service+for+%22%28%5B%5E%22%5D%2A%29%22+as+follows%24%2F" target="_blank">Rubular</a>
|
798
827
|
|
799
828
|
|
800
829
|
</div>
|
@@ -804,7 +833,7 @@
|
|
804
833
|
<div class="details">
|
805
834
|
|
806
835
|
<div class="meta" style="clear: right;">
|
807
|
-
<div class="file">features/step_definitions/rest_client_steps.rb:
|
836
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:22</div>
|
808
837
|
</div>
|
809
838
|
|
810
839
|
<!-- Comments -->
|
@@ -818,15 +847,25 @@
|
|
818
847
|
<table class="source_code">
|
819
848
|
<tr>
|
820
849
|
<td>
|
821
|
-
<pre class="lines">
|
822
|
-
|
823
|
-
|
824
|
-
|
850
|
+
<pre class="lines">22
|
851
|
+
23
|
852
|
+
24
|
853
|
+
25
|
854
|
+
26
|
855
|
+
27
|
856
|
+
28
|
857
|
+
29
|
858
|
+
30</pre>
|
825
859
|
</td>
|
826
860
|
<td>
|
827
|
-
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have "(GET|PUT|POST|DELETE)" service for "(
|
828
|
-
|
829
|
-
|
861
|
+
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have "(GET|PUT|POST|DELETE)" service for "([^"]*)" as follows$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> \
|
862
|
+
<span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='id identifier rubyid_message'>message</span><span class='op'>|</span>
|
863
|
+
<span class='ivar'>@path</span> <span class='op'>=</span> <span class='id identifier rubyid_path'>path</span>
|
864
|
+
<span class='kw'>if</span> <span class='id identifier rubyid_type'>type</span> <span class='op'>==</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>GET</span><span class='tstring_end'>'</span></span>
|
865
|
+
<span class='id identifier rubyid_create_get'>create_get</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>
|
866
|
+
<span class='kw'>else</span>
|
867
|
+
<span class='ivar'>@mockservice</span><span class='period'>.</span><span class='id identifier rubyid_store_msg'>store_msg</span><span class='lparen'>(</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='const'>DEFAULT_MSG</span><span class='comma'>,</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='id identifier rubyid_message'>message</span><span class='rparen'>)</span>
|
868
|
+
<span class='kw'>end</span>
|
830
869
|
<span class='kw'>end</span></pre>
|
831
870
|
</td>
|
832
871
|
</tr>
|
@@ -852,7 +891,7 @@
|
|
852
891
|
</span>
|
853
892
|
</div>
|
854
893
|
|
855
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
894
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:7</a>
|
856
895
|
|
857
896
|
<div style="clear: both;"></div>
|
858
897
|
</div>
|
@@ -867,7 +906,7 @@
|
|
867
906
|
</span>
|
868
907
|
</div>
|
869
908
|
|
870
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
909
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:19</a>
|
871
910
|
|
872
911
|
<div style="clear: both;"></div>
|
873
912
|
</div>
|
@@ -882,7 +921,7 @@
|
|
882
921
|
</span>
|
883
922
|
</div>
|
884
923
|
|
885
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
924
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:34</a>
|
886
925
|
|
887
926
|
<div style="clear: both;"></div>
|
888
927
|
</div>
|
@@ -897,7 +936,7 @@
|
|
897
936
|
</span>
|
898
937
|
</div>
|
899
938
|
|
900
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:
|
939
|
+
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:49</a>
|
901
940
|
|
902
941
|
<div style="clear: both;"></div>
|
903
942
|
</div>
|
@@ -916,12 +955,12 @@
|
|
916
955
|
<div class="transformer stepdefinition
|
917
956
|
|
918
957
|
">
|
919
|
-
<a name="
|
958
|
+
<a name="step_definition5-stepdefinition"></a>
|
920
959
|
<div class="title">
|
921
|
-
<span class="pre">
|
922
|
-
<span class="name">/^
|
960
|
+
<span class="pre">When</span>
|
961
|
+
<span class="name">/^I have the following headers?$/</span>
|
923
962
|
<div style="float: right;">
|
924
|
-
<a href="http://rubular.com/?regex=%2F%
|
963
|
+
<a href="http://rubular.com/?regex=%2F%5EI+have+the+following+headers%3F%24%2F" target="_blank">Rubular</a>
|
925
964
|
|
926
965
|
|
927
966
|
</div>
|
@@ -931,7 +970,7 @@
|
|
931
970
|
<div class="details">
|
932
971
|
|
933
972
|
<div class="meta" style="clear: right;">
|
934
|
-
<div class="file">features/step_definitions/
|
973
|
+
<div class="file">features/step_definitions/header_steps.rb:27</div>
|
935
974
|
</div>
|
936
975
|
|
937
976
|
<!-- Comments -->
|
@@ -945,13 +984,13 @@
|
|
945
984
|
<table class="source_code">
|
946
985
|
<tr>
|
947
986
|
<td>
|
948
|
-
<pre class="lines">
|
949
|
-
|
950
|
-
|
987
|
+
<pre class="lines">27
|
988
|
+
28
|
989
|
+
29</pre>
|
951
990
|
</td>
|
952
991
|
<td>
|
953
|
-
<pre class="code"><span class='const'>
|
954
|
-
<span class='
|
992
|
+
<pre class="code"><span class='const'>When</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have the following headers?$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_table'>table</span><span class='op'>|</span>
|
993
|
+
<span class='ivar'>@restbaby</span><span class='period'>.</span><span class='id identifier rubyid_add_headers'>add_headers</span><span class='lparen'>(</span><span class='id identifier rubyid_table'>table</span><span class='period'>.</span><span class='id identifier rubyid_rows_hash'>rows_hash</span><span class='rparen'>)</span>
|
955
994
|
<span class='kw'>end</span></pre>
|
956
995
|
</td>
|
957
996
|
</tr>
|
@@ -961,7 +1000,7 @@
|
|
961
1000
|
<!-- Matching Step Instances -->
|
962
1001
|
|
963
1002
|
<div class='showSteps'>
|
964
|
-
[<a href='#' class='toggleSteps' alt="
|
1003
|
+
[<a href='#' class='toggleSteps' alt="2 steps">Hide 2 steps</a>]
|
965
1004
|
</div>
|
966
1005
|
|
967
1006
|
<div class="steps">
|
@@ -970,20 +1009,16 @@
|
|
970
1009
|
<div class="step odd">
|
971
1010
|
<div>
|
972
1011
|
<span class="predicate">
|
973
|
-
|
1012
|
+
When
|
974
1013
|
</span>
|
975
1014
|
<span class="defined">
|
976
|
-
|
1015
|
+
I have the following header
|
977
1016
|
</span>
|
978
1017
|
</div>
|
979
1018
|
|
980
|
-
<a class="definition" style="clear: right;" href="features/
|
981
|
-
|
982
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:35</a>
|
1019
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:10</a>
|
983
1020
|
|
984
|
-
<a class="definition" style="clear: right;" href="features/
|
985
|
-
|
986
|
-
<a class="definition" style="clear: right;" href="features/print_response.html">features/print_response.feature:72</a>
|
1021
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:25</a>
|
987
1022
|
|
988
1023
|
<div style="clear: both;"></div>
|
989
1024
|
</div>
|
@@ -1002,12 +1037,12 @@
|
|
1002
1037
|
<div class="transformer stepdefinition
|
1003
1038
|
|
1004
1039
|
">
|
1005
|
-
<a name="
|
1040
|
+
<a name="step_definition1-stepdefinition"></a>
|
1006
1041
|
<div class="title">
|
1007
1042
|
<span class="pre">Given</span>
|
1008
|
-
<span class="name">/^I have
|
1043
|
+
<span class="name">/^I have a secure web service$/</span>
|
1009
1044
|
<div style="float: right;">
|
1010
|
-
<a href="http://rubular.com/?regex=%2F%5EI+have+
|
1045
|
+
<a href="http://rubular.com/?regex=%2F%5EI+have+a+secure+web+service%24%2F" target="_blank">Rubular</a>
|
1011
1046
|
|
1012
1047
|
|
1013
1048
|
</div>
|
@@ -1017,7 +1052,7 @@
|
|
1017
1052
|
<div class="details">
|
1018
1053
|
|
1019
1054
|
<div class="meta" style="clear: right;">
|
1020
|
-
<div class="file">features/step_definitions/header_steps.rb:
|
1055
|
+
<div class="file">features/step_definitions/header_steps.rb:1</div>
|
1021
1056
|
</div>
|
1022
1057
|
|
1023
1058
|
<!-- Comments -->
|
@@ -1031,13 +1066,19 @@
|
|
1031
1066
|
<table class="source_code">
|
1032
1067
|
<tr>
|
1033
1068
|
<td>
|
1034
|
-
<pre class="lines">
|
1035
|
-
|
1036
|
-
|
1069
|
+
<pre class="lines">1
|
1070
|
+
2
|
1071
|
+
3
|
1072
|
+
4
|
1073
|
+
5
|
1074
|
+
6</pre>
|
1037
1075
|
</td>
|
1038
1076
|
<td>
|
1039
|
-
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have
|
1040
|
-
<span class='ivar'>@
|
1077
|
+
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have a secure web service$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span>
|
1078
|
+
<span class='ivar'>@protocol</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>https</span><span class='tstring_end'>'</span></span>
|
1079
|
+
<span class='ivar'>@server</span> <span class='op'>=</span> <span class='const'>FigNewton</span><span class='period'>.</span><span class='id identifier rubyid_server'>server</span>
|
1080
|
+
<span class='ivar'>@port</span> <span class='op'>=</span> <span class='const'>FigNewton</span><span class='period'>.</span><span class='id identifier rubyid_port'>port</span>
|
1081
|
+
<span class='ivar'>@mockservice</span> <span class='op'>=</span> <span class='const'>MockRestService</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@server</span><span class='comma'>,</span> <span class='ivar'>@port</span><span class='comma'>,</span> <span class='ivar'>@protocol</span><span class='rparen'>)</span>
|
1041
1082
|
<span class='kw'>end</span></pre>
|
1042
1083
|
</td>
|
1043
1084
|
</tr>
|
@@ -1047,7 +1088,7 @@
|
|
1047
1088
|
<!-- Matching Step Instances -->
|
1048
1089
|
|
1049
1090
|
<div class='showSteps'>
|
1050
|
-
[<a href='#' class='toggleSteps' alt="
|
1091
|
+
[<a href='#' class='toggleSteps' alt="1 steps">Hide 1 steps</a>]
|
1051
1092
|
</div>
|
1052
1093
|
|
1053
1094
|
<div class="steps">
|
@@ -1056,16 +1097,14 @@
|
|
1056
1097
|
<div class="step odd">
|
1057
1098
|
<div>
|
1058
1099
|
<span class="predicate">
|
1059
|
-
|
1100
|
+
Given
|
1060
1101
|
</span>
|
1061
1102
|
<span class="defined">
|
1062
|
-
I have
|
1103
|
+
I have a secure web service
|
1063
1104
|
</span>
|
1064
1105
|
</div>
|
1065
1106
|
|
1066
|
-
<a class="definition" style="clear: right;" href="features/
|
1067
|
-
|
1068
|
-
<a class="definition" style="clear: right;" href="features/headers/header_options.html">features/headers/header_options.feature:44</a>
|
1107
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">features/header_options.feature:47</a>
|
1069
1108
|
|
1070
1109
|
<div style="clear: both;"></div>
|
1071
1110
|
</div>
|
@@ -1084,12 +1123,12 @@
|
|
1084
1123
|
<div class="transformer stepdefinition
|
1085
1124
|
|
1086
1125
|
">
|
1087
|
-
<a name="
|
1126
|
+
<a name="step_definition16-stepdefinition"></a>
|
1088
1127
|
<div class="title">
|
1089
|
-
<span class="pre">
|
1090
|
-
<span class="name">/^I
|
1128
|
+
<span class="pre">Then</span>
|
1129
|
+
<span class="name">/^I receive a message with "([^"]*)"$/</span>
|
1091
1130
|
<div style="float: right;">
|
1092
|
-
<a href="http://rubular.com/?regex=%2F%5EI+
|
1131
|
+
<a href="http://rubular.com/?regex=%2F%5EI+receive+a+message+with+%22%28%5B%5E%22%5D%2A%29%22%24%2F" target="_blank">Rubular</a>
|
1093
1132
|
|
1094
1133
|
|
1095
1134
|
</div>
|
@@ -1099,7 +1138,7 @@
|
|
1099
1138
|
<div class="details">
|
1100
1139
|
|
1101
1140
|
<div class="meta" style="clear: right;">
|
1102
|
-
<div class="file">features/step_definitions/
|
1141
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:78</div>
|
1103
1142
|
</div>
|
1104
1143
|
|
1105
1144
|
<!-- Comments -->
|
@@ -1113,13 +1152,15 @@
|
|
1113
1152
|
<table class="source_code">
|
1114
1153
|
<tr>
|
1115
1154
|
<td>
|
1116
|
-
<pre class="lines">
|
1117
|
-
|
1118
|
-
|
1155
|
+
<pre class="lines">78
|
1156
|
+
79
|
1157
|
+
80
|
1158
|
+
81</pre>
|
1119
1159
|
</td>
|
1120
1160
|
<td>
|
1121
|
-
<pre class="code"><span class='const'>
|
1122
|
-
|
1161
|
+
<pre class="code"><span class='const'>Then</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I receive a message with "([^"]*)"$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_message'>message</span><span class='op'>|</span>
|
1162
|
+
<span class='id identifier rubyid_expect'>expect</span><span class='lparen'>(</span><span class='ivar'>@response</span><span class='period'>.</span><span class='id identifier rubyid_code'>code</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_to'>to</span> <span class='id identifier rubyid_eq'>eq</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>200</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
|
1163
|
+
<span class='id identifier rubyid_expect'>expect</span><span class='lparen'>(</span><span class='ivar'>@response</span><span class='period'>.</span><span class='id identifier rubyid_body'>body</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_to'>to</span> <span class='id identifier rubyid_eq'>eq</span><span class='lparen'>(</span><span class='id identifier rubyid_message'>message</span><span class='rparen'>)</span>
|
1123
1164
|
<span class='kw'>end</span></pre>
|
1124
1165
|
</td>
|
1125
1166
|
</tr>
|
@@ -1129,7 +1170,7 @@
|
|
1129
1170
|
<!-- Matching Step Instances -->
|
1130
1171
|
|
1131
1172
|
<div class='showSteps'>
|
1132
|
-
[<a href='#' class='toggleSteps' alt="
|
1173
|
+
[<a href='#' class='toggleSteps' alt="1 steps">Hide 1 steps</a>]
|
1133
1174
|
</div>
|
1134
1175
|
|
1135
1176
|
<div class="steps">
|
@@ -1138,16 +1179,14 @@
|
|
1138
1179
|
<div class="step odd">
|
1139
1180
|
<div>
|
1140
1181
|
<span class="predicate">
|
1141
|
-
|
1182
|
+
Then
|
1142
1183
|
</span>
|
1143
1184
|
<span class="defined">
|
1144
|
-
I
|
1185
|
+
I receive a message with "<span class='match'>first=1&second=2&third=3</span>"
|
1145
1186
|
</span>
|
1146
1187
|
</div>
|
1147
1188
|
|
1148
|
-
<a class="definition" style="clear: right;" href="features/
|
1149
|
-
|
1150
|
-
<a class="definition" style="clear: right;" href="features/headers/header_options.html">features/headers/header_options.feature:21</a>
|
1189
|
+
<a class="definition" style="clear: right;" href="features/url_parameter.html">features/url_parameter.feature:13</a>
|
1151
1190
|
|
1152
1191
|
<div style="clear: both;"></div>
|
1153
1192
|
</div>
|
@@ -1166,12 +1205,12 @@
|
|
1166
1205
|
<div class="transformer stepdefinition
|
1167
1206
|
|
1168
1207
|
">
|
1169
|
-
<a name="
|
1208
|
+
<a name="step_definition13-stepdefinition"></a>
|
1170
1209
|
<div class="title">
|
1171
|
-
<span class="pre">
|
1172
|
-
<span class="name">/^I
|
1210
|
+
<span class="pre">When</span>
|
1211
|
+
<span class="name">/^I "GET" from the web service with the parameters$/</span>
|
1173
1212
|
<div style="float: right;">
|
1174
|
-
<a href="http://rubular.com/?regex=%2F%5EI
|
1213
|
+
<a href="http://rubular.com/?regex=%2F%5EI+%22GET%22+from+the+web+service+with+the+parameters%24%2F" target="_blank">Rubular</a>
|
1175
1214
|
|
1176
1215
|
|
1177
1216
|
</div>
|
@@ -1181,7 +1220,7 @@
|
|
1181
1220
|
<div class="details">
|
1182
1221
|
|
1183
1222
|
<div class="meta" style="clear: right;">
|
1184
|
-
<div class="file">features/step_definitions/
|
1223
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:65</div>
|
1185
1224
|
</div>
|
1186
1225
|
|
1187
1226
|
<!-- Comments -->
|
@@ -1195,15 +1234,13 @@
|
|
1195
1234
|
<table class="source_code">
|
1196
1235
|
<tr>
|
1197
1236
|
<td>
|
1198
|
-
<pre class="lines">
|
1199
|
-
|
1200
|
-
|
1201
|
-
11</pre>
|
1237
|
+
<pre class="lines">65
|
1238
|
+
66
|
1239
|
+
67</pre>
|
1202
1240
|
</td>
|
1203
1241
|
<td>
|
1204
|
-
<pre class="code"><span class='const'>
|
1205
|
-
|
1206
|
-
<span class='ivar'>@mockservice</span><span class='period'>.</span><span class='id identifier rubyid_store_msg'>store_msg</span><span class='lparen'>(</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='const'>DEFAULT_MESSAGE</span><span class='comma'>,</span> <span class='id identifier rubyid_table'>table</span><span class='period'>.</span><span class='id identifier rubyid_rows_hash'>rows_hash</span><span class='rparen'>)</span>
|
1242
|
+
<pre class="code"><span class='const'>When</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I "GET" from the web service with the parameters$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_table'>table</span><span class='op'>|</span>
|
1243
|
+
<span class='ivar'>@response</span> <span class='op'>=</span> <span class='ivar'>@restbaby</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span><span class='lparen'>(</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='id identifier rubyid_table'>table</span><span class='period'>.</span><span class='id identifier rubyid_rows_hash'>rows_hash</span><span class='rparen'>)</span>
|
1207
1244
|
<span class='kw'>end</span></pre>
|
1208
1245
|
</td>
|
1209
1246
|
</tr>
|
@@ -1213,7 +1250,7 @@
|
|
1213
1250
|
<!-- Matching Step Instances -->
|
1214
1251
|
|
1215
1252
|
<div class='showSteps'>
|
1216
|
-
[<a href='#' class='toggleSteps' alt="
|
1253
|
+
[<a href='#' class='toggleSteps' alt="1 steps">Hide 1 steps</a>]
|
1217
1254
|
</div>
|
1218
1255
|
|
1219
1256
|
<div class="steps">
|
@@ -1222,29 +1259,14 @@
|
|
1222
1259
|
<div class="step odd">
|
1223
1260
|
<div>
|
1224
1261
|
<span class="predicate">
|
1225
|
-
|
1226
|
-
</span>
|
1227
|
-
<span class="defined">
|
1228
|
-
I have "<span class='match'>GET</span>" service for "<span class='match'>/test</span>" with the following headers
|
1229
|
-
</span>
|
1230
|
-
</div>
|
1231
|
-
|
1232
|
-
<a class="definition" style="clear: right;" href="features/headers/header_options.html">features/headers/header_options.feature:6</a>
|
1233
|
-
|
1234
|
-
<div style="clear: both;"></div>
|
1235
|
-
</div>
|
1236
|
-
|
1237
|
-
<div class="step even">
|
1238
|
-
<div>
|
1239
|
-
<span class="predicate">
|
1240
|
-
And
|
1262
|
+
When
|
1241
1263
|
</span>
|
1242
1264
|
<span class="defined">
|
1243
|
-
I
|
1265
|
+
I "GET" from the web service with the parameters
|
1244
1266
|
</span>
|
1245
1267
|
</div>
|
1246
1268
|
|
1247
|
-
<a class="definition" style="clear: right;" href="features/
|
1269
|
+
<a class="definition" style="clear: right;" href="features/url_parameter.html">features/url_parameter.feature:9</a>
|
1248
1270
|
|
1249
1271
|
<div style="clear: both;"></div>
|
1250
1272
|
</div>
|
@@ -1261,16 +1283,17 @@
|
|
1261
1283
|
|
1262
1284
|
|
1263
1285
|
<div class="transformer stepdefinition
|
1264
|
-
|
1286
|
+
nodefinitions
|
1265
1287
|
">
|
1266
|
-
<a name="
|
1288
|
+
<a name="step_definition3-stepdefinition"></a>
|
1267
1289
|
<div class="title">
|
1268
1290
|
<span class="pre">Given</span>
|
1269
|
-
<span class="name">/^I have
|
1291
|
+
<span class="name">/^I have "(GET|DELETE)" service for "([^"]*)" for \
|
1292
|
+
user "([^"]*)" and password "([^"]*)"$/</span>
|
1270
1293
|
<div style="float: right;">
|
1271
|
-
<a href="http://rubular.com/?regex=%2F%5EI+have+
|
1272
|
-
|
1294
|
+
<a href="http://rubular.com/?regex=%2F%5EI+have+%22%28GET%7CDELETE%29%22+service+for+%22%28%5B%5E%22%5D%2A%29%22+for+%5C%0Auser+%22%28%5B%5E%22%5D%2A%29%22+and+password+%22%28%5B%5E%22%5D%2A%29%22%24%2F" target="_blank">Rubular</a>
|
1273
1295
|
|
1296
|
+
| UNUSED
|
1274
1297
|
</div>
|
1275
1298
|
<div style="clear: both;"></div>
|
1276
1299
|
</div>
|
@@ -1278,7 +1301,7 @@
|
|
1278
1301
|
<div class="details">
|
1279
1302
|
|
1280
1303
|
<div class="meta" style="clear: right;">
|
1281
|
-
<div class="file">features/step_definitions/header_steps.rb:
|
1304
|
+
<div class="file">features/step_definitions/header_steps.rb:14</div>
|
1282
1305
|
</div>
|
1283
1306
|
|
1284
1307
|
<!-- Comments -->
|
@@ -1292,19 +1315,17 @@
|
|
1292
1315
|
<table class="source_code">
|
1293
1316
|
<tr>
|
1294
1317
|
<td>
|
1295
|
-
<pre class="lines">
|
1296
|
-
|
1297
|
-
|
1298
|
-
|
1299
|
-
|
1300
|
-
6</pre>
|
1318
|
+
<pre class="lines">14
|
1319
|
+
15
|
1320
|
+
16
|
1321
|
+
17
|
1322
|
+
18</pre>
|
1301
1323
|
</td>
|
1302
1324
|
<td>
|
1303
|
-
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have
|
1304
|
-
|
1305
|
-
|
1306
|
-
|
1307
|
-
<span class='ivar'>@mockservice</span> <span class='op'>=</span> <span class='const'>MockRestService</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@server</span><span class='comma'>,</span> <span class='ivar'>@port</span><span class='comma'>,</span> <span class='ivar'>@protocol</span><span class='rparen'>)</span>
|
1325
|
+
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have "(GET|DELETE)" service for "([^"]*)" for \
|
1326
|
+
user "([^"]*)" and password "([^"]*)"$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='id identifier rubyid_user'>user</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='op'>|</span>
|
1327
|
+
<span class='ivar'>@path</span> <span class='op'>=</span> <span class='id identifier rubyid_path'>path</span>
|
1328
|
+
<span class='ivar'>@mockservice</span><span class='period'>.</span><span class='id identifier rubyid_store_msg'>store_msg</span><span class='lparen'>(</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='const'>DEFAULT_MSG</span><span class='comma'>,</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='comma'>,</span> <span class='id identifier rubyid_user'>user</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='rparen'>)</span>
|
1308
1329
|
<span class='kw'>end</span></pre>
|
1309
1330
|
</td>
|
1310
1331
|
</tr>
|
@@ -1313,28 +1334,9 @@
|
|
1313
1334
|
|
1314
1335
|
<!-- Matching Step Instances -->
|
1315
1336
|
|
1316
|
-
<div class='showSteps'>
|
1317
|
-
[<a href='#' class='toggleSteps' alt="1 steps">Hide 1 steps</a>]
|
1318
|
-
</div>
|
1319
|
-
|
1320
1337
|
<div class="steps">
|
1321
1338
|
|
1322
|
-
|
1323
|
-
<div class="step odd">
|
1324
|
-
<div>
|
1325
|
-
<span class="predicate">
|
1326
|
-
Given
|
1327
|
-
</span>
|
1328
|
-
<span class="defined">
|
1329
|
-
I have a secure web service
|
1330
|
-
</span>
|
1331
|
-
</div>
|
1332
|
-
|
1333
|
-
<a class="definition" style="clear: right;" href="features/headers/header_options.html">features/headers/header_options.feature:41</a>
|
1334
|
-
|
1335
|
-
<div style="clear: both;"></div>
|
1336
|
-
</div>
|
1337
|
-
|
1339
|
+
<div class="undefined">No steps were found to match this step definition.</div>
|
1338
1340
|
|
1339
1341
|
</div>
|
1340
1342
|
|
@@ -1349,12 +1351,13 @@
|
|
1349
1351
|
<div class="transformer stepdefinition
|
1350
1352
|
nodefinitions
|
1351
1353
|
">
|
1352
|
-
<a name="
|
1354
|
+
<a name="step_definition4-stepdefinition"></a>
|
1353
1355
|
<div class="title">
|
1354
|
-
<span class="pre">
|
1355
|
-
<span class="name">/^I
|
1356
|
+
<span class="pre">Given</span>
|
1357
|
+
<span class="name">/^I have "(PUT|POST)" service for "([^"]*)" for \
|
1358
|
+
user "([^"]*)" and password "([^"]*)"$/</span>
|
1356
1359
|
<div style="float: right;">
|
1357
|
-
<a href="http://rubular.com/?regex=%2F%5EI+
|
1360
|
+
<a href="http://rubular.com/?regex=%2F%5EI+have+%22%28PUT%7CPOST%29%22+service+for+%22%28%5B%5E%22%5D%2A%29%22+for+%5C%0Auser+%22%28%5B%5E%22%5D%2A%29%22+and+password+%22%28%5B%5E%22%5D%2A%29%22%24%2F" target="_blank">Rubular</a>
|
1358
1361
|
|
1359
1362
|
| UNUSED
|
1360
1363
|
</div>
|
@@ -1364,7 +1367,7 @@
|
|
1364
1367
|
<div class="details">
|
1365
1368
|
|
1366
1369
|
<div class="meta" style="clear: right;">
|
1367
|
-
<div class="file">features/step_definitions/
|
1370
|
+
<div class="file">features/step_definitions/header_steps.rb:20</div>
|
1368
1371
|
</div>
|
1369
1372
|
|
1370
1373
|
<!-- Comments -->
|
@@ -1378,15 +1381,19 @@
|
|
1378
1381
|
<table class="source_code">
|
1379
1382
|
<tr>
|
1380
1383
|
<td>
|
1381
|
-
<pre class="lines">
|
1382
|
-
|
1383
|
-
|
1384
|
-
|
1384
|
+
<pre class="lines">20
|
1385
|
+
21
|
1386
|
+
22
|
1387
|
+
23
|
1388
|
+
24
|
1389
|
+
25</pre>
|
1385
1390
|
</td>
|
1386
1391
|
<td>
|
1387
|
-
<pre class="code"><span class='const'>
|
1388
|
-
|
1389
|
-
|
1392
|
+
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have "(PUT|POST)" service for "([^"]*)" for \
|
1393
|
+
user "([^"]*)" and password "([^"]*)"$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='id identifier rubyid_user'>user</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='comma'>,</span> <span class='id identifier rubyid_table'>table</span><span class='op'>|</span>
|
1394
|
+
<span class='ivar'>@path</span> <span class='op'>=</span> <span class='id identifier rubyid_path'>path</span>
|
1395
|
+
<span class='ivar'>@headers</span> <span class='op'>=</span> <span class='id identifier rubyid_table'>table</span><span class='period'>.</span><span class='id identifier rubyid_rows_hash'>rows_hash</span>
|
1396
|
+
<span class='ivar'>@mockservice</span><span class='period'>.</span><span class='id identifier rubyid_store_msg'>store_msg</span><span class='lparen'>(</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='const'>DEFAULT_MSG</span><span class='comma'>,</span> <span class='ivar'>@headers</span><span class='comma'>,</span> <span class='id identifier rubyid_user'>user</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='rparen'>)</span>
|
1390
1397
|
<span class='kw'>end</span></pre>
|
1391
1398
|
</td>
|
1392
1399
|
</tr>
|
@@ -1412,7 +1419,7 @@
|
|
1412
1419
|
<div class="transformer stepdefinition
|
1413
1420
|
nodefinitions
|
1414
1421
|
">
|
1415
|
-
<a name="
|
1422
|
+
<a name="step_definition14-stepdefinition"></a>
|
1416
1423
|
<div class="title">
|
1417
1424
|
<span class="pre">When</span>
|
1418
1425
|
<span class="name">/^I pause$/</span>
|
@@ -1427,7 +1434,7 @@
|
|
1427
1434
|
<div class="details">
|
1428
1435
|
|
1429
1436
|
<div class="meta" style="clear: right;">
|
1430
|
-
<div class="file">features/step_definitions/rest_client_steps.rb:
|
1437
|
+
<div class="file">features/step_definitions/rest_client_steps.rb:69</div>
|
1431
1438
|
</div>
|
1432
1439
|
|
1433
1440
|
<!-- Comments -->
|
@@ -1441,13 +1448,143 @@
|
|
1441
1448
|
<table class="source_code">
|
1442
1449
|
<tr>
|
1443
1450
|
<td>
|
1444
|
-
<pre class="lines">
|
1445
|
-
|
1446
|
-
|
1451
|
+
<pre class="lines">69
|
1452
|
+
70
|
1453
|
+
71</pre>
|
1447
1454
|
</td>
|
1448
1455
|
<td>
|
1449
1456
|
<pre class="code"><span class='const'>When</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I pause$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span>
|
1450
|
-
<span class='id identifier rubyid_pause'>pause</span
|
1457
|
+
<span class='id identifier rubyid_pause'>pause</span>
|
1458
|
+
<span class='kw'>end</span></pre>
|
1459
|
+
</td>
|
1460
|
+
</tr>
|
1461
|
+
</table>
|
1462
|
+
</div>
|
1463
|
+
|
1464
|
+
<!-- Matching Step Instances -->
|
1465
|
+
|
1466
|
+
<div class="steps">
|
1467
|
+
|
1468
|
+
<div class="undefined">No steps were found to match this step definition.</div>
|
1469
|
+
|
1470
|
+
</div>
|
1471
|
+
|
1472
|
+
</div>
|
1473
|
+
|
1474
|
+
<div style="margin: 30px 20px; border-top: 1px dotted #AAA;"></div>
|
1475
|
+
|
1476
|
+
</div>
|
1477
|
+
|
1478
|
+
|
1479
|
+
|
1480
|
+
<div class="transformer stepdefinition
|
1481
|
+
nodefinitions
|
1482
|
+
">
|
1483
|
+
<a name="step_definition2-stepdefinition"></a>
|
1484
|
+
<div class="title">
|
1485
|
+
<span class="pre">Given</span>
|
1486
|
+
<span class="name">/^I have "(GET|PUT|POST|DELETE)" service for "([^"]*)" \
|
1487
|
+
with the following headers$/</span>
|
1488
|
+
<div style="float: right;">
|
1489
|
+
<a href="http://rubular.com/?regex=%2F%5EI+have+%22%28GET%7CPUT%7CPOST%7CDELETE%29%22+service+for+%22%28%5B%5E%22%5D%2A%29%22+%5C%0Awith+the+following+headers%24%2F" target="_blank">Rubular</a>
|
1490
|
+
|
1491
|
+
| UNUSED
|
1492
|
+
</div>
|
1493
|
+
<div style="clear: both;"></div>
|
1494
|
+
</div>
|
1495
|
+
|
1496
|
+
<div class="details">
|
1497
|
+
|
1498
|
+
<div class="meta" style="clear: right;">
|
1499
|
+
<div class="file">features/step_definitions/header_steps.rb:8</div>
|
1500
|
+
</div>
|
1501
|
+
|
1502
|
+
<!-- Comments -->
|
1503
|
+
<div>
|
1504
|
+
|
1505
|
+
</div>
|
1506
|
+
|
1507
|
+
|
1508
|
+
<!-- Source Code -->
|
1509
|
+
<div class="method_details_list">
|
1510
|
+
<table class="source_code">
|
1511
|
+
<tr>
|
1512
|
+
<td>
|
1513
|
+
<pre class="lines">8
|
1514
|
+
9
|
1515
|
+
10
|
1516
|
+
11
|
1517
|
+
12</pre>
|
1518
|
+
</td>
|
1519
|
+
<td>
|
1520
|
+
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have "(GET|PUT|POST|DELETE)" service for "([^"]*)" \
|
1521
|
+
with the following headers$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='id identifier rubyid_table'>table</span><span class='op'>|</span>
|
1522
|
+
<span class='ivar'>@path</span> <span class='op'>=</span> <span class='id identifier rubyid_path'>path</span>
|
1523
|
+
<span class='ivar'>@mockservice</span><span class='period'>.</span><span class='id identifier rubyid_store_msg'>store_msg</span><span class='lparen'>(</span><span class='id identifier rubyid_type'>type</span><span class='comma'>,</span> <span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='const'>DEFAULT_MSG</span><span class='comma'>,</span> <span class='id identifier rubyid_table'>table</span><span class='period'>.</span><span class='id identifier rubyid_rows_hash'>rows_hash</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='const'>DEFAULT_RESPONSE</span><span class='rparen'>)</span>
|
1524
|
+
<span class='kw'>end</span></pre>
|
1525
|
+
</td>
|
1526
|
+
</tr>
|
1527
|
+
</table>
|
1528
|
+
</div>
|
1529
|
+
|
1530
|
+
<!-- Matching Step Instances -->
|
1531
|
+
|
1532
|
+
<div class="steps">
|
1533
|
+
|
1534
|
+
<div class="undefined">No steps were found to match this step definition.</div>
|
1535
|
+
|
1536
|
+
</div>
|
1537
|
+
|
1538
|
+
</div>
|
1539
|
+
|
1540
|
+
<div style="margin: 30px 20px; border-top: 1px dotted #AAA;"></div>
|
1541
|
+
|
1542
|
+
</div>
|
1543
|
+
|
1544
|
+
|
1545
|
+
|
1546
|
+
<div class="transformer stepdefinition
|
1547
|
+
nodefinitions
|
1548
|
+
">
|
1549
|
+
<a name="step_definition6-stepdefinition"></a>
|
1550
|
+
<div class="title">
|
1551
|
+
<span class="pre">Given</span>
|
1552
|
+
<span class="name">/^I have basic auth for user "([^"]*)" \
|
1553
|
+
and password "(.*?)"$/</span>
|
1554
|
+
<div style="float: right;">
|
1555
|
+
<a href="http://rubular.com/?regex=%2F%5EI+have+basic+auth+for+user+%22%28%5B%5E%22%5D%2A%29%22+%5C%0Aand+password+%22%28.%2A%3F%29%22%24%2F" target="_blank">Rubular</a>
|
1556
|
+
|
1557
|
+
| UNUSED
|
1558
|
+
</div>
|
1559
|
+
<div style="clear: both;"></div>
|
1560
|
+
</div>
|
1561
|
+
|
1562
|
+
<div class="details">
|
1563
|
+
|
1564
|
+
<div class="meta" style="clear: right;">
|
1565
|
+
<div class="file">features/step_definitions/header_steps.rb:31</div>
|
1566
|
+
</div>
|
1567
|
+
|
1568
|
+
<!-- Comments -->
|
1569
|
+
<div>
|
1570
|
+
|
1571
|
+
</div>
|
1572
|
+
|
1573
|
+
|
1574
|
+
<!-- Source Code -->
|
1575
|
+
<div class="method_details_list">
|
1576
|
+
<table class="source_code">
|
1577
|
+
<tr>
|
1578
|
+
<td>
|
1579
|
+
<pre class="lines">31
|
1580
|
+
32
|
1581
|
+
33
|
1582
|
+
34</pre>
|
1583
|
+
</td>
|
1584
|
+
<td>
|
1585
|
+
<pre class="code"><span class='const'>Given</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^I have basic auth for user "([^"]*)" \
|
1586
|
+
and password "(.*?)"$</span><span class='regexp_end'>/</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_user'>user</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='op'>|</span>
|
1587
|
+
<span class='ivar'>@restbaby</span><span class='period'>.</span><span class='id identifier rubyid_set_auth'>set_auth</span><span class='lparen'>(</span><span class='id identifier rubyid_user'>user</span><span class='comma'>,</span> <span class='id identifier rubyid_password'>password</span><span class='rparen'>)</span>
|
1451
1588
|
<span class='kw'>end</span></pre>
|
1452
1589
|
</td>
|
1453
1590
|
</tr>
|
@@ -1492,18 +1629,84 @@
|
|
1492
1629
|
<div class="transformer">
|
1493
1630
|
<div class="steps">
|
1494
1631
|
|
1495
|
-
|
1496
|
-
|
1632
|
+
|
1633
|
+
<div class="step odd">
|
1634
|
+
<div>
|
1635
|
+
<span class="predicate">And </span>
|
1636
|
+
<span class="undefined">
|
1637
|
+
I have basic auth for user "test" and password "rest"
|
1638
|
+
</span>
|
1639
|
+
</div>
|
1640
|
+
|
1641
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">
|
1642
|
+
features/header_options.feature:40
|
1643
|
+
</a>
|
1644
|
+
|
1645
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">
|
1646
|
+
features/header_options.feature:50
|
1647
|
+
</a>
|
1648
|
+
|
1649
|
+
<div style="clear: both;"></div>
|
1650
|
+
</div>
|
1651
|
+
|
1652
|
+
<div class="step even">
|
1653
|
+
<div>
|
1654
|
+
<span class="predicate">And </span>
|
1655
|
+
<span class="undefined">
|
1656
|
+
I have "GET" service for "/test" for user "test" and password "rest"
|
1657
|
+
</span>
|
1658
|
+
</div>
|
1659
|
+
|
1660
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">
|
1661
|
+
features/header_options.feature:38
|
1662
|
+
</a>
|
1663
|
+
|
1664
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">
|
1665
|
+
features/header_options.feature:48
|
1666
|
+
</a>
|
1667
|
+
|
1668
|
+
<div style="clear: both;"></div>
|
1669
|
+
</div>
|
1670
|
+
|
1671
|
+
<div class="step odd">
|
1672
|
+
<div>
|
1673
|
+
<span class="predicate">And </span>
|
1674
|
+
<span class="undefined">
|
1675
|
+
I have "POST" service for "/test" with the following headers
|
1676
|
+
</span>
|
1677
|
+
</div>
|
1678
|
+
|
1679
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">
|
1680
|
+
features/header_options.feature:19
|
1681
|
+
</a>
|
1682
|
+
|
1683
|
+
<div style="clear: both;"></div>
|
1497
1684
|
</div>
|
1498
1685
|
|
1686
|
+
<div class="step even">
|
1687
|
+
<div>
|
1688
|
+
<span class="predicate">And </span>
|
1689
|
+
<span class="undefined">
|
1690
|
+
I have "GET" service for "/test" with the following headers
|
1691
|
+
</span>
|
1692
|
+
</div>
|
1693
|
+
|
1694
|
+
<a class="definition" style="clear: right;" href="features/header_options.html">
|
1695
|
+
features/header_options.feature:7
|
1696
|
+
</a>
|
1697
|
+
|
1698
|
+
<div style="clear: both;"></div>
|
1699
|
+
</div>
|
1700
|
+
|
1701
|
+
|
1499
1702
|
</div>
|
1500
1703
|
</div>
|
1501
1704
|
</div>
|
1502
1705
|
|
1503
1706
|
<div id="footer">
|
1504
|
-
Generated on
|
1707
|
+
Generated on Fri Jul 17 23:52:38 2015 by
|
1505
1708
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
1506
|
-
0.8.7 (ruby-2.0.0).
|
1709
|
+
0.8.7.6 (ruby-2.0.0).
|
1507
1710
|
</div>
|
1508
1711
|
|
1509
1712
|
</body>
|