Skip to content

Commit

Permalink
[JENKINS-51465] Exception in XSL Transformation cause JEP-200
Browse files Browse the repository at this point in the history
Change the converter to no more include ConversionException as cause to avoid JEP-200 issue. Only exception message or its root message is collected.
  • Loading branch information
Nikolas Falco committed Jun 6, 2018
1 parent 5dff992 commit 5149c4e
Showing 1 changed file with 5 additions and 2 deletions.
Expand Up @@ -84,8 +84,11 @@ public File convert(XUnitToolInfo xUnitToolInfo, File inputFile, File junitOutpu
inputMetric.convert(inputFile, junitTargetFile);
return junitTargetFile;

} catch (ConversionException | InterruptedException | IOException e) {
throw new XUnitException("Conversion error " + e.getMessage(), e);
} catch (ConversionException e) {
Throwable cause = e.getCause();
throw new XUnitException("Conversion error: " + (cause != null ? cause.getMessage() : e.getMessage()));
} catch (InterruptedException | IOException e) {
throw new XUnitException("Conversion error: " + e.getMessage(), e);
}
}

Expand Down

0 comments on commit 5149c4e

Please sign in to comment.