mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

al_xipe
30.22.2007 276922e03a86ce25545377dd17787b43535d3e89
surround the XSL report generation step with try catch to help diagnose when the XML log is malformed
1 files modified
7 ■■■■ changed files
opendj-sdk/opends/tests/functional-tests/testcases/runTestJob.xml 7 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/tests/functional-tests/testcases/runTestJob.xml
@@ -454,6 +454,8 @@
      </message>
      
      <script>
        _message=''
        try:
        from java.io import FileInputStream
        from java.io import FileOutputStream
        from java.io import ByteArrayOutputStream
@@ -473,8 +475,11 @@
        
        #the new report transformation
        TransformerFactory.newInstance().newTemplates(StreamSource(FileInputStream("%s/xsl/my-report.xsl" % TESTS_SHARED_DIR))).newTransformer().transform(StreamSource(FileInputStream("%s/tests-log.xml" % TMPDIR)), StreamResult(FileOutputStream("%s/my-report.html" % TMPDIR)))      
          _message='Generated drill-down HTML report'
        except:
          _message='Could not generate drill-down HTML report'
      </script>
      <message>_message</message>
      <if expr="SEND_MAIL_AFTER_TEST_RUN == 'TRUE'">
        <sequence>
          <message>