Skip to content
Permalink
Browse files

Fixed: JENKINS-23285 - All links on trend graph map are wrong on "tes…

…tngreports" subpage
  • Loading branch information
nullin committed Jun 29, 2014
1 parent 694ddcc commit e8153d09dd5ceb42b7de8d10881c8ee2b048b961
3 README
@@ -16,6 +16,9 @@ graph and all details about which tests that failed are also presented.
Release Notes
-------

### Upcoming
* Fixed: JENKINS-23285 - All links on trend graph map are wrong on "testngreports" subpage

### 1.6
* Fixed: JENKINS-19353 - Exception error message newlines are escaped
* Fixed: JENKINS-20968 - Doesn't resolve parameters in "TestNG XML report pattern" field
@@ -46,8 +46,7 @@ public static void redirectWhenGraphUnsupported(StaplerResponse rsp, StaplerRequ
rsp.sendRedirect2(req.getContextPath() + "/images/headless.png");
}

public static JFreeChart createChart(StaplerRequest req, CategoryDataset dataset) {

public static JFreeChart createChart(final StaplerRequest req, CategoryDataset dataset) {
final JFreeChart chart = ChartFactory.createStackedAreaChart(
null, // chart title
null, // unused
@@ -88,7 +87,8 @@ public static JFreeChart createChart(StaplerRequest req, CategoryDataset dataset
@Override
public String generateURL(CategoryDataset dataset, int row, int column) {
NumberOnlyBuildLabel label = (NumberOnlyBuildLabel) dataset.getColumnKey(column);
return label.build.getNumber() + "/" + PluginImpl.URL + "/";
String path = req.getParameter("rel");
return (path == null ? "" : path) + label.build.getNumber() + "/" + PluginImpl.URL + "/";
}

@Override
@@ -13,7 +13,7 @@ l.layout(title: "TestNG Results Trend") {

h1("TestNG Results Trends")
if (my.isGraphActive()) {
img(lazymap: "graphMap?rel=${my.project.lastCompletedBuild.upUrl}", alt: "[Test result trend chart]", src: "graph")
img(lazymap: "graphMap?rel=../", alt: "[Test result trend chart]", src: "graph")
} else {
p("Need at least 2 builds with results to show trend graph")
}

0 comments on commit e8153d0

Please sign in to comment.
You can’t perform that action at this time.