palantir / gerrit-ci

Plugin for Gerrit enabling self-service continuous integration workflows with Jenkins.
Apache License 2.0
18 stars 9 forks source link

Add junit configuration option to gerrit-ci #2

Closed camushoilingma closed 9 years ago

mass commented 9 years ago

Looks like some .DS_Store files were committed. We should probably add that to the .gitignore file.

mass commented 9 years ago

I'm getting this exception when the JenkinsJobParser is parsing XML from jobs that exist but do not have JUnit enabled:

[2015-08-05 18:24:19,064] ERROR com.google.gerrit.pgm.http.jetty.HiddenErrorHandler : Error in GET /plugins/gerrit-ci/jobs/All-Projects
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
        at java.util.ArrayList.rangeCheck(ArrayList.java:635)
        at java.util.ArrayList.get(ArrayList.java:411)
        at com.palantir.gerrit.gerritci.util.JenkinsJobParser.parseJenkinsJob(JenkinsJobParser.java:83)
mass commented 9 years ago

It looks like jenkins-verify-job.vm and jenkins-publish-job.vm were auto-formatted. Although I'm open to a different formatting, it's kind of confusing to have that be in the same commit as the JUnit stuff as it's hard to tell what is actually being added or removed and what is just being formatted. We should probably either undo the auto-formatting or split it into a separate commit.

camushoilingma commented 9 years ago

Sure, I just used an xml formatter but can put that in a separate commit.