predrags_dummy_pipelines 0.7.3 → 0.7.5
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
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 54a9f3e889cedec60ab980d4ef4c58eeb9b000d1
|
4
|
+
data.tar.gz: 74fc648565cc40f42dcdcfb58e5f58d246eaf0b1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 68d73c5804ae59a7408aa132da7f4d77bfc9ecb1ab1a3e5a47fd760f651e63b0e384697ac612d6da184377c8869a0cd03995c4b9ed19ed9c07ec3cf9a6b9dec6
|
7
|
+
data.tar.gz: 8fc31fd452eb8f634784ba137ec7711f8810099343faa47d1094080869e88704dc1dad59c1e011d9932f9401cbb0c4b5e642ac6c79541c9ffe2e6334b2309e87
|
@@ -15,10 +15,29 @@ module PredragsDummyPipelines
|
|
15
15
|
|
16
16
|
def run
|
17
17
|
run_cmd(@cmd, @cmd_results, true)
|
18
|
-
return if @cmd_results
|
18
|
+
return if not success_impl(@cmd_results)
|
19
19
|
run_cmd(@test, @test_results, false)
|
20
20
|
end
|
21
21
|
|
22
|
+
def show
|
23
|
+
[{exec_name: @name}, @cmd_results, @test_results]
|
24
|
+
end
|
25
|
+
|
26
|
+
def results
|
27
|
+
{:cmd => @cmd_results, :test => @test_results, name: @name}
|
28
|
+
end
|
29
|
+
|
30
|
+
def success?
|
31
|
+
success_impl(@cmd_results) and success_impl(@test_results)
|
32
|
+
end
|
33
|
+
|
34
|
+
def success_impl(results)
|
35
|
+
return false if (results == [])
|
36
|
+
results.map {|cmd| cmd[:estatus]}.all? {|status| status == 0}
|
37
|
+
end
|
38
|
+
|
39
|
+
private
|
40
|
+
|
22
41
|
def run_cmd(commands, results, should_break)
|
23
42
|
commands.each {|c|
|
24
43
|
begin
|
@@ -31,13 +50,6 @@ module PredragsDummyPipelines
|
|
31
50
|
}
|
32
51
|
@results
|
33
52
|
end
|
34
|
-
|
35
|
-
def show
|
36
|
-
[{exec_name: @name}, @cmd_results, @test_results]
|
37
|
-
end
|
38
|
-
|
39
|
-
def results
|
40
|
-
{:cmd => @cmd_results, :test => @test_results, name: @name}
|
41
|
-
end
|
42
53
|
end
|
54
|
+
|
43
55
|
end
|
data/project/simple.yml
CHANGED