[ https://issues.apache.org/jira/browse/RAT-242?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16325667#comment-16325667 ]
Matthias Bläsing commented on RAT-242: -------------------------------------- I tried to reproduce the test failure and totally failed. I switched JDKs, Maven versions and system locales and nothing changed. The build runs cleanly. I checked the test files and both contain the the right ISO-8859-1 encoding umlauts. I suggest to modify the test to output the header-sample content like this: {noformat} matthias@athena:~/src/creadur-rat-svn$ svn diff Index: apache-rat-plugin/src/test/java/org/apache/rat/mp/RatCheckMojoTest.java =================================================================== --- apache-rat-plugin/src/test/java/org/apache/rat/mp/RatCheckMojoTest.java (Revision 1821111) +++ apache-rat-plugin/src/test/java/org/apache/rat/mp/RatCheckMojoTest.java (Arbeitskopie) @@ -238,11 +238,12 @@ boolean documentParsed = false; try { Document doc = db.parse(fis); - boolean byteSequencePresent = doc.getElementsByTagName("header-sample") + String headerSample = doc.getElementsByTagName("header-sample") .item(0) - .getTextContent() + .getTextContent(); + boolean byteSequencePresent = headerSample .contains("\u00E4\u00F6\u00FC\u00C4\u00D6\u00DC\u00DF"); - assertTrue("Report should contain test umlauts", byteSequencePresent); + assertTrue("header-sample should contain test umlauts: " + headerSample, byteSequencePresent); documentParsed = true; } catch (Exception ex) { documentParsed = false; matthias@athena:~/src/creadur-rat-svn$ {noformat} Maybe that reveals something. > Encoding of XML report > ---------------------- > > Key: RAT-242 > URL: https://issues.apache.org/jira/browse/RAT-242 > Project: Apache Rat > Issue Type: Bug > Components: reports > Affects Versions: 0.12 > Environment: ubuntu > Reporter: Eric Barboni > Attachments: rat-242.patch > > > Hi, we encounter an issue with encoding of a xml rat report. > We try to parse an xml rat report generated on an iso-8859-1 file system. The > xml has no encoding element in the prolog. If you open it with fileinpustream > it may fail. > last comment in this pull request > (https://github.com/apache/incubator-netbeans/pull/70) by Matthias Bläsing > suggest forcing to UTF-8. > encoding may also be an option in the report task > Regards -- This message was sent by Atlassian JIRA (v6.4.14#64029)