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

No history for test cases where name of suite is part of test case name

XMLWordPrintable

      If the name of test suite (e.g. "aaaa") is part of the test case name (e.g. "tc_aaaa"), Jenkins is unable to display history of this test case and throws an exeption:

      Oct 2, 2012 5:06:15 PM hudson.ExpressionFactory2$JexlExpression evaluate
      WARNING: Caught exception evaluating: it.getResultInBuild(b). Reason: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
      java.lang.StringIndexOutOfBoundsException: String index out of range: -1
      at java.lang.String.substring(Unknown Source)
      at java.lang.String.substring(Unknown Source)
      at hudson.tasks.junit.ClassResult.findCorrespondingResult(ClassResult.java:86)
      at hudson.tasks.junit.PackageResult.findCorrespondingResult(PackageResult.java:102)
      at hudson.tasks.junit.TestResult.findCorrespondingResult(TestResult.java:295)
      at hudson.tasks.test.AbstractTestResultAction.findCorrespondingResult(AbstractTestResultAction.java:183)
      at hudson.tasks.test.TestResult.getResultInBuild(TestResult.java:162)

      (full log can be found in attachment log.txt)

      I´ve attached the test results file (junit.xml) with which this behavior can be reproduced.

        1. tc_xaaaax.jpg
          tc_xaaaax.jpg
          18 kB
        2. tc_bbbb.jpg
          tc_bbbb.jpg
          29 kB
        3. tc_aaaa.jpg
          tc_aaaa.jpg
          16 kB
        4. log.txt
          11 kB
        5. junit3.xml
          0.3 kB
        6. junit2.xml
          0.3 kB
        7. junit.xml
          0.3 kB

            thesam Samuel Moritz
            hjhafner Hans-Juergen Hafner
            Votes:
            2 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated: