Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-08-23 Thread Wisen Tanasa
I couldn't get a way to grab the config.xml files nicely from jenkinsRule.jenkins.getAllItems(). This is what I ended up doing to get the config.xml files. I kind of like this approach as I don't have to handle config.xml that are not from Jenkins *Item *e.g. promoted builds generate

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-18 Thread Thomas Zoratto
Hello, I came up with a solution that doesn’t involve overwriting class, subclass etc. You just have to use the JenkinsRule object in your test in order to use the API of the running Jenkins instance. e.g. jenkinsRule.jenkins.getAllItems()… Then you can retrieve the config.xml generated for

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-07 Thread Thomas Zoratto
Hi, thanks for this update. I still don’t have time to try something about it but I will…! > Le 7 juin 2016 à 17:20, François Genois a écrit : > > Information for all (and for Thomas) : > > I was able to output the XML files in a not-clean-not-proud way : > I

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-07 Thread François Genois
Information for all (and for Thomas) : I was able to output the XML files in a not-clean-not-proud way : I copied the JenkinsJobManagement file (to remove the 'final' keyword from it that class) and I subclassed it as MemoryJobManagement subclasses MockJobManagement. I needed to add logging

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread François Genois
Ok, I'm pretty much in the same situation over here. Alright, I'm looking forward your advancement on this issue; I'll keep you updated if I find anything. Thanks again! - Frank On Wed, Jun 1, 2016 at 3:40 PM Thomas Zoratto wrote: > Right now I can’t see a way to do

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread Thomas Zoratto
Right now I can’t see a way to do this but my knowledge on this topic is very limited. I also have to work on it soon so I’ll let you know if I find a way (and if you still don’t have the answer). Please share your progress, if any Good luck ! Thomas > Le 1 juin 2016 à 20:35, François

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread François Genois
Hello Thomas, Thank you very much for your answer. The promoted builds plugin is indeed a extension point. I added the following line to my dependencies "testCompile 'org.jenkins-ci.plugins:promoted-builds:2.27@jar'" and my 'gradlew test' command now succeeds. I just tried applying the same

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread Thomas Zoratto
Hello Frank, I guess the promoted builds plugin is not directly compatible with the job DSL plugin. I mean you can’t find DSL methods relative to the promoted builds plugin in the online API https://github.com/franknarf8/job-dsl-gradle-example/commit/f15b7fbf698d7be29b8527043d8649ab15559842

Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread François Genois
Good morning everyone, I'm currently using a project based on https://github.com/sheehan/job-dsl-gradle-example and I am trying to get the promoted-builds plugin to work with this project (https://wiki.jenkins-ci.org/display/JENKINS/Promoted+Builds+Plugin). Everything works fine on my Jenkins