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

xUnit fails to parse boost test log

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Incomplete
    • Component/s: xunit-plugin
    • Labels:
      None
    • Environment:
      Jenkins v1.434 with xUnit 1.23.
    • Similar Issues:

      Description

      When parsing the attached file, following message is logged by xUnit:

      Oct 12, 2011 6:03:12 PM com.thalesgroup.hudson.plugins.xunit.service.XUnitService errorSystemLogger
      SEVERE: [xUnit] - The result file '/var/lib/jenkins/jobs/xUnit Test/workspace/Test_log.xml' for the metric 'BoostTest-1.x (default)' is not valid. The result file has been skipped.

      The following text is shown in console:
      [xUnit] [INFO] - Starting to record.
      [xUnit] [INFO] - Processing BoostTest-1.x (default)
      [xUnit] [WARNING] - Can't create the path /var/lib/jenkins/jobs/xUnit Test/workspace/generatedJUnitFiles. Maybe the directory already exists.
      [xUnit] [INFO] - [BoostTest-1.x (default)] - 1 test report file(s) were found with the pattern 'Test_log.xml' relative to '/var/lib/jenkins/jobs/xUnit Test/workspace' for the testing framework 'BoostTest-1.x (default)'.
      [xUnit] [ERROR] - The result file '/var/lib/jenkins/jobs/xUnit Test/workspace/Test_log.xml' for the metric 'BoostTest-1.x (default)' is not valid. The result file has been skipped.
      [xUnit] [INFO] - Stopping recording.

        Attachments

          Activity

          Hide
          eldaryus Eldar Yusupov added a comment -

          I deleted most entries from the file and came up with the following log (which still does not work):

          <TestLog>
          <TestSuite name="BER">
          <TestCase name="TestBERIntegerConstraints">
          <TestSuite name="Base BER INTEGER encoding/decoding constrained test suite">
          <TestCase name="TestBERIntegerConstraintsWithValue">
          <Message file="/var/lib/jenkins/jobs/ASN1 Compiler/workspace/trunk/asn1-compiler/runtime/tests/TestBER.cc" line="340">
          <![CDATA[BER INTEGER constraints: 0 .. 255, value = 0]]>
          </Message>
          <Message file="/var/lib/jenkins/jobs/ASN1 Compiler/workspace/trunk/asn1-compiler/runtime/tests/TestBER.cc" line="353">
          <![CDATA[Encode INTEGER [EMPTY, UNIVERSAL]]]>
          </Message>
          <Message file="/var/lib/jenkins/jobs/ASN1 Compiler/workspace/trunk/asn1-compiler/runtime/tests/TestBER.cc" line="360">
          <![CDATA[Decode INTEGER [EMPTY, UNIVERSAL]]]>
          </Message>
          <TestingTime>0</TestingTime>
          </TestCase>
          </TestSuite>
          <Error file="/var/lib/jenkins/jobs/ASN1 Compiler/workspace/trunk/asn1-compiler/runtime/tests/TestBER.cc" line="410">
          <![CDATA[check tr.p_assertions_failed == (std::size_t) 0 failed [2 != 0]]]>
          </Error>
          <TestingTime>0</TestingTime>
          </TestCase>
          </TestSuite>
          </TestLog>

          Any idea why it does not work?

          Show
          eldaryus Eldar Yusupov added a comment - I deleted most entries from the file and came up with the following log (which still does not work): <TestLog> <TestSuite name="BER"> <TestCase name="TestBERIntegerConstraints"> <TestSuite name="Base BER INTEGER encoding/decoding constrained test suite"> <TestCase name="TestBERIntegerConstraintsWithValue"> <Message file="/var/lib/jenkins/jobs/ASN1 Compiler/workspace/trunk/asn1-compiler/runtime/tests/TestBER.cc" line="340"> <![CDATA [BER INTEGER constraints: 0 .. 255, value = 0] ]> </Message> <Message file="/var/lib/jenkins/jobs/ASN1 Compiler/workspace/trunk/asn1-compiler/runtime/tests/TestBER.cc" line="353"> <![CDATA[Encode INTEGER [EMPTY, UNIVERSAL] ]]> </Message> <Message file="/var/lib/jenkins/jobs/ASN1 Compiler/workspace/trunk/asn1-compiler/runtime/tests/TestBER.cc" line="360"> <![CDATA[Decode INTEGER [EMPTY, UNIVERSAL] ]]> </Message> <TestingTime>0</TestingTime> </TestCase> </TestSuite> <Error file="/var/lib/jenkins/jobs/ASN1 Compiler/workspace/trunk/asn1-compiler/runtime/tests/TestBER.cc" line="410"> <![CDATA[check tr.p_assertions_failed == (std::size_t) 0 failed [2 != 0] ]]> </Error> <TestingTime>0</TestingTime> </TestCase> </TestSuite> </TestLog> Any idea why it does not work?
          Hide
          gbois Gregory Boissinot added a comment -

          I'll look at it.
          Additionally, could you give the boost version?

          Show
          gbois Gregory Boissinot added a comment - I'll look at it. Additionally, could you give the boost version?
          Hide
          eldaryus Eldar Yusupov added a comment -

          We are using boost v1.45. Thank you.

          Show
          eldaryus Eldar Yusupov added a comment - We are using boost v1.45. Thank you.
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Gregory Boissinot
          Path:
          pom.xml
          http://jenkins-ci.org/commit/xunit-plugin/e915aabf3fe31a68d8ce11c24a1abd69834e42fe
          Log:
          Fixed JENKINS-11344

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Gregory Boissinot Path: pom.xml http://jenkins-ci.org/commit/xunit-plugin/e915aabf3fe31a68d8ce11c24a1abd69834e42fe Log: Fixed JENKINS-11344
          Hide
          gbois Gregory Boissinot added a comment -

          Available in 1.24

          Show
          gbois Gregory Boissinot added a comment - Available in 1.24
          Hide
          chris42 Christoph Torens added a comment - - edited

          Hi,
          i am using boost 1.45 and the latest version of xunit plugin. It seems that boost messages are still not parsed correctly if they appear out of a <test case>

          for example the following xml snippet produces an error, but cut/paste into a <test case>
          it works:

          <Message file="unittests2/main.cpp" line="111"><![CDATA[global unit test setup
            testing started at Monday, 22nd of october, 2012, 8:26:46.257000
            test log:   'log/mission.test.release.win32.vc.2012-10-22_08h26m46s.log'
          ]]></Message>
          <TestLog>
          	<TestSuite name="Master Test Suite">
          

          best regards

          Show
          chris42 Christoph Torens added a comment - - edited Hi, i am using boost 1.45 and the latest version of xunit plugin. It seems that boost messages are still not parsed correctly if they appear out of a <test case> for example the following xml snippet produces an error, but cut/paste into a <test case> it works: <Message file= "unittests2/main.cpp" line= "111" ><![CDATA[global unit test setup testing started at Monday, 22nd of october, 2012, 8:26:46.257000 test log: 'log/mission.test.release.win32.vc.2012-10-22_08h26m46s.log' ]]></Message> <TestLog> <TestSuite name= "Master Test Suite" > best regards
          Hide
          gbois Gregory Boissinot added a comment -

          Hi Christoph,
          Could you attach a complete test file with your use case?
          Thanks

          Show
          gbois Gregory Boissinot added a comment - Hi Christoph, Could you attach a complete test file with your use case? Thanks
          Hide
          gbois Gregory Boissinot added a comment -

          Missing a full wrong test result.

          Show
          gbois Gregory Boissinot added a comment - Missing a full wrong test result.

            People

            • Assignee:
              gbois Gregory Boissinot
              Reporter:
              eldaryus Eldar Yusupov
            • Votes:
              2 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: