Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-5913

Special characters in test failure message causes xUnit to ignore the xml file as invalid.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • xunit-plugin
    • None
    • Hudson 1.349 on Windows 2003 Server

      We are using CppUnit for testing the code and xUnit plugin has been working great to capture and report the results...

      However, our Unittest just recently failed with a failure message that causes xUnit to ignore it as "invalid" and it seems as though the test hasn't run.

      CppUnit outputs an XML file and in the <Message> section, if the content of the failure message contains either "&&" or "<" it causes the XML file to be considered invalid. There are probably other character strings that will cause this invalid issue, but these are the ones I had in my test.

      Is there a way to escape these special characters? I tried putting it in quotes or using a backslash...neither worked.

            gbois Gregory Boissinot
            jmboulos jmboulos
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: