Skip to content
Permalink
Browse files
[JENKINS-32376] Jenkins < 1.600 have a problem with the server-side d…
…ownload feature (Downloadable refers URLs without signatures) and cannot test the behavior. I decided to target 1.609.
  • Loading branch information
ikedam committed Jan 16, 2016
1 parent a4e9b85 commit cf71b464e80372ff906e0d81d5113d6f4e4b2892
Showing with 15 additions and 2 deletions.
  1. +1 −1 pom.xml
  2. +14 −1 src/test/java/jp/ikedam/jenkins/plugins/updatesitesmanager/ManagedUpdateSiteJenkinsTest.java
@@ -3,7 +3,7 @@
<parent>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>plugin</artifactId>
<version>1.596</version><!-- which version of Jenkins is this plugin built against? -->
<version>1.609</version><!-- which version of Jenkins is this plugin built against? -->
</parent>

<groupId>jp.ikedam.jenkins.plugins</groupId>
@@ -247,8 +247,21 @@ public void testDoCheckUpdateServer() throws Exception {
false
);
jenkins.getUpdateCenter().getSites().clear();

{
target.setCaCertificate(null);
HttpResponse rsp = jenkins.getPluginManager().doCheckUpdatesServer();
if (rsp instanceof FormValidation) {
// this fails with Jenkins < 1.600, Jenkins < 1.596.1
assertEquals(
"Accessing update center without any update sites should succeed",
FormValidation.Kind.OK,
((FormValidation)rsp).kind
);
}
}

jenkins.getUpdateCenter().getSites().add(target);
jenkins.getUpdateCenter().save();

{
target.setCaCertificate(null);

0 comments on commit cf71b46

Please sign in to comment.