Issue Details (XML | Word | Printable)

Key: SUREFIRE-264
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Herve Boutemy
Reporter: Maarten Winkels
Votes: 2
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Maven Surefire

XRef links do not work with aggregated reports on windows

Created: 27/Nov/06 01:11 AM   Updated: 03/May/08 01:48 AM
Component/s: report plugin
Affects Version/s: 2.0 Report Plugin
Fix Version/s: 2.4.3

Time Tracking:
Original Estimate: 1 hour
Original Estimate - 1 hour
Remaining Estimate: 1 hour
Remaining Estimate - 1 hour
Time Spent: Not Specified
Remaining Estimate - 1 hour

File Attachments: 1. Text File outputDirectoryIsFile.patch (3 kB)

Issue Links:
dependent
 

Patch Submitted: Yes


 Description  « Hide
When generating aggregated reports with the jxr-plugin, the xref links cannot be generated correctly on windows.

This is mainly due to the fact that the outputDirectory is a java.lang.String property in stead of a java.io.File property. This makes the propert os dependant. The expression with this property is ${project.build.directory}/site. On windows this should be ${project.build.directory}\site. It might even be beter to change it to ${project.reporting.outputDirectory}. See the checkstyle plugin for reference.

When working with aggregated jxr-reports, the xrefLocation (which IS a java.io.File property) should preferable be ${project.build.directory}/site/../xref-test, since this is the relative publish location of the reports. Being a java.lang.String property, this will resolve to something like c:[path to build directory]\target\site\..\xref-test. In the SurefireReportMojo.determineXrefLocation the absolute path of this file property is compared to the outputDirectory which is a java.lang.String it will probably be set to c:[path to build directory]\target/site (n.b. forward slash in stead of backward slash), which will lead to an empty relative path, where ../xref-test would be expected.



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Maarten Winkels added a comment - 27/Nov/06 01:45 AM
This patch turns the outputDirectory into a java.io.File. Tests are updated.

Benjamin Bentmann added a comment - 19/Jan/08 08:44 AM
See also Common Bugs why changing the parameter type of outputDirectory to java.io.File is a more than advisable.

Herve Boutemy added a comment - 08/Mar/08 03:31 PM
patch applied in r635090

thanks