File tree Expand file tree Collapse file tree 3 files changed +18
-0
lines changed
main/groovy/javaposse/jobdsl/dsl/views
test/groovy/javaposse/jobdsl/dsl/views Expand file tree Collapse file tree 3 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -38,6 +38,7 @@ listView(String name) { // since 1.30
3838 lastDuration()
3939 buildButton()
4040 lastBuildConsole() // since 1.23, requires the Extra Columns Plugin
41+ configureProject() // since 1.31, requires the Extra Columns Plugin
4142 claim() // since 1.29, requires the Claim Plugin
4243 lastBuildNode() // since 1.31, requires the Build Node Column Plugin
4344 }
Original file line number Diff line number Diff line change @@ -43,6 +43,10 @@ class ColumnsContext implements Context {
4343 columnNodes << new Node (null , ' jenkins.plugins.extracolumns.LastBuildConsoleColumn' )
4444 }
4545
46+ void configureProject () {
47+ columnNodes << new Node (null , ' jenkins.plugins.extracolumns.ConfigureProjectColumn' )
48+ }
49+
4650 void claim () {
4751 columnNodes << new Node (null , ' hudson.plugins.claim.ClaimColumn' )
4852 }
Original file line number Diff line number Diff line change @@ -254,6 +254,19 @@ class ListViewSpec extends Specification {
254254 root. columns[0 ]. value()[0 ]. name() == ' jenkins.plugins.extracolumns.LastBuildConsoleColumn'
255255 }
256256
257+ def ' configureProject column' () {
258+ when :
259+ view. columns {
260+ configureProject()
261+ }
262+
263+ then :
264+ Node root = view. node
265+ root. columns. size() == 1
266+ root. columns[0 ]. value(). size() == 1
267+ root. columns[0 ]. value()[0 ]. name() == ' jenkins.plugins.extracolumns.ConfigureProjectColumn'
268+ }
269+
257270 def ' statusFilter' (Closure filter, Map children) {
258271 when :
259272 view. jobFilters(filter)
You can’t perform that action at this time.
0 commit comments