mocha 1.7.0 → 1.8.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (72) hide show
  1. checksums.yaml +4 -4
  2. data/CONTRIBUTING.md +4 -9
  3. data/README.md +17 -16
  4. data/RELEASE.md +10 -0
  5. data/Rakefile +6 -13
  6. data/bin/build-matrix +16 -2
  7. data/docs/CNAME +1 -0
  8. data/docs/Mocha.html +127 -0
  9. data/docs/Mocha/API.html +1056 -0
  10. data/docs/Mocha/ClassMethods.html +267 -0
  11. data/docs/Mocha/Configuration.html +626 -0
  12. data/docs/Mocha/Expectation.html +2709 -0
  13. data/docs/Mocha/ExpectationError.html +157 -0
  14. data/docs/Mocha/ExpectationErrorFactory.html +269 -0
  15. data/docs/Mocha/Hooks.html +385 -0
  16. data/docs/Mocha/Integration.html +125 -0
  17. data/docs/Mocha/Integration/MiniTest.html +123 -0
  18. data/docs/Mocha/Integration/MiniTest/Adapter.html +165 -0
  19. data/docs/Mocha/Integration/TestUnit.html +123 -0
  20. data/docs/Mocha/Integration/TestUnit/Adapter.html +165 -0
  21. data/docs/Mocha/Mock.html +1197 -0
  22. data/docs/Mocha/ObjectMethods.html +712 -0
  23. data/docs/Mocha/ParameterMatchers.html +3049 -0
  24. data/docs/Mocha/ParameterMatchers/AllOf.html +154 -0
  25. data/docs/Mocha/ParameterMatchers/AnyOf.html +154 -0
  26. data/docs/Mocha/ParameterMatchers/AnyParameters.html +153 -0
  27. data/docs/Mocha/ParameterMatchers/Anything.html +153 -0
  28. data/docs/Mocha/ParameterMatchers/Base.html +448 -0
  29. data/docs/Mocha/ParameterMatchers/Equals.html +154 -0
  30. data/docs/Mocha/ParameterMatchers/EquivalentUri.html +153 -0
  31. data/docs/Mocha/ParameterMatchers/HasEntries.html +154 -0
  32. data/docs/Mocha/ParameterMatchers/HasEntry.html +154 -0
  33. data/docs/Mocha/ParameterMatchers/HasKey.html +154 -0
  34. data/docs/Mocha/ParameterMatchers/HasValue.html +154 -0
  35. data/docs/Mocha/ParameterMatchers/Includes.html +154 -0
  36. data/docs/Mocha/ParameterMatchers/InstanceOf.html +154 -0
  37. data/docs/Mocha/ParameterMatchers/IsA.html +153 -0
  38. data/docs/Mocha/ParameterMatchers/KindOf.html +154 -0
  39. data/docs/Mocha/ParameterMatchers/Not.html +154 -0
  40. data/docs/Mocha/ParameterMatchers/Optionally.html +153 -0
  41. data/docs/Mocha/ParameterMatchers/RegexpMatches.html +154 -0
  42. data/docs/Mocha/ParameterMatchers/RespondsWith.html +154 -0
  43. data/docs/Mocha/ParameterMatchers/YamlEquivalent.html +154 -0
  44. data/docs/Mocha/Sequence.html +149 -0
  45. data/docs/Mocha/StateMachine.html +539 -0
  46. data/docs/Mocha/StateMachine/State.html +141 -0
  47. data/docs/Mocha/StateMachine/StatePredicate.html +141 -0
  48. data/docs/Mocha/StubbingError.html +150 -0
  49. data/docs/Mocha/UnexpectedInvocation.html +140 -0
  50. data/docs/_index.html +537 -0
  51. data/docs/class_list.html +51 -0
  52. data/docs/css/common.css +1 -0
  53. data/docs/css/full_list.css +58 -0
  54. data/docs/css/style.css +496 -0
  55. data/docs/file.COPYING.html +81 -0
  56. data/docs/file.MIT-LICENSE.html +85 -0
  57. data/docs/file.README.html +418 -0
  58. data/docs/file.RELEASE.html +875 -0
  59. data/docs/file_list.html +71 -0
  60. data/docs/frames.html +17 -0
  61. data/docs/index.html +418 -0
  62. data/docs/js/app.js +292 -0
  63. data/docs/js/full_list.js +216 -0
  64. data/docs/js/jquery.js +4 -0
  65. data/docs/method_list.html +571 -0
  66. data/docs/top-level-namespace.html +118 -0
  67. data/lib/mocha/inspect.rb +1 -1
  68. data/lib/mocha/version.rb +1 -1
  69. data/mocha.gemspec +2 -3
  70. data/test/unit/object_inspect_test.rb +10 -0
  71. data/yard-templates/default/layout/html/google_analytics.erb +6 -9
  72. metadata +68 -36
@@ -0,0 +1,149 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>
7
+ Class: Mocha::Sequence
8
+
9
+ &mdash; Mocha 1.8.0
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
+ <script type="text/javascript" charset="utf-8">
18
+ pathId = "Mocha::Sequence";
19
+ relpath = '../';
20
+ </script>
21
+
22
+
23
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
24
+
25
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
26
+
27
+
28
+ </head>
29
+ <body>
30
+ <div class="nav_wrap">
31
+ <iframe id="nav" src="../class_list.html?1"></iframe>
32
+ <div id="resizer"></div>
33
+ </div>
34
+
35
+ <div id="main" tabindex="-1">
36
+ <div id="header">
37
+ <div id="menu">
38
+
39
+ <a href="../_index.html">Index (S)</a> &raquo;
40
+ <span class='title'><span class='object_link'><a href="../Mocha.html" title="Mocha (module)">Mocha</a></span></span>
41
+ &raquo;
42
+ <span class="title">Sequence</span>
43
+
44
+ </div>
45
+
46
+ <div id="search">
47
+
48
+ <a class="full_list_link" id="class_list_link"
49
+ href="../class_list.html">
50
+
51
+ <svg width="24" height="24">
52
+ <rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
53
+ <rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
54
+ <rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
55
+ </svg>
56
+ </a>
57
+
58
+ </div>
59
+ <div class="clear"></div>
60
+ </div>
61
+
62
+ <div id="content"><h1>Class: Mocha::Sequence
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+ <dl>
70
+ <dt>Inherits:</dt>
71
+ <dd>
72
+ <span class="inheritName"><span class='object_link'>Object</span></span>
73
+
74
+ <ul class="fullTree">
75
+ <li><span class='object_link'>Object</span></li>
76
+
77
+ <li class="next">Mocha::Sequence</li>
78
+
79
+ </ul>
80
+ <a href="#" class="inheritanceTree">show all</a>
81
+
82
+ </dd>
83
+ </dl>
84
+
85
+
86
+
87
+
88
+
89
+
90
+
91
+
92
+
93
+
94
+
95
+ <dl>
96
+ <dt>Defined in:</dt>
97
+ <dd>lib/mocha/sequence.rb</dd>
98
+ </dl>
99
+
100
+ </div>
101
+
102
+ <h2>Overview</h2><div class="docstring">
103
+ <div class="discussion">
104
+
105
+ <p>Used to constrain the order in which expectations can occur.</p>
106
+
107
+
108
+ </div>
109
+ </div>
110
+ <div class="tags">
111
+
112
+
113
+ <p class="tag_title">See Also:</p>
114
+ <ul class="see">
115
+
116
+ <li><span class='object_link'><a href="API.html#sequence-instance_method" title="Mocha::API#sequence (method)">API#sequence</a></span></li>
117
+
118
+ <li><span class='object_link'><a href="Expectation.html#in_sequence-instance_method" title="Mocha::Expectation#in_sequence (method)">Expectation#in_sequence</a></span></li>
119
+
120
+ </ul>
121
+
122
+ </div>
123
+
124
+
125
+
126
+
127
+
128
+
129
+
130
+
131
+ <script async src="https://www.googletagmanager.com/gtag/js?id=UA-625523-7"></script>
132
+ <script>
133
+ window.dataLayer = window.dataLayer || [];
134
+ function gtag(){dataLayer.push(arguments);}
135
+ gtag('js', new Date());
136
+
137
+ gtag('config', 'UA-625523-7');
138
+ </script>
139
+ </div>
140
+
141
+ <div id="footer">
142
+ Generated on Tue Jan 15 17:13:06 2019 by
143
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
144
+ 0.9.16 (ruby-2.5.3).
145
+ </div>
146
+
147
+ </div>
148
+ </body>
149
+ </html>
@@ -0,0 +1,539 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>
7
+ Class: Mocha::StateMachine
8
+
9
+ &mdash; Mocha 1.8.0
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
+ <script type="text/javascript" charset="utf-8">
18
+ pathId = "Mocha::StateMachine";
19
+ relpath = '../';
20
+ </script>
21
+
22
+
23
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
24
+
25
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
26
+
27
+
28
+ </head>
29
+ <body>
30
+ <div class="nav_wrap">
31
+ <iframe id="nav" src="../class_list.html?1"></iframe>
32
+ <div id="resizer"></div>
33
+ </div>
34
+
35
+ <div id="main" tabindex="-1">
36
+ <div id="header">
37
+ <div id="menu">
38
+
39
+ <a href="../_index.html">Index (S)</a> &raquo;
40
+ <span class='title'><span class='object_link'><a href="../Mocha.html" title="Mocha (module)">Mocha</a></span></span>
41
+ &raquo;
42
+ <span class="title">StateMachine</span>
43
+
44
+ </div>
45
+
46
+ <div id="search">
47
+
48
+ <a class="full_list_link" id="class_list_link"
49
+ href="../class_list.html">
50
+
51
+ <svg width="24" height="24">
52
+ <rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
53
+ <rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
54
+ <rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
55
+ </svg>
56
+ </a>
57
+
58
+ </div>
59
+ <div class="clear"></div>
60
+ </div>
61
+
62
+ <div id="content"><h1>Class: Mocha::StateMachine
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+ <dl>
70
+ <dt>Inherits:</dt>
71
+ <dd>
72
+ <span class="inheritName"><span class='object_link'>Object</span></span>
73
+
74
+ <ul class="fullTree">
75
+ <li><span class='object_link'>Object</span></li>
76
+
77
+ <li class="next">Mocha::StateMachine</li>
78
+
79
+ </ul>
80
+ <a href="#" class="inheritanceTree">show all</a>
81
+
82
+ </dd>
83
+ </dl>
84
+
85
+
86
+
87
+
88
+
89
+
90
+
91
+
92
+
93
+
94
+
95
+ <dl>
96
+ <dt>Defined in:</dt>
97
+ <dd>lib/mocha/state_machine.rb</dd>
98
+ </dl>
99
+
100
+ </div>
101
+
102
+ <h2>Overview</h2><div class="docstring">
103
+ <div class="discussion">
104
+
105
+ <p>A state machine that is used to constrain the order of invocations. An
106
+ invocation can be constrained to occur when a state <span class='object_link'><a href="#is-instance_method" title="Mocha::StateMachine#is (method)">#is</a></span>, or <span class='object_link'><a href="#is_not-instance_method" title="Mocha::StateMachine#is_not (method)">#is_not</a></span>,
107
+ active.</p>
108
+
109
+
110
+ </div>
111
+ </div>
112
+ <div class="tags">
113
+
114
+
115
+ </div><h2>Defined Under Namespace</h2>
116
+ <p class="children">
117
+
118
+
119
+
120
+
121
+ <strong class="classes">Classes:</strong> <span class='object_link'><a href="StateMachine/State.html" title="Mocha::StateMachine::State (class)">State</a></span>, <span class='object_link'><a href="StateMachine/StatePredicate.html" title="Mocha::StateMachine::StatePredicate (class)">StatePredicate</a></span>
122
+
123
+
124
+ </p>
125
+
126
+
127
+
128
+
129
+
130
+
131
+
132
+
133
+ <h2>
134
+ Instance Method Summary
135
+ <small><a href="#" class="summary_toggle">collapse</a></small>
136
+ </h2>
137
+
138
+ <ul class="summary">
139
+
140
+ <li class="public ">
141
+ <span class="summary_signature">
142
+
143
+ <a href="#become-instance_method" title="#become (instance method)">#<strong>become</strong>(next_state_name) &#x21d2; Object </a>
144
+
145
+
146
+
147
+ </span>
148
+
149
+
150
+
151
+
152
+
153
+
154
+
155
+
156
+
157
+ <span class="summary_desc"><div class='inline'>
158
+ <p>Put the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">StateMachine</a></span> into the <code>next_state_name</code>.</p>
159
+ </div></span>
160
+
161
+ </li>
162
+
163
+
164
+ <li class="public ">
165
+ <span class="summary_signature">
166
+
167
+ <a href="#is-instance_method" title="#is (instance method)">#<strong>is</strong>(state_name) &#x21d2; State </a>
168
+
169
+
170
+
171
+ </span>
172
+
173
+
174
+
175
+
176
+
177
+
178
+
179
+
180
+
181
+ <span class="summary_desc"><div class='inline'>
182
+ <p>Provides a mechanism to change the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">StateMachine</a></span> into the state specified
183
+ by <code>state_name</code> at some point in the future.</p>
184
+ </div></span>
185
+
186
+ </li>
187
+
188
+
189
+ <li class="public ">
190
+ <span class="summary_signature">
191
+
192
+ <a href="#is_not-instance_method" title="#is_not (instance method)">#<strong>is_not</strong>(state_name) &#x21d2; Object </a>
193
+
194
+
195
+
196
+ </span>
197
+
198
+
199
+
200
+
201
+
202
+
203
+
204
+
205
+
206
+ <span class="summary_desc"><div class='inline'>
207
+ <p>Provides a mechanism to determine whether the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">StateMachine</a></span> is not in the
208
+ state specified by <code>state_name</code> at some point in the future.</p>
209
+ </div></span>
210
+
211
+ </li>
212
+
213
+
214
+ <li class="public ">
215
+ <span class="summary_signature">
216
+
217
+ <a href="#starts_as-instance_method" title="#starts_as (instance method)">#<strong>starts_as</strong>(initial_state_name) &#x21d2; StateMachine </a>
218
+
219
+
220
+
221
+ </span>
222
+
223
+
224
+
225
+
226
+
227
+
228
+
229
+
230
+
231
+ <span class="summary_desc"><div class='inline'>
232
+ <p>Put the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">StateMachine</a></span> into the state specified by
233
+ <code>initial_state_name</code>.</p>
234
+ </div></span>
235
+
236
+ </li>
237
+
238
+
239
+ </ul>
240
+
241
+
242
+
243
+
244
+ <div id="instance_method_details" class="method_details_list">
245
+ <h2>Instance Method Details</h2>
246
+
247
+
248
+ <div class="method_details first">
249
+ <h3 class="signature first" id="become-instance_method">
250
+
251
+ #<strong>become</strong>(next_state_name) &#x21d2; <tt><span class='object_link'>Object</span></tt>
252
+
253
+
254
+
255
+
256
+
257
+ </h3><div class="docstring">
258
+ <div class="discussion">
259
+
260
+ <p>Put the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">Mocha::StateMachine</a></span> into the <code>next_state_name</code>.</p>
261
+
262
+
263
+ </div>
264
+ </div>
265
+ <div class="tags">
266
+ <p class="tag_title">Parameters:</p>
267
+ <ul class="param">
268
+
269
+ <li>
270
+
271
+ <span class='name'>next_state_name</span>
272
+
273
+
274
+ <span class='type'>(<tt>String</tt>)</span>
275
+
276
+
277
+
278
+ &mdash;
279
+ <div class='inline'>
280
+ <p>name of new state</p>
281
+ </div>
282
+
283
+ </li>
284
+
285
+ </ul>
286
+
287
+
288
+ </div><table class="source_code">
289
+ <tr>
290
+ <td>
291
+ <pre class="lines">
292
+
293
+
294
+ 72
295
+ 73
296
+ 74</pre>
297
+ </td>
298
+ <td>
299
+ <pre class="code"><span class="info file"># File 'lib/mocha/state_machine.rb', line 72</span>
300
+
301
+ <span class='kw'>def</span> <span class='id identifier rubyid_become'>become</span><span class='lparen'>(</span><span class='id identifier rubyid_next_state_name'>next_state_name</span><span class='rparen'>)</span>
302
+ <span class='ivar'>@current_state</span> <span class='op'>=</span> <span class='id identifier rubyid_next_state_name'>next_state_name</span>
303
+ <span class='kw'>end</span></pre>
304
+ </td>
305
+ </tr>
306
+ </table>
307
+ </div>
308
+
309
+ <div class="method_details ">
310
+ <h3 class="signature " id="is-instance_method">
311
+
312
+ #<strong>is</strong>(state_name) &#x21d2; <tt><span class='object_link'><a href="StateMachine/State.html" title="Mocha::StateMachine::State (class)">State</a></span></tt>
313
+
314
+
315
+
316
+
317
+
318
+ </h3><div class="docstring">
319
+ <div class="discussion">
320
+
321
+ <p>Provides a mechanism to change the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">Mocha::StateMachine</a></span> into the state specified
322
+ by <code>state_name</code> at some point in the future.</p>
323
+
324
+ <p>Or provides a mechanism to determine whether the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">Mocha::StateMachine</a></span> is in the
325
+ state specified by <code>state_name</code> at some point in the future.</p>
326
+
327
+
328
+ </div>
329
+ </div>
330
+ <div class="tags">
331
+ <p class="tag_title">Parameters:</p>
332
+ <ul class="param">
333
+
334
+ <li>
335
+
336
+ <span class='name'>state_name</span>
337
+
338
+
339
+ <span class='type'>(<tt>String</tt>)</span>
340
+
341
+
342
+
343
+ &mdash;
344
+ <div class='inline'>
345
+ <p>name of new state</p>
346
+ </div>
347
+
348
+ </li>
349
+
350
+ </ul>
351
+
352
+ <p class="tag_title">Returns:</p>
353
+ <ul class="return">
354
+
355
+ <li>
356
+
357
+
358
+ <span class='type'>(<tt><span class='object_link'><a href="StateMachine/State.html" title="Mocha::StateMachine::State (class)">State</a></span></tt>)</span>
359
+
360
+
361
+
362
+ &mdash;
363
+ <div class='inline'>
364
+ <p>state which, when activated, will change the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">Mocha::StateMachine</a></span> into the state
365
+ with the specified <code>state_name</code>.</p>
366
+ </div>
367
+
368
+ </li>
369
+
370
+ </ul>
371
+
372
+ </div><table class="source_code">
373
+ <tr>
374
+ <td>
375
+ <pre class="lines">
376
+
377
+
378
+ 82
379
+ 83
380
+ 84</pre>
381
+ </td>
382
+ <td>
383
+ <pre class="code"><span class="info file"># File 'lib/mocha/state_machine.rb', line 82</span>
384
+
385
+ <span class='kw'>def</span> <span class='id identifier rubyid_is'>is</span><span class='lparen'>(</span><span class='id identifier rubyid_state_name'>state_name</span><span class='rparen'>)</span>
386
+ <span class='const'><span class='object_link'><a href="StateMachine/State.html" title="Mocha::StateMachine::State (class)">State</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id identifier rubyid_state_name'>state_name</span><span class='rparen'>)</span>
387
+ <span class='kw'>end</span></pre>
388
+ </td>
389
+ </tr>
390
+ </table>
391
+ </div>
392
+
393
+ <div class="method_details ">
394
+ <h3 class="signature " id="is_not-instance_method">
395
+
396
+ #<strong>is_not</strong>(state_name) &#x21d2; <tt><span class='object_link'>Object</span></tt>
397
+
398
+
399
+
400
+
401
+
402
+ </h3><div class="docstring">
403
+ <div class="discussion">
404
+
405
+ <p>Provides a mechanism to determine whether the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">Mocha::StateMachine</a></span> is not in the
406
+ state specified by <code>state_name</code> at some point in the future.
407
+ rubocop:disable Naming/PredicateName</p>
408
+
409
+
410
+ </div>
411
+ </div>
412
+ <div class="tags">
413
+
414
+
415
+ </div><table class="source_code">
416
+ <tr>
417
+ <td>
418
+ <pre class="lines">
419
+
420
+
421
+ 88
422
+ 89
423
+ 90</pre>
424
+ </td>
425
+ <td>
426
+ <pre class="code"><span class="info file"># File 'lib/mocha/state_machine.rb', line 88</span>
427
+
428
+ <span class='kw'>def</span> <span class='id identifier rubyid_is_not'>is_not</span><span class='lparen'>(</span><span class='id identifier rubyid_state_name'>state_name</span><span class='rparen'>)</span>
429
+ <span class='const'><span class='object_link'><a href="StateMachine/StatePredicate.html" title="Mocha::StateMachine::StatePredicate (class)">StatePredicate</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id identifier rubyid_state_name'>state_name</span><span class='rparen'>)</span>
430
+ <span class='kw'>end</span></pre>
431
+ </td>
432
+ </tr>
433
+ </table>
434
+ </div>
435
+
436
+ <div class="method_details ">
437
+ <h3 class="signature " id="starts_as-instance_method">
438
+
439
+ #<strong>starts_as</strong>(initial_state_name) &#x21d2; <tt><span class='object_link'><a href="" title="Mocha::StateMachine (class)">StateMachine</a></span></tt>
440
+
441
+
442
+
443
+
444
+
445
+ </h3><div class="docstring">
446
+ <div class="discussion">
447
+
448
+ <p>Put the <span class='object_link'><a href="" title="Mocha::StateMachine (class)">Mocha::StateMachine</a></span> into the state specified by
449
+ <code>initial_state_name</code>.</p>
450
+
451
+
452
+ </div>
453
+ </div>
454
+ <div class="tags">
455
+ <p class="tag_title">Parameters:</p>
456
+ <ul class="param">
457
+
458
+ <li>
459
+
460
+ <span class='name'>initial_state_name</span>
461
+
462
+
463
+ <span class='type'>(<tt>String</tt>)</span>
464
+
465
+
466
+
467
+ &mdash;
468
+ <div class='inline'>
469
+ <p>name of initial state</p>
470
+ </div>
471
+
472
+ </li>
473
+
474
+ </ul>
475
+
476
+ <p class="tag_title">Returns:</p>
477
+ <ul class="return">
478
+
479
+ <li>
480
+
481
+
482
+ <span class='type'>(<tt><span class='object_link'><a href="" title="Mocha::StateMachine (class)">StateMachine</a></span></tt>)</span>
483
+
484
+
485
+
486
+ &mdash;
487
+ <div class='inline'>
488
+ <p>state machine, thereby allowing invocations of other <span class='object_link'><a href="" title="Mocha::StateMachine (class)">Mocha::StateMachine</a></span> methods
489
+ to be chained.</p>
490
+ </div>
491
+
492
+ </li>
493
+
494
+ </ul>
495
+
496
+ </div><table class="source_code">
497
+ <tr>
498
+ <td>
499
+ <pre class="lines">
500
+
501
+
502
+ 64
503
+ 65
504
+ 66
505
+ 67</pre>
506
+ </td>
507
+ <td>
508
+ <pre class="code"><span class="info file"># File 'lib/mocha/state_machine.rb', line 64</span>
509
+
510
+ <span class='kw'>def</span> <span class='id identifier rubyid_starts_as'>starts_as</span><span class='lparen'>(</span><span class='id identifier rubyid_initial_state_name'>initial_state_name</span><span class='rparen'>)</span>
511
+ <span class='id identifier rubyid_become'>become</span><span class='lparen'>(</span><span class='id identifier rubyid_initial_state_name'>initial_state_name</span><span class='rparen'>)</span>
512
+ <span class='kw'>self</span>
513
+ <span class='kw'>end</span></pre>
514
+ </td>
515
+ </tr>
516
+ </table>
517
+ </div>
518
+
519
+ </div>
520
+
521
+ <script async src="https://www.googletagmanager.com/gtag/js?id=UA-625523-7"></script>
522
+ <script>
523
+ window.dataLayer = window.dataLayer || [];
524
+ function gtag(){dataLayer.push(arguments);}
525
+ gtag('js', new Date());
526
+
527
+ gtag('config', 'UA-625523-7');
528
+ </script>
529
+ </div>
530
+
531
+ <div id="footer">
532
+ Generated on Tue Jan 15 17:13:06 2019 by
533
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
534
+ 0.9.16 (ruby-2.5.3).
535
+ </div>
536
+
537
+ </div>
538
+ </body>
539
+ </html>