rubyjobbuilderdsl 0.0.4 → 0.0.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.
Files changed (112) hide show
  1. checksums.yaml +5 -13
  2. data/Gemfile +6 -6
  3. data/Gemfile.lock +41 -41
  4. data/LICENSE +18 -18
  5. data/Rakefile +12 -12
  6. data/docs/common.md +313 -313
  7. data/docs/flow.md +17 -17
  8. data/docs/freestyle.md +100 -100
  9. data/docs/gerrit.md +70 -70
  10. data/docs/git.md +88 -88
  11. data/docs/multi.md +26 -26
  12. data/docs/overview.md +74 -74
  13. data/docs/postbuild.md +266 -266
  14. data/docs/view.md +13 -13
  15. data/lib/rubyjobbuilderdsl/buildstep/ant.rb +29 -29
  16. data/lib/rubyjobbuilderdsl/buildstep/copyartifact.rb +23 -23
  17. data/lib/rubyjobbuilderdsl/buildstep/inject_env.rb +18 -18
  18. data/lib/rubyjobbuilderdsl/buildstep/phase.rb +19 -19
  19. data/lib/rubyjobbuilderdsl/buildstep/phase_job.rb +26 -26
  20. data/lib/rubyjobbuilderdsl/buildstep/shell.rb +24 -24
  21. data/lib/rubyjobbuilderdsl/buildstep/xvfb.rb +46 -46
  22. data/lib/rubyjobbuilderdsl/common/artifactory.rb +33 -33
  23. data/lib/rubyjobbuilderdsl/common/blocking_job.rb +11 -11
  24. data/lib/rubyjobbuilderdsl/common/build_timeout.rb +23 -23
  25. data/lib/rubyjobbuilderdsl/common/gerrit.rb +53 -53
  26. data/lib/rubyjobbuilderdsl/common/git.rb +76 -76
  27. data/lib/rubyjobbuilderdsl/common/logrotate.rb +24 -24
  28. data/lib/rubyjobbuilderdsl/common/parameter.rb +22 -22
  29. data/lib/rubyjobbuilderdsl/common/password.rb +12 -12
  30. data/lib/rubyjobbuilderdsl/common/pollscm.rb +10 -10
  31. data/lib/rubyjobbuilderdsl/common/scms.rb +18 -18
  32. data/lib/rubyjobbuilderdsl/common/throttle.rb +24 -24
  33. data/lib/rubyjobbuilderdsl/common/timed.rb +10 -10
  34. data/lib/rubyjobbuilderdsl/common/timestamps.rb +6 -6
  35. data/lib/rubyjobbuilderdsl/common.rb +140 -140
  36. data/lib/rubyjobbuilderdsl/deployer.rb +95 -95
  37. data/lib/rubyjobbuilderdsl/flow.rb +14 -14
  38. data/lib/rubyjobbuilderdsl/freestyle.rb +65 -65
  39. data/lib/rubyjobbuilderdsl/jenkins_client.rb +203 -203
  40. data/lib/rubyjobbuilderdsl/multijob.rb +24 -24
  41. data/lib/rubyjobbuilderdsl/postbuild/archive.rb +23 -23
  42. data/lib/rubyjobbuilderdsl/postbuild/chucknorris_publisher.rb +6 -6
  43. data/lib/rubyjobbuilderdsl/postbuild/claim_publisher.rb +6 -6
  44. data/lib/rubyjobbuilderdsl/postbuild/cloverphp_publisher.rb +36 -36
  45. data/lib/rubyjobbuilderdsl/postbuild/cucumber_json_publisher.rb +20 -20
  46. data/lib/rubyjobbuilderdsl/postbuild/email_publisher.rb +23 -23
  47. data/lib/rubyjobbuilderdsl/postbuild/game_publisher.rb +6 -6
  48. data/lib/rubyjobbuilderdsl/postbuild/groovy.rb +10 -10
  49. data/lib/rubyjobbuilderdsl/postbuild/html_publisher.rb +27 -27
  50. data/lib/rubyjobbuilderdsl/postbuild/javadoc_publisher.rb +19 -19
  51. data/lib/rubyjobbuilderdsl/postbuild/logparser.rb +21 -21
  52. data/lib/rubyjobbuilderdsl/postbuild/nunit_publisher.rb +21 -21
  53. data/lib/rubyjobbuilderdsl/postbuild/pmd_publisher.rb +19 -19
  54. data/lib/rubyjobbuilderdsl/postbuild/script.rb +14 -14
  55. data/lib/rubyjobbuilderdsl/postbuild/tap_publisher.rb +44 -44
  56. data/lib/rubyjobbuilderdsl/postbuild/trigger.rb +38 -38
  57. data/lib/rubyjobbuilderdsl/postbuild/xunit_publisher.rb +35 -35
  58. data/lib/rubyjobbuilderdsl/postbuild.rb +160 -160
  59. data/lib/rubyjobbuilderdsl/view.rb +14 -14
  60. data/lib/rubyjobbuilderdsl/xml_generator.rb +1 -1
  61. data/lib/rubyjobbuilderdsl.rb +2 -2
  62. data/rubyjobbuilderdsl-0.0.3.gem +0 -0
  63. data/rubyjobbuilderdsl.gemspec +13 -13
  64. data/rubyjobbuilderdsl.sublime-project +14 -14
  65. data/run_tests.sh +7 -7
  66. data/sample/Schedule-sample-pipeline.xml +32 -0
  67. data/sample/hello_mars.rb +27 -27
  68. data/sample/local.ini +4 -4
  69. data/test/test_ant.rb +38 -38
  70. data/test/test_archive.rb +24 -24
  71. data/test/test_artifactory.rb +26 -26
  72. data/test/test_blocking_job.rb +18 -18
  73. data/test/test_chucknorris_publisher.rb +17 -17
  74. data/test/test_claim_publisher.rb +17 -17
  75. data/test/test_cloverphp.rb +33 -33
  76. data/test/test_concurrent.rb +44 -44
  77. data/test/test_copyartifact.rb +45 -45
  78. data/test/test_cucumber_json_publisher.rb +30 -30
  79. data/test/test_default_setting.rb +29 -29
  80. data/test/test_email_publisher.rb +44 -44
  81. data/test/test_flow.rb +19 -19
  82. data/test/test_freestyle.rb +52 -52
  83. data/test/test_game_publisher.rb +17 -17
  84. data/test/test_gerrit.rb +117 -117
  85. data/test/test_git.rb +80 -80
  86. data/test/test_html_publisher.rb +57 -57
  87. data/test/test_inject.rb +23 -23
  88. data/test/test_javadoc.rb +22 -22
  89. data/test/test_logparser.rb +24 -24
  90. data/test/test_logrotate.rb +22 -22
  91. data/test/test_multijob.rb +50 -50
  92. data/test/test_nunit_publisher.rb +20 -20
  93. data/test/test_parameter.rb +44 -44
  94. data/test/test_password.rb +17 -17
  95. data/test/test_pmd.rb +22 -22
  96. data/test/test_pollscm.rb +15 -15
  97. data/test/test_postbuild_groovy.rb +21 -21
  98. data/test/test_postbuild_script.rb +24 -24
  99. data/test/test_postbuild_trigger.rb +170 -170
  100. data/test/test_scms.rb +31 -31
  101. data/test/test_tap_publisher.rb +25 -25
  102. data/test/test_timed.rb +15 -15
  103. data/test/test_timeout.rb +20 -20
  104. data/test/test_timestamps.rb +14 -14
  105. data/test/test_xml_generator.rb +28 -28
  106. data/test/test_xunit_publisher.rb +22 -22
  107. data/test/test_xvfb.rb +35 -35
  108. metadata +9 -11
  109. data/sample/hello_mars.xml +0 -18
  110. data/sample/hello_world-post.xml +0 -40
  111. data/sample/sample_flow.rb +0 -15
  112. data/sample/test.xml +0 -21
@@ -1,76 +1,76 @@
1
- module JenkinsJob
2
- module Common
3
- class Git < BasicObject
4
- attr_reader :url_, :basedir_, :reference_repo_, :branches_, :refspec_,
5
- :choosing_strategy_, :git_config_name_, :git_config_email_,
6
- :fastpoll_, :files_, :wipe_workspace_, :clean_, :jgit_, :credentials_
7
-
8
- def initialize
9
- @fastpoll_ = true
10
- @branches_ = ['*/master']
11
- @jgit_ = false
12
- end
13
-
14
- def url(value)
15
- @url_ = value
16
- end
17
-
18
- def basedir(value)
19
- @basedir_ = value
20
- end
21
-
22
- def reference_repo(value)
23
- @reference_repo_ = value
24
- end
25
-
26
- # @deprecated Please use {#branch}
27
- def branches(*value)
28
- branch(*value)
29
- end
30
-
31
- def branch(*value)
32
- @branches_ = value
33
- end
34
-
35
- def refspec(value)
36
- @refspec_ = value
37
- end
38
-
39
- def choosing_strategy(value)
40
- @choosing_strategy_ = value
41
- end
42
-
43
- def git_config_name(value)
44
- @git_config_name_ = value
45
- end
46
-
47
- def git_config_email(value)
48
- @git_config_email_ = value
49
- end
50
-
51
- def fastpoll(value = true)
52
- @fastpoll_ = value
53
- end
54
-
55
- def file(*value)
56
- @files_ = value
57
- end
58
-
59
- def clean(value = false)
60
- @clean_ = value
61
- end
62
-
63
- def wipe_workspace(value = true)
64
- @wipe_workspace_ = value
65
- end
66
-
67
- def jgit
68
- @jgit_ = true
69
- end
70
-
71
- def credentials(value)
72
- @credentials_ = value
73
- end
74
- end
75
- end
76
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class Git < BasicObject
4
+ attr_reader :url_, :basedir_, :reference_repo_, :branches_, :refspec_,
5
+ :choosing_strategy_, :git_config_name_, :git_config_email_,
6
+ :fastpoll_, :files_, :wipe_workspace_, :clean_, :jgit_, :credentials_
7
+
8
+ def initialize
9
+ @fastpoll_ = true
10
+ @branches_ = ['*/master']
11
+ @jgit_ = false
12
+ end
13
+
14
+ def url(value)
15
+ @url_ = value
16
+ end
17
+
18
+ def basedir(value)
19
+ @basedir_ = value
20
+ end
21
+
22
+ def reference_repo(value)
23
+ @reference_repo_ = value
24
+ end
25
+
26
+ # @deprecated Please use {#branch}
27
+ def branches(*value)
28
+ branch(*value)
29
+ end
30
+
31
+ def branch(*value)
32
+ @branches_ = value
33
+ end
34
+
35
+ def refspec(value)
36
+ @refspec_ = value
37
+ end
38
+
39
+ def choosing_strategy(value)
40
+ @choosing_strategy_ = value
41
+ end
42
+
43
+ def git_config_name(value)
44
+ @git_config_name_ = value
45
+ end
46
+
47
+ def git_config_email(value)
48
+ @git_config_email_ = value
49
+ end
50
+
51
+ def fastpoll(value = true)
52
+ @fastpoll_ = value
53
+ end
54
+
55
+ def file(*value)
56
+ @files_ = value
57
+ end
58
+
59
+ def clean(value = false)
60
+ @clean_ = value
61
+ end
62
+
63
+ def wipe_workspace(value = true)
64
+ @wipe_workspace_ = value
65
+ end
66
+
67
+ def jgit
68
+ @jgit_ = true
69
+ end
70
+
71
+ def credentials(value)
72
+ @credentials_ = value
73
+ end
74
+ end
75
+ end
76
+ end
@@ -1,24 +1,24 @@
1
- module JenkinsJob
2
- module Common
3
- class LogRotate < BasicObject
4
- attr_reader :days_to_keep_, :num_to_keep_,
5
- :artifact_days_to_keep_, :artifact_num_to_keep_
6
-
7
- def days_to_keep(value)
8
- @days_to_keep_ = value
9
- end
10
-
11
- def num_to_keep(value)
12
- @num_to_keep_ = value
13
- end
14
-
15
- def artifact_days_to_keep(value)
16
- @artifact_days_to_keep_ = value
17
- end
18
-
19
- def artifact_num_to_keep(value)
20
- @artifact_num_to_keep_ = value
21
- end
22
- end
23
- end
24
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class LogRotate < BasicObject
4
+ attr_reader :days_to_keep_, :num_to_keep_,
5
+ :artifact_days_to_keep_, :artifact_num_to_keep_
6
+
7
+ def days_to_keep(value)
8
+ @days_to_keep_ = value
9
+ end
10
+
11
+ def num_to_keep(value)
12
+ @num_to_keep_ = value
13
+ end
14
+
15
+ def artifact_days_to_keep(value)
16
+ @artifact_days_to_keep_ = value
17
+ end
18
+
19
+ def artifact_num_to_keep(value)
20
+ @artifact_num_to_keep_ = value
21
+ end
22
+ end
23
+ end
24
+ end
@@ -1,22 +1,22 @@
1
- module JenkinsJob
2
- module Common
3
- class Parameter < BasicObject
4
- attr_reader :name, :default_, :description_
5
-
6
- def initialize(name)
7
- @name = name
8
- end
9
-
10
- def default(value)
11
- @default_ = value
12
- end
13
-
14
- def description(value)
15
- @description_ = value
16
- end
17
- end
18
-
19
- class PasswordParameter < Parameter
20
- end
21
- end
22
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class Parameter < BasicObject
4
+ attr_reader :name, :default_, :description_
5
+
6
+ def initialize(name)
7
+ @name = name
8
+ end
9
+
10
+ def default(value)
11
+ @default_ = value
12
+ end
13
+
14
+ def description(value)
15
+ @description_ = value
16
+ end
17
+ end
18
+
19
+ class PasswordParameter < Parameter
20
+ end
21
+ end
22
+ end
@@ -1,12 +1,12 @@
1
- module JenkinsJob
2
- module Common
3
- class Password < BasicObject
4
- attr_reader :name_, :password_
5
-
6
- def initialize(name, password)
7
- @name_ = name
8
- @password_ = password
9
- end
10
- end
11
- end
12
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class Password < BasicObject
4
+ attr_reader :name_, :password_
5
+
6
+ def initialize(name, password)
7
+ @name_ = name
8
+ @password_ = password
9
+ end
10
+ end
11
+ end
12
+ end
@@ -1,10 +1,10 @@
1
- module JenkinsJob
2
- module Common
3
- class PollSCM < BasicObject
4
- attr_reader :value_
5
- def initialize(value)
6
- @value_ = value
7
- end
8
- end
9
- end
10
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class PollSCM < BasicObject
4
+ attr_reader :value_
5
+ def initialize(value)
6
+ @value_ = value
7
+ end
8
+ end
9
+ end
10
+ end
@@ -1,18 +1,18 @@
1
- module JenkinsJob
2
- module Common
3
- class Scms < BasicObject
4
- attr_reader :scms_
5
-
6
- def initialize
7
- @scms_ = []
8
- end
9
-
10
- def git(&block)
11
- git = Git.new
12
- git.instance_eval(&block)
13
-
14
- @scms_ << git
15
- end
16
- end
17
- end
18
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class Scms < BasicObject
4
+ attr_reader :scms_
5
+
6
+ def initialize
7
+ @scms_ = []
8
+ end
9
+
10
+ def git(&block)
11
+ git = Git.new
12
+ git.instance_eval(&block)
13
+
14
+ @scms_ << git
15
+ end
16
+ end
17
+ end
18
+ end
@@ -1,24 +1,24 @@
1
- module JenkinsJob
2
- module Common
3
- class Throttle < BasicObject
4
- attr_reader :categories_, :max_per_node_, :max_total_
5
-
6
- def initialize
7
- @max_per_node_ = 1
8
- @max_total_ = 0
9
- end
10
-
11
- def max_per_node(value)
12
- @max_per_node_ = value
13
- end
14
-
15
- def max_total(value)
16
- @max_total_ = value
17
- end
18
-
19
- def category(*value)
20
- @categories_ = value
21
- end
22
- end
23
- end
24
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class Throttle < BasicObject
4
+ attr_reader :categories_, :max_per_node_, :max_total_
5
+
6
+ def initialize
7
+ @max_per_node_ = 1
8
+ @max_total_ = 0
9
+ end
10
+
11
+ def max_per_node(value)
12
+ @max_per_node_ = value
13
+ end
14
+
15
+ def max_total(value)
16
+ @max_total_ = value
17
+ end
18
+
19
+ def category(*value)
20
+ @categories_ = value
21
+ end
22
+ end
23
+ end
24
+ end
@@ -1,10 +1,10 @@
1
- module JenkinsJob
2
- module Common
3
- class Timed < BasicObject
4
- attr_reader :value_
5
- def initialize(value)
6
- @value_ = value
7
- end
8
- end
9
- end
10
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class Timed < BasicObject
4
+ attr_reader :value_
5
+ def initialize(value)
6
+ @value_ = value
7
+ end
8
+ end
9
+ end
10
+ end
@@ -1,6 +1,6 @@
1
- module JenkinsJob
2
- module Common
3
- class Timestamps < BasicObject
4
- end
5
- end
6
- end
1
+ module JenkinsJob
2
+ module Common
3
+ class Timestamps < BasicObject
4
+ end
5
+ end
6
+ end