automate_soup 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +15 -0
- data/.rspec +2 -0
- data/.travis.yml +5 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +6 -0
- data/LICENSE.txt +21 -0
- data/README.md +128 -0
- data/Rakefile +10 -0
- data/automate_soup.gemspec +31 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/docs/AutomateSoup.html +2566 -0
- data/docs/AutomateSoup/API.html +1174 -0
- data/docs/AutomateSoup/Change.html +892 -0
- data/docs/AutomateSoup/Credentials.html +452 -0
- data/docs/AutomateSoup/Rest.html +321 -0
- data/docs/AutomateSoup/Stage.html +428 -0
- data/docs/AutomateSoup/Topic.html +530 -0
- data/docs/_index.html +166 -0
- data/docs/class_list.html +51 -0
- data/docs/coverage/.last_run.json +5 -0
- data/docs/coverage/.resultset.json +145 -0
- data/docs/coverage/.resultset.json.lock +0 -0
- data/docs/coverage/assets/0.10.2/application.css +799 -0
- data/docs/coverage/assets/0.10.2/application.js +1707 -0
- data/docs/coverage/assets/0.10.2/colorbox/border.png +0 -0
- data/docs/coverage/assets/0.10.2/colorbox/controls.png +0 -0
- data/docs/coverage/assets/0.10.2/colorbox/loading.gif +0 -0
- data/docs/coverage/assets/0.10.2/colorbox/loading_background.png +0 -0
- data/docs/coverage/assets/0.10.2/favicon_green.png +0 -0
- data/docs/coverage/assets/0.10.2/favicon_red.png +0 -0
- data/docs/coverage/assets/0.10.2/favicon_yellow.png +0 -0
- data/docs/coverage/assets/0.10.2/loading.gif +0 -0
- data/docs/coverage/assets/0.10.2/magnify.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-icons_222222_256x240.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-icons_2e83ff_256x240.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-icons_454545_256x240.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-icons_888888_256x240.png +0 -0
- data/docs/coverage/assets/0.10.2/smoothness/images/ui-icons_cd0a0a_256x240.png +0 -0
- data/docs/coverage/index.html +968 -0
- data/docs/css/common.css +1 -0
- data/docs/css/full_list.css +58 -0
- data/docs/css/style.css +492 -0
- data/docs/file.README.html +211 -0
- data/docs/file_list.html +56 -0
- data/docs/frames.html +17 -0
- data/docs/index.html +211 -0
- data/docs/js/app.js +248 -0
- data/docs/js/full_list.js +216 -0
- data/docs/js/jquery.js +4 -0
- data/docs/method_list.html +395 -0
- data/docs/top-level-namespace.html +110 -0
- data/lib/automate_soup.rb +264 -0
- data/lib/automate_soup/api.rb +112 -0
- data/lib/automate_soup/change.rb +105 -0
- data/lib/automate_soup/credentials.rb +16 -0
- data/lib/automate_soup/rest.rb +40 -0
- data/lib/automate_soup/stage.rb +25 -0
- data/lib/automate_soup/version.rb +3 -0
- metadata +195 -0
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -0,0 +1,968 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html xmlns='http://www.w3.org/1999/xhtml'>
|
3
|
+
<head>
|
4
|
+
<title>Code coverage for Automate soup</title>
|
5
|
+
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
6
|
+
<script src='./assets/0.10.2/application.js' type='text/javascript'></script>
|
7
|
+
<link href='./assets/0.10.2/application.css' media='screen, projection, print' rel='stylesheet' type='text/css'>
|
8
|
+
<link rel="shortcut icon" type="image/png" href="./assets/0.10.2/favicon_green.png" />
|
9
|
+
<link rel="icon" type="image/png" href="./assets/0.10.2/favicon.png" />
|
10
|
+
</head>
|
11
|
+
|
12
|
+
<body>
|
13
|
+
<div id="loading">
|
14
|
+
<img src="./assets/0.10.2/loading.gif" alt="loading"/>
|
15
|
+
</div>
|
16
|
+
<div id="wrapper" style="display:none;">
|
17
|
+
<div class="timestamp">Generated <abbr class="timeago" title="2017-12-18T14:46:34-05:00">2017-12-18T14:46:34-05:00</abbr></div>
|
18
|
+
<ul class="group_tabs"></ul>
|
19
|
+
|
20
|
+
<div id="content">
|
21
|
+
<div class="file_list_container" id="AllFiles">
|
22
|
+
<h2>
|
23
|
+
<span class="group_name">All Files</span>
|
24
|
+
(<span class="covered_percent"><span class="green">96.88%</span></span>
|
25
|
+
covered at
|
26
|
+
<span class="covered_strength">
|
27
|
+
<span class="red">
|
28
|
+
0.96
|
29
|
+
</span>
|
30
|
+
</span> hits/line)
|
31
|
+
</h2>
|
32
|
+
<a name="AllFiles"></a>
|
33
|
+
<div>
|
34
|
+
<b>4</b> files in total.
|
35
|
+
<b>64</b> relevant lines.
|
36
|
+
<span class="green"><b>62</b> lines covered</span> and
|
37
|
+
<span class="red"><b>2</b> lines missed </span>
|
38
|
+
</div>
|
39
|
+
<table class="file_list">
|
40
|
+
<thead>
|
41
|
+
<tr>
|
42
|
+
<th>File</th>
|
43
|
+
<th>% covered</th>
|
44
|
+
<th>Lines</th>
|
45
|
+
<th>Relevant Lines</th>
|
46
|
+
<th>Lines covered</th>
|
47
|
+
<th>Lines missed</th>
|
48
|
+
<th>Avg. Hits / Line</th>
|
49
|
+
</tr>
|
50
|
+
</thead>
|
51
|
+
<tbody>
|
52
|
+
|
53
|
+
<tr>
|
54
|
+
<td class="strong"><a href="#3fd135936187c2e5c0ccd53773608009f1bd2584" class="src_link" title="spec/automate_soup_change_spec.rb">spec/automate_soup_change_spec.rb</a></td>
|
55
|
+
<td class="green strong">92.0 %</td>
|
56
|
+
<td>47</td>
|
57
|
+
<td>25</td>
|
58
|
+
<td>23</td>
|
59
|
+
<td>2</td>
|
60
|
+
<td>0.9</td>
|
61
|
+
</tr>
|
62
|
+
|
63
|
+
<tr>
|
64
|
+
<td class="strong"><a href="#216228a0fcbde3a6b1949b54f0b4e4cb506898a0" class="src_link" title="spec/automate_soup_credentials_spec.rb">spec/automate_soup_credentials_spec.rb</a></td>
|
65
|
+
<td class="green strong">100.0 %</td>
|
66
|
+
<td>19</td>
|
67
|
+
<td>8</td>
|
68
|
+
<td>8</td>
|
69
|
+
<td>0</td>
|
70
|
+
<td>1.0</td>
|
71
|
+
</tr>
|
72
|
+
|
73
|
+
<tr>
|
74
|
+
<td class="strong"><a href="#511a4eb55baf75c36394e69b0646f925720842f5" class="src_link" title="spec/automate_soup_spec.rb">spec/automate_soup_spec.rb</a></td>
|
75
|
+
<td class="green strong">100.0 %</td>
|
76
|
+
<td>25</td>
|
77
|
+
<td>10</td>
|
78
|
+
<td>10</td>
|
79
|
+
<td>0</td>
|
80
|
+
<td>1.0</td>
|
81
|
+
</tr>
|
82
|
+
|
83
|
+
<tr>
|
84
|
+
<td class="strong"><a href="#15f71dc668a2e8aab0a1ce3f352d75a12193a92d" class="src_link" title="spec/automate_soup_stage_spec.rb">spec/automate_soup_stage_spec.rb</a></td>
|
85
|
+
<td class="green strong">100.0 %</td>
|
86
|
+
<td>39</td>
|
87
|
+
<td>21</td>
|
88
|
+
<td>21</td>
|
89
|
+
<td>0</td>
|
90
|
+
<td>1.0</td>
|
91
|
+
</tr>
|
92
|
+
|
93
|
+
</tbody>
|
94
|
+
</table>
|
95
|
+
</div>
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
</div>
|
100
|
+
|
101
|
+
<div id="footer">
|
102
|
+
Generated by <a href="http://github.com/colszowka/simplecov">simplecov</a> v0.15.0
|
103
|
+
and simplecov-html v0.10.2<br/>
|
104
|
+
using RSpec
|
105
|
+
</div>
|
106
|
+
|
107
|
+
<div class="source_files">
|
108
|
+
|
109
|
+
<div class="source_table" id="3fd135936187c2e5c0ccd53773608009f1bd2584">
|
110
|
+
<div class="header">
|
111
|
+
<h3>spec/automate_soup_change_spec.rb</h3>
|
112
|
+
<h4><span class="green">92.0 %</span> covered</h4>
|
113
|
+
<div>
|
114
|
+
<b>25</b> relevant lines.
|
115
|
+
<span class="green"><b>23</b> lines covered</span> and
|
116
|
+
<span class="red"><b>2</b> lines missed.</span>
|
117
|
+
</div>
|
118
|
+
</div>
|
119
|
+
|
120
|
+
<pre>
|
121
|
+
<ol>
|
122
|
+
|
123
|
+
<li class="covered" data-hits="1" data-linenumber="1">
|
124
|
+
<span class="hits">1</span>
|
125
|
+
|
126
|
+
<code class="ruby">require 'spec_helper'</code>
|
127
|
+
</li>
|
128
|
+
|
129
|
+
<li class="never" data-hits="" data-linenumber="2">
|
130
|
+
|
131
|
+
|
132
|
+
<code class="ruby"></code>
|
133
|
+
</li>
|
134
|
+
|
135
|
+
<li class="covered" data-hits="1" data-linenumber="3">
|
136
|
+
<span class="hits">1</span>
|
137
|
+
|
138
|
+
<code class="ruby">RSpec.describe AutomateSoup::Change do</code>
|
139
|
+
</li>
|
140
|
+
|
141
|
+
<li class="covered" data-hits="1" data-linenumber="4">
|
142
|
+
<span class="hits">1</span>
|
143
|
+
|
144
|
+
<code class="ruby"> before(:all) do</code>
|
145
|
+
</li>
|
146
|
+
|
147
|
+
<li class="covered" data-hits="1" data-linenumber="5">
|
148
|
+
<span class="hits">1</span>
|
149
|
+
|
150
|
+
<code class="ruby"> @organization = ENV['AUTOMATE_ORG'] || 'test'</code>
|
151
|
+
</li>
|
152
|
+
|
153
|
+
<li class="covered" data-hits="1" data-linenumber="6">
|
154
|
+
<span class="hits">1</span>
|
155
|
+
|
156
|
+
<code class="ruby"> @project = ENV['AUTOMATE_PROJECT'] || 'coffee_docker'</code>
|
157
|
+
</li>
|
158
|
+
|
159
|
+
<li class="covered" data-hits="1" data-linenumber="7">
|
160
|
+
<span class="hits">1</span>
|
161
|
+
|
162
|
+
<code class="ruby"> @pipeline = ENV['AUTOMATE_PIPELINE'] || 'master'</code>
|
163
|
+
</li>
|
164
|
+
|
165
|
+
<li class="covered" data-hits="1" data-linenumber="8">
|
166
|
+
<span class="hits">1</span>
|
167
|
+
|
168
|
+
<code class="ruby"> @soup = AutomateSoup.setup(</code>
|
169
|
+
</li>
|
170
|
+
|
171
|
+
<li class="never" data-hits="" data-linenumber="9">
|
172
|
+
|
173
|
+
|
174
|
+
<code class="ruby"> url: ENV['AUTOMATE_URL'],</code>
|
175
|
+
</li>
|
176
|
+
|
177
|
+
<li class="never" data-hits="" data-linenumber="10">
|
178
|
+
|
179
|
+
|
180
|
+
<code class="ruby"> username: ENV['AUTOMATE_USERNAME'],</code>
|
181
|
+
</li>
|
182
|
+
|
183
|
+
<li class="never" data-hits="" data-linenumber="11">
|
184
|
+
|
185
|
+
|
186
|
+
<code class="ruby"> token: ENV['AUTOMATE_TOKEN'],</code>
|
187
|
+
</li>
|
188
|
+
|
189
|
+
<li class="never" data-hits="" data-linenumber="12">
|
190
|
+
|
191
|
+
|
192
|
+
<code class="ruby"> organization: @organization,</code>
|
193
|
+
</li>
|
194
|
+
|
195
|
+
<li class="never" data-hits="" data-linenumber="13">
|
196
|
+
|
197
|
+
|
198
|
+
<code class="ruby"> project: @project,</code>
|
199
|
+
</li>
|
200
|
+
|
201
|
+
<li class="never" data-hits="" data-linenumber="14">
|
202
|
+
|
203
|
+
|
204
|
+
<code class="ruby"> pipeline: @pipeline</code>
|
205
|
+
</li>
|
206
|
+
|
207
|
+
<li class="never" data-hits="" data-linenumber="15">
|
208
|
+
|
209
|
+
|
210
|
+
<code class="ruby"> )</code>
|
211
|
+
</li>
|
212
|
+
|
213
|
+
<li class="covered" data-hits="1" data-linenumber="16">
|
214
|
+
<span class="hits">1</span>
|
215
|
+
|
216
|
+
<code class="ruby"> @topic = @soup.change_by_topic(</code>
|
217
|
+
</li>
|
218
|
+
|
219
|
+
<li class="never" data-hits="" data-linenumber="17">
|
220
|
+
|
221
|
+
|
222
|
+
<code class="ruby"> topic: 'foobarbaz'</code>
|
223
|
+
</li>
|
224
|
+
|
225
|
+
<li class="never" data-hits="" data-linenumber="18">
|
226
|
+
|
227
|
+
|
228
|
+
<code class="ruby"> )</code>
|
229
|
+
</li>
|
230
|
+
|
231
|
+
<li class="never" data-hits="" data-linenumber="19">
|
232
|
+
|
233
|
+
|
234
|
+
<code class="ruby"> end</code>
|
235
|
+
</li>
|
236
|
+
|
237
|
+
<li class="never" data-hits="" data-linenumber="20">
|
238
|
+
|
239
|
+
|
240
|
+
<code class="ruby"></code>
|
241
|
+
</li>
|
242
|
+
|
243
|
+
<li class="covered" data-hits="1" data-linenumber="21">
|
244
|
+
<span class="hits">1</span>
|
245
|
+
|
246
|
+
<code class="ruby"> it 'should determine the topic stage' do</code>
|
247
|
+
</li>
|
248
|
+
|
249
|
+
<li class="covered" data-hits="1" data-linenumber="22">
|
250
|
+
<span class="hits">1</span>
|
251
|
+
|
252
|
+
<code class="ruby"> stage = @topic.current_stage</code>
|
253
|
+
</li>
|
254
|
+
|
255
|
+
<li class="covered" data-hits="1" data-linenumber="23">
|
256
|
+
<span class="hits">1</span>
|
257
|
+
|
258
|
+
<code class="ruby"> expect(stage).not_to be nil</code>
|
259
|
+
</li>
|
260
|
+
|
261
|
+
<li class="never" data-hits="" data-linenumber="24">
|
262
|
+
|
263
|
+
|
264
|
+
<code class="ruby"> end</code>
|
265
|
+
</li>
|
266
|
+
|
267
|
+
<li class="never" data-hits="" data-linenumber="25">
|
268
|
+
|
269
|
+
|
270
|
+
<code class="ruby"></code>
|
271
|
+
</li>
|
272
|
+
|
273
|
+
<li class="covered" data-hits="1" data-linenumber="26">
|
274
|
+
<span class="hits">1</span>
|
275
|
+
|
276
|
+
<code class="ruby"> it 'should approve a change or return nil if it cannot' do</code>
|
277
|
+
</li>
|
278
|
+
|
279
|
+
<li class="covered" data-hits="1" data-linenumber="27">
|
280
|
+
<span class="hits">1</span>
|
281
|
+
|
282
|
+
<code class="ruby"> topic = @topic</code>
|
283
|
+
</li>
|
284
|
+
|
285
|
+
<li class="covered" data-hits="1" data-linenumber="28">
|
286
|
+
<span class="hits">1</span>
|
287
|
+
|
288
|
+
<code class="ruby"> approve = topic.approve</code>
|
289
|
+
</li>
|
290
|
+
|
291
|
+
<li class="covered" data-hits="1" data-linenumber="29">
|
292
|
+
<span class="hits">1</span>
|
293
|
+
|
294
|
+
<code class="ruby"> if approve.nil?</code>
|
295
|
+
</li>
|
296
|
+
|
297
|
+
<li class="covered" data-hits="1" data-linenumber="30">
|
298
|
+
<span class="hits">1</span>
|
299
|
+
|
300
|
+
<code class="ruby"> expect(topic.current_stage.stage).not_to be nil</code>
|
301
|
+
</li>
|
302
|
+
|
303
|
+
<li class="covered" data-hits="1" data-linenumber="31">
|
304
|
+
<span class="hits">1</span>
|
305
|
+
|
306
|
+
<code class="ruby"> expect(topic.current_stage.stage).not_to eql 'approve'</code>
|
307
|
+
</li>
|
308
|
+
|
309
|
+
<li class="never" data-hits="" data-linenumber="32">
|
310
|
+
|
311
|
+
|
312
|
+
<code class="ruby"> else</code>
|
313
|
+
</li>
|
314
|
+
|
315
|
+
<li class="missed" data-hits="0" data-linenumber="33">
|
316
|
+
|
317
|
+
|
318
|
+
<code class="ruby"> expect(approve).to be true</code>
|
319
|
+
</li>
|
320
|
+
|
321
|
+
<li class="never" data-hits="" data-linenumber="34">
|
322
|
+
|
323
|
+
|
324
|
+
<code class="ruby"> end</code>
|
325
|
+
</li>
|
326
|
+
|
327
|
+
<li class="never" data-hits="" data-linenumber="35">
|
328
|
+
|
329
|
+
|
330
|
+
<code class="ruby"> end</code>
|
331
|
+
</li>
|
332
|
+
|
333
|
+
<li class="never" data-hits="" data-linenumber="36">
|
334
|
+
|
335
|
+
|
336
|
+
<code class="ruby"></code>
|
337
|
+
</li>
|
338
|
+
|
339
|
+
<li class="covered" data-hits="1" data-linenumber="37">
|
340
|
+
<span class="hits">1</span>
|
341
|
+
|
342
|
+
<code class="ruby"> it 'should deliver a change or return nil if it cannot' do</code>
|
343
|
+
</li>
|
344
|
+
|
345
|
+
<li class="covered" data-hits="1" data-linenumber="38">
|
346
|
+
<span class="hits">1</span>
|
347
|
+
|
348
|
+
<code class="ruby"> topic = @topic</code>
|
349
|
+
</li>
|
350
|
+
|
351
|
+
<li class="covered" data-hits="1" data-linenumber="39">
|
352
|
+
<span class="hits">1</span>
|
353
|
+
|
354
|
+
<code class="ruby"> deliver = topic.deliver</code>
|
355
|
+
</li>
|
356
|
+
|
357
|
+
<li class="covered" data-hits="1" data-linenumber="40">
|
358
|
+
<span class="hits">1</span>
|
359
|
+
|
360
|
+
<code class="ruby"> if deliver.nil?</code>
|
361
|
+
</li>
|
362
|
+
|
363
|
+
<li class="covered" data-hits="1" data-linenumber="41">
|
364
|
+
<span class="hits">1</span>
|
365
|
+
|
366
|
+
<code class="ruby"> expect(topic.current_stage.stage).not_to be nil</code>
|
367
|
+
</li>
|
368
|
+
|
369
|
+
<li class="covered" data-hits="1" data-linenumber="42">
|
370
|
+
<span class="hits">1</span>
|
371
|
+
|
372
|
+
<code class="ruby"> expect(topic.current_stage.stage).not_to eql 'approve'</code>
|
373
|
+
</li>
|
374
|
+
|
375
|
+
<li class="never" data-hits="" data-linenumber="43">
|
376
|
+
|
377
|
+
|
378
|
+
<code class="ruby"> else</code>
|
379
|
+
</li>
|
380
|
+
|
381
|
+
<li class="missed" data-hits="0" data-linenumber="44">
|
382
|
+
|
383
|
+
|
384
|
+
<code class="ruby"> expect(deliver).to be true</code>
|
385
|
+
</li>
|
386
|
+
|
387
|
+
<li class="never" data-hits="" data-linenumber="45">
|
388
|
+
|
389
|
+
|
390
|
+
<code class="ruby"> end</code>
|
391
|
+
</li>
|
392
|
+
|
393
|
+
<li class="never" data-hits="" data-linenumber="46">
|
394
|
+
|
395
|
+
|
396
|
+
<code class="ruby"> end</code>
|
397
|
+
</li>
|
398
|
+
|
399
|
+
<li class="never" data-hits="" data-linenumber="47">
|
400
|
+
|
401
|
+
|
402
|
+
<code class="ruby">end</code>
|
403
|
+
</li>
|
404
|
+
|
405
|
+
</ol>
|
406
|
+
</pre>
|
407
|
+
</div>
|
408
|
+
|
409
|
+
|
410
|
+
<div class="source_table" id="216228a0fcbde3a6b1949b54f0b4e4cb506898a0">
|
411
|
+
<div class="header">
|
412
|
+
<h3>spec/automate_soup_credentials_spec.rb</h3>
|
413
|
+
<h4><span class="green">100.0 %</span> covered</h4>
|
414
|
+
<div>
|
415
|
+
<b>8</b> relevant lines.
|
416
|
+
<span class="green"><b>8</b> lines covered</span> and
|
417
|
+
<span class="red"><b>0</b> lines missed.</span>
|
418
|
+
</div>
|
419
|
+
</div>
|
420
|
+
|
421
|
+
<pre>
|
422
|
+
<ol>
|
423
|
+
|
424
|
+
<li class="covered" data-hits="1" data-linenumber="1">
|
425
|
+
<span class="hits">1</span>
|
426
|
+
|
427
|
+
<code class="ruby">require 'spec_helper'</code>
|
428
|
+
</li>
|
429
|
+
|
430
|
+
<li class="never" data-hits="" data-linenumber="2">
|
431
|
+
|
432
|
+
|
433
|
+
<code class="ruby"></code>
|
434
|
+
</li>
|
435
|
+
|
436
|
+
<li class="covered" data-hits="1" data-linenumber="3">
|
437
|
+
<span class="hits">1</span>
|
438
|
+
|
439
|
+
<code class="ruby">RSpec.describe AutomateSoup::Credentials do</code>
|
440
|
+
</li>
|
441
|
+
|
442
|
+
<li class="covered" data-hits="1" data-linenumber="4">
|
443
|
+
<span class="hits">1</span>
|
444
|
+
|
445
|
+
<code class="ruby"> it 'creates credentials with username/password' do</code>
|
446
|
+
</li>
|
447
|
+
|
448
|
+
<li class="covered" data-hits="1" data-linenumber="5">
|
449
|
+
<span class="hits">1</span>
|
450
|
+
|
451
|
+
<code class="ruby"> creds = AutomateSoup::Credentials.new(</code>
|
452
|
+
</li>
|
453
|
+
|
454
|
+
<li class="never" data-hits="" data-linenumber="6">
|
455
|
+
|
456
|
+
|
457
|
+
<code class="ruby"> username: 'test',</code>
|
458
|
+
</li>
|
459
|
+
|
460
|
+
<li class="never" data-hits="" data-linenumber="7">
|
461
|
+
|
462
|
+
|
463
|
+
<code class="ruby"> password: 'test'</code>
|
464
|
+
</li>
|
465
|
+
|
466
|
+
<li class="never" data-hits="" data-linenumber="8">
|
467
|
+
|
468
|
+
|
469
|
+
<code class="ruby"> )</code>
|
470
|
+
</li>
|
471
|
+
|
472
|
+
<li class="covered" data-hits="1" data-linenumber="9">
|
473
|
+
<span class="hits">1</span>
|
474
|
+
|
475
|
+
<code class="ruby"> expect(creds).not_to be nil</code>
|
476
|
+
</li>
|
477
|
+
|
478
|
+
<li class="never" data-hits="" data-linenumber="10">
|
479
|
+
|
480
|
+
|
481
|
+
<code class="ruby"> end</code>
|
482
|
+
</li>
|
483
|
+
|
484
|
+
<li class="never" data-hits="" data-linenumber="11">
|
485
|
+
|
486
|
+
|
487
|
+
<code class="ruby"></code>
|
488
|
+
</li>
|
489
|
+
|
490
|
+
<li class="covered" data-hits="1" data-linenumber="12">
|
491
|
+
<span class="hits">1</span>
|
492
|
+
|
493
|
+
<code class="ruby"> it 'creates credentials with username/token' do</code>
|
494
|
+
</li>
|
495
|
+
|
496
|
+
<li class="covered" data-hits="1" data-linenumber="13">
|
497
|
+
<span class="hits">1</span>
|
498
|
+
|
499
|
+
<code class="ruby"> creds = AutomateSoup::Credentials.new(</code>
|
500
|
+
</li>
|
501
|
+
|
502
|
+
<li class="never" data-hits="" data-linenumber="14">
|
503
|
+
|
504
|
+
|
505
|
+
<code class="ruby"> username: 'test',</code>
|
506
|
+
</li>
|
507
|
+
|
508
|
+
<li class="never" data-hits="" data-linenumber="15">
|
509
|
+
|
510
|
+
|
511
|
+
<code class="ruby"> token: 'test'</code>
|
512
|
+
</li>
|
513
|
+
|
514
|
+
<li class="never" data-hits="" data-linenumber="16">
|
515
|
+
|
516
|
+
|
517
|
+
<code class="ruby"> )</code>
|
518
|
+
</li>
|
519
|
+
|
520
|
+
<li class="covered" data-hits="1" data-linenumber="17">
|
521
|
+
<span class="hits">1</span>
|
522
|
+
|
523
|
+
<code class="ruby"> expect(creds).not_to be nil</code>
|
524
|
+
</li>
|
525
|
+
|
526
|
+
<li class="never" data-hits="" data-linenumber="18">
|
527
|
+
|
528
|
+
|
529
|
+
<code class="ruby"> end</code>
|
530
|
+
</li>
|
531
|
+
|
532
|
+
<li class="never" data-hits="" data-linenumber="19">
|
533
|
+
|
534
|
+
|
535
|
+
<code class="ruby">end</code>
|
536
|
+
</li>
|
537
|
+
|
538
|
+
</ol>
|
539
|
+
</pre>
|
540
|
+
</div>
|
541
|
+
|
542
|
+
|
543
|
+
<div class="source_table" id="511a4eb55baf75c36394e69b0646f925720842f5">
|
544
|
+
<div class="header">
|
545
|
+
<h3>spec/automate_soup_spec.rb</h3>
|
546
|
+
<h4><span class="green">100.0 %</span> covered</h4>
|
547
|
+
<div>
|
548
|
+
<b>10</b> relevant lines.
|
549
|
+
<span class="green"><b>10</b> lines covered</span> and
|
550
|
+
<span class="red"><b>0</b> lines missed.</span>
|
551
|
+
</div>
|
552
|
+
</div>
|
553
|
+
|
554
|
+
<pre>
|
555
|
+
<ol>
|
556
|
+
|
557
|
+
<li class="covered" data-hits="1" data-linenumber="1">
|
558
|
+
<span class="hits">1</span>
|
559
|
+
|
560
|
+
<code class="ruby">require 'spec_helper'</code>
|
561
|
+
</li>
|
562
|
+
|
563
|
+
<li class="never" data-hits="" data-linenumber="2">
|
564
|
+
|
565
|
+
|
566
|
+
<code class="ruby"></code>
|
567
|
+
</li>
|
568
|
+
|
569
|
+
<li class="covered" data-hits="1" data-linenumber="3">
|
570
|
+
<span class="hits">1</span>
|
571
|
+
|
572
|
+
<code class="ruby">RSpec.describe AutomateSoup do</code>
|
573
|
+
</li>
|
574
|
+
|
575
|
+
<li class="covered" data-hits="1" data-linenumber="4">
|
576
|
+
<span class="hits">1</span>
|
577
|
+
|
578
|
+
<code class="ruby"> it 'has a version number' do</code>
|
579
|
+
</li>
|
580
|
+
|
581
|
+
<li class="covered" data-hits="1" data-linenumber="5">
|
582
|
+
<span class="hits">1</span>
|
583
|
+
|
584
|
+
<code class="ruby"> expect(AutomateSoup::VERSION).not_to be nil</code>
|
585
|
+
</li>
|
586
|
+
|
587
|
+
<li class="never" data-hits="" data-linenumber="6">
|
588
|
+
|
589
|
+
|
590
|
+
<code class="ruby"> end</code>
|
591
|
+
</li>
|
592
|
+
|
593
|
+
<li class="never" data-hits="" data-linenumber="7">
|
594
|
+
|
595
|
+
|
596
|
+
<code class="ruby"></code>
|
597
|
+
</li>
|
598
|
+
|
599
|
+
<li class="covered" data-hits="1" data-linenumber="8">
|
600
|
+
<span class="hits">1</span>
|
601
|
+
|
602
|
+
<code class="ruby"> it 'creates a new instance of AutomateSoup with password' do</code>
|
603
|
+
</li>
|
604
|
+
|
605
|
+
<li class="covered" data-hits="1" data-linenumber="9">
|
606
|
+
<span class="hits">1</span>
|
607
|
+
|
608
|
+
<code class="ruby"> soup = AutomateSoup.setup(</code>
|
609
|
+
</li>
|
610
|
+
|
611
|
+
<li class="never" data-hits="" data-linenumber="10">
|
612
|
+
|
613
|
+
|
614
|
+
<code class="ruby"> url: 'test',</code>
|
615
|
+
</li>
|
616
|
+
|
617
|
+
<li class="never" data-hits="" data-linenumber="11">
|
618
|
+
|
619
|
+
|
620
|
+
<code class="ruby"> username: 'test',</code>
|
621
|
+
</li>
|
622
|
+
|
623
|
+
<li class="never" data-hits="" data-linenumber="12">
|
624
|
+
|
625
|
+
|
626
|
+
<code class="ruby"> password: 'test'</code>
|
627
|
+
</li>
|
628
|
+
|
629
|
+
<li class="never" data-hits="" data-linenumber="13">
|
630
|
+
|
631
|
+
|
632
|
+
<code class="ruby"> )</code>
|
633
|
+
</li>
|
634
|
+
|
635
|
+
<li class="covered" data-hits="1" data-linenumber="14">
|
636
|
+
<span class="hits">1</span>
|
637
|
+
|
638
|
+
<code class="ruby"> expect(soup).not_to be nil</code>
|
639
|
+
</li>
|
640
|
+
|
641
|
+
<li class="never" data-hits="" data-linenumber="15">
|
642
|
+
|
643
|
+
|
644
|
+
<code class="ruby"> end</code>
|
645
|
+
</li>
|
646
|
+
|
647
|
+
<li class="never" data-hits="" data-linenumber="16">
|
648
|
+
|
649
|
+
|
650
|
+
<code class="ruby"></code>
|
651
|
+
</li>
|
652
|
+
|
653
|
+
<li class="covered" data-hits="1" data-linenumber="17">
|
654
|
+
<span class="hits">1</span>
|
655
|
+
|
656
|
+
<code class="ruby"> it 'creates a new instance of AutomateSoup with token' do</code>
|
657
|
+
</li>
|
658
|
+
|
659
|
+
<li class="covered" data-hits="1" data-linenumber="18">
|
660
|
+
<span class="hits">1</span>
|
661
|
+
|
662
|
+
<code class="ruby"> soup = AutomateSoup.setup(</code>
|
663
|
+
</li>
|
664
|
+
|
665
|
+
<li class="never" data-hits="" data-linenumber="19">
|
666
|
+
|
667
|
+
|
668
|
+
<code class="ruby"> url: 'test',</code>
|
669
|
+
</li>
|
670
|
+
|
671
|
+
<li class="never" data-hits="" data-linenumber="20">
|
672
|
+
|
673
|
+
|
674
|
+
<code class="ruby"> username: 'test',</code>
|
675
|
+
</li>
|
676
|
+
|
677
|
+
<li class="never" data-hits="" data-linenumber="21">
|
678
|
+
|
679
|
+
|
680
|
+
<code class="ruby"> token: 'test'</code>
|
681
|
+
</li>
|
682
|
+
|
683
|
+
<li class="never" data-hits="" data-linenumber="22">
|
684
|
+
|
685
|
+
|
686
|
+
<code class="ruby"> )</code>
|
687
|
+
</li>
|
688
|
+
|
689
|
+
<li class="covered" data-hits="1" data-linenumber="23">
|
690
|
+
<span class="hits">1</span>
|
691
|
+
|
692
|
+
<code class="ruby"> expect(soup).not_to be nil</code>
|
693
|
+
</li>
|
694
|
+
|
695
|
+
<li class="never" data-hits="" data-linenumber="24">
|
696
|
+
|
697
|
+
|
698
|
+
<code class="ruby"> end</code>
|
699
|
+
</li>
|
700
|
+
|
701
|
+
<li class="never" data-hits="" data-linenumber="25">
|
702
|
+
|
703
|
+
|
704
|
+
<code class="ruby">end</code>
|
705
|
+
</li>
|
706
|
+
|
707
|
+
</ol>
|
708
|
+
</pre>
|
709
|
+
</div>
|
710
|
+
|
711
|
+
|
712
|
+
<div class="source_table" id="15f71dc668a2e8aab0a1ce3f352d75a12193a92d">
|
713
|
+
<div class="header">
|
714
|
+
<h3>spec/automate_soup_stage_spec.rb</h3>
|
715
|
+
<h4><span class="green">100.0 %</span> covered</h4>
|
716
|
+
<div>
|
717
|
+
<b>21</b> relevant lines.
|
718
|
+
<span class="green"><b>21</b> lines covered</span> and
|
719
|
+
<span class="red"><b>0</b> lines missed.</span>
|
720
|
+
</div>
|
721
|
+
</div>
|
722
|
+
|
723
|
+
<pre>
|
724
|
+
<ol>
|
725
|
+
|
726
|
+
<li class="covered" data-hits="1" data-linenumber="1">
|
727
|
+
<span class="hits">1</span>
|
728
|
+
|
729
|
+
<code class="ruby">require 'spec_helper'</code>
|
730
|
+
</li>
|
731
|
+
|
732
|
+
<li class="never" data-hits="" data-linenumber="2">
|
733
|
+
|
734
|
+
|
735
|
+
<code class="ruby"></code>
|
736
|
+
</li>
|
737
|
+
|
738
|
+
<li class="covered" data-hits="1" data-linenumber="3">
|
739
|
+
<span class="hits">1</span>
|
740
|
+
|
741
|
+
<code class="ruby">RSpec.describe AutomateSoup::Stage do</code>
|
742
|
+
</li>
|
743
|
+
|
744
|
+
<li class="covered" data-hits="1" data-linenumber="4">
|
745
|
+
<span class="hits">1</span>
|
746
|
+
|
747
|
+
<code class="ruby"> before(:all) do</code>
|
748
|
+
</li>
|
749
|
+
|
750
|
+
<li class="covered" data-hits="1" data-linenumber="5">
|
751
|
+
<span class="hits">1</span>
|
752
|
+
|
753
|
+
<code class="ruby"> @soup = AutomateSoup.setup(</code>
|
754
|
+
</li>
|
755
|
+
|
756
|
+
<li class="never" data-hits="" data-linenumber="6">
|
757
|
+
|
758
|
+
|
759
|
+
<code class="ruby"> url: ENV['AUTOMATE_URL'],</code>
|
760
|
+
</li>
|
761
|
+
|
762
|
+
<li class="never" data-hits="" data-linenumber="7">
|
763
|
+
|
764
|
+
|
765
|
+
<code class="ruby"> username: ENV['AUTOMATE_USERNAME'],</code>
|
766
|
+
</li>
|
767
|
+
|
768
|
+
<li class="never" data-hits="" data-linenumber="8">
|
769
|
+
|
770
|
+
|
771
|
+
<code class="ruby"> token: ENV['AUTOMATE_TOKEN']</code>
|
772
|
+
</li>
|
773
|
+
|
774
|
+
<li class="never" data-hits="" data-linenumber="9">
|
775
|
+
|
776
|
+
|
777
|
+
<code class="ruby"> )</code>
|
778
|
+
</li>
|
779
|
+
|
780
|
+
<li class="covered" data-hits="1" data-linenumber="10">
|
781
|
+
<span class="hits">1</span>
|
782
|
+
|
783
|
+
<code class="ruby"> @organization = ENV['AUTOMATE_ORG'] || 'test'</code>
|
784
|
+
</li>
|
785
|
+
|
786
|
+
<li class="covered" data-hits="1" data-linenumber="11">
|
787
|
+
<span class="hits">1</span>
|
788
|
+
|
789
|
+
<code class="ruby"> @project = ENV['AUTOMATE_PROJECT'] || 'coffee_docker'</code>
|
790
|
+
</li>
|
791
|
+
|
792
|
+
<li class="covered" data-hits="1" data-linenumber="12">
|
793
|
+
<span class="hits">1</span>
|
794
|
+
|
795
|
+
<code class="ruby"> @pipeline = ENV['AUTOMATE_PIPELINE'] || 'master'</code>
|
796
|
+
</li>
|
797
|
+
|
798
|
+
<li class="covered" data-hits="1" data-linenumber="13">
|
799
|
+
<span class="hits">1</span>
|
800
|
+
|
801
|
+
<code class="ruby"> @topic = @soup.change_by_topic(</code>
|
802
|
+
</li>
|
803
|
+
|
804
|
+
<li class="never" data-hits="" data-linenumber="14">
|
805
|
+
|
806
|
+
|
807
|
+
<code class="ruby"> organization: @organization,</code>
|
808
|
+
</li>
|
809
|
+
|
810
|
+
<li class="never" data-hits="" data-linenumber="15">
|
811
|
+
|
812
|
+
|
813
|
+
<code class="ruby"> project: @project,</code>
|
814
|
+
</li>
|
815
|
+
|
816
|
+
<li class="never" data-hits="" data-linenumber="16">
|
817
|
+
|
818
|
+
|
819
|
+
<code class="ruby"> pipeline: @pipeline,</code>
|
820
|
+
</li>
|
821
|
+
|
822
|
+
<li class="never" data-hits="" data-linenumber="17">
|
823
|
+
|
824
|
+
|
825
|
+
<code class="ruby"> topic: 'foobarbaz'</code>
|
826
|
+
</li>
|
827
|
+
|
828
|
+
<li class="never" data-hits="" data-linenumber="18">
|
829
|
+
|
830
|
+
|
831
|
+
<code class="ruby"> )</code>
|
832
|
+
</li>
|
833
|
+
|
834
|
+
<li class="never" data-hits="" data-linenumber="19">
|
835
|
+
|
836
|
+
|
837
|
+
<code class="ruby"> end</code>
|
838
|
+
</li>
|
839
|
+
|
840
|
+
<li class="never" data-hits="" data-linenumber="20">
|
841
|
+
|
842
|
+
|
843
|
+
<code class="ruby"></code>
|
844
|
+
</li>
|
845
|
+
|
846
|
+
<li class="covered" data-hits="1" data-linenumber="21">
|
847
|
+
<span class="hits">1</span>
|
848
|
+
|
849
|
+
<code class="ruby"> it 'should determine the status of the current stage' do</code>
|
850
|
+
</li>
|
851
|
+
|
852
|
+
<li class="covered" data-hits="1" data-linenumber="22">
|
853
|
+
<span class="hits">1</span>
|
854
|
+
|
855
|
+
<code class="ruby"> stage = @topic.current_stage</code>
|
856
|
+
</li>
|
857
|
+
|
858
|
+
<li class="covered" data-hits="1" data-linenumber="23">
|
859
|
+
<span class="hits">1</span>
|
860
|
+
|
861
|
+
<code class="ruby"> expect(stage.status).not_to be nil</code>
|
862
|
+
</li>
|
863
|
+
|
864
|
+
<li class="never" data-hits="" data-linenumber="24">
|
865
|
+
|
866
|
+
|
867
|
+
<code class="ruby"> end</code>
|
868
|
+
</li>
|
869
|
+
|
870
|
+
<li class="never" data-hits="" data-linenumber="25">
|
871
|
+
|
872
|
+
|
873
|
+
<code class="ruby"></code>
|
874
|
+
</li>
|
875
|
+
|
876
|
+
<li class="covered" data-hits="1" data-linenumber="26">
|
877
|
+
<span class="hits">1</span>
|
878
|
+
|
879
|
+
<code class="ruby"> it 'should determine if the stage passed' do</code>
|
880
|
+
</li>
|
881
|
+
|
882
|
+
<li class="covered" data-hits="1" data-linenumber="27">
|
883
|
+
<span class="hits">1</span>
|
884
|
+
|
885
|
+
<code class="ruby"> stage = @topic.current_stage</code>
|
886
|
+
</li>
|
887
|
+
|
888
|
+
<li class="covered" data-hits="1" data-linenumber="28">
|
889
|
+
<span class="hits">1</span>
|
890
|
+
|
891
|
+
<code class="ruby"> stage.status = 'passed'</code>
|
892
|
+
</li>
|
893
|
+
|
894
|
+
<li class="covered" data-hits="1" data-linenumber="29">
|
895
|
+
<span class="hits">1</span>
|
896
|
+
|
897
|
+
<code class="ruby"> expect(stage.passed?).not_to be nil</code>
|
898
|
+
</li>
|
899
|
+
|
900
|
+
<li class="covered" data-hits="1" data-linenumber="30">
|
901
|
+
<span class="hits">1</span>
|
902
|
+
|
903
|
+
<code class="ruby"> expect(stage.passed?).to be true</code>
|
904
|
+
</li>
|
905
|
+
|
906
|
+
<li class="never" data-hits="" data-linenumber="31">
|
907
|
+
|
908
|
+
|
909
|
+
<code class="ruby"> end</code>
|
910
|
+
</li>
|
911
|
+
|
912
|
+
<li class="never" data-hits="" data-linenumber="32">
|
913
|
+
|
914
|
+
|
915
|
+
<code class="ruby"></code>
|
916
|
+
</li>
|
917
|
+
|
918
|
+
<li class="covered" data-hits="1" data-linenumber="33">
|
919
|
+
<span class="hits">1</span>
|
920
|
+
|
921
|
+
<code class="ruby"> it 'should determine if the stage failed' do</code>
|
922
|
+
</li>
|
923
|
+
|
924
|
+
<li class="covered" data-hits="1" data-linenumber="34">
|
925
|
+
<span class="hits">1</span>
|
926
|
+
|
927
|
+
<code class="ruby"> stage = @topic.current_stage</code>
|
928
|
+
</li>
|
929
|
+
|
930
|
+
<li class="covered" data-hits="1" data-linenumber="35">
|
931
|
+
<span class="hits">1</span>
|
932
|
+
|
933
|
+
<code class="ruby"> stage.status = 'failed'</code>
|
934
|
+
</li>
|
935
|
+
|
936
|
+
<li class="covered" data-hits="1" data-linenumber="36">
|
937
|
+
<span class="hits">1</span>
|
938
|
+
|
939
|
+
<code class="ruby"> expect(stage.passed?).not_to be nil</code>
|
940
|
+
</li>
|
941
|
+
|
942
|
+
<li class="covered" data-hits="1" data-linenumber="37">
|
943
|
+
<span class="hits">1</span>
|
944
|
+
|
945
|
+
<code class="ruby"> expect(stage.passed?).to be false</code>
|
946
|
+
</li>
|
947
|
+
|
948
|
+
<li class="never" data-hits="" data-linenumber="38">
|
949
|
+
|
950
|
+
|
951
|
+
<code class="ruby"> end</code>
|
952
|
+
</li>
|
953
|
+
|
954
|
+
<li class="never" data-hits="" data-linenumber="39">
|
955
|
+
|
956
|
+
|
957
|
+
<code class="ruby">end</code>
|
958
|
+
</li>
|
959
|
+
|
960
|
+
</ol>
|
961
|
+
</pre>
|
962
|
+
</div>
|
963
|
+
|
964
|
+
|
965
|
+
</div>
|
966
|
+
</div>
|
967
|
+
</body>
|
968
|
+
</html>
|