Skip to content

Commit

Permalink
[JENKINS-33683] Reproduce
Browse files Browse the repository at this point in the history
  • Loading branch information
olivergondza committed Mar 21, 2016
1 parent 27aeca9 commit e4d7da6
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions test/src/test/java/hudson/model/ManagementLinkTest.java
Expand Up @@ -23,16 +23,21 @@
*/
package hudson.model;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;

import com.gargoylesoftware.htmlunit.html.DomNodeUtil;
import com.gargoylesoftware.htmlunit.html.HtmlAnchor;
import com.gargoylesoftware.htmlunit.html.HtmlPage;
import org.junit.Rule;
import org.junit.Test;
import org.jvnet.hudson.test.Issue;
import org.jvnet.hudson.test.JenkinsRule;
import org.jvnet.hudson.test.JenkinsRule.WebClient;
import org.jvnet.hudson.test.TestExtension;
import org.xml.sax.SAXException;

import java.io.IOException;
import java.util.List;

/**
Expand All @@ -59,4 +64,28 @@ public void links() throws Exception {
((HtmlAnchor)anchors.get(i)).click();
}
}

@Test @Issue("JENKINS-33683")
public void invisibleLinks() throws Exception {
assertEquals(null, j.jenkins.getDynamic("and_fail_trying"));
}

@TestExtension("invisibleLinks")
public static final class InvisibleManagementLink extends ManagementLink {

@Override
public String getIconFileName() {
return null;
}

@Override
public String getDisplayName() {
return null;
}

@Override
public String getUrlName() {
return null;
}
}
}

0 comments on commit e4d7da6

Please sign in to comment.