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

Plugin does not handle missing suite names

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • robot-plugin
    • None
    • 3.4.0

      if a test suite is named something like A_test_suite__.robot, then the output.xml does not contain name attribute at all.

      Although weird, it seems rebot happily parses this kind of suite without problem generating log.html and report.html.

      However, the plugin fails with:

      Robot results publisher started...
      -Parsing output xml:
      Done!
      -Copying log files to build dir:
      Done!
      -Assigning results to build:
      ERROR: Build step failed with exception
      java.lang.NullPointerException
      	at java.lang.StringBuilder.<init>(StringBuilder.java:117)
      	at hudson.plugins.robot.model.RobotTestObject.getRelativePackageName(RobotTestObject.java:101)
      	at hudson.plugins.robot.model.RobotTestObject.getRelativeParent(RobotTestObject.java:113)
      	at hudson.plugins.robot.model.RobotTestObject.getRelativePackageName(RobotTestObject.java:102)
      	at hudson.plugins.robot.model.RobotCaseComparator.compare(RobotCaseComparator.java:37)
      	at hudson.plugins.robot.model.RobotCaseComparator.compare(RobotCaseComparator.java:21)
      	at java.util.TimSort.countRunAndMakeAscending(TimSort.java:355)
      	at java.util.TimSort.sort(TimSort.java:220)
      	at java.util.Arrays.sort(Arrays.java:1512)
      	at java.util.ArrayList.sort(ArrayList.java:1464)
      	at java.util.Collections.sort(Collections.java:177)
      	at hudson.plugins.robot.model.RobotSuiteResult.getCaseResults(RobotSuiteResult.java:125)
      	at hudson.plugins.robot.model.RobotSuiteResult.tally(RobotSuiteResult.java:395)
      	at hudson.plugins.robot.model.RobotSuiteResult.tally(RobotSuiteResult.java:413)
      	at hudson.plugins.robot.model.RobotResult.tally(RobotResult.java:422)
      	at hudson.plugins.robot.RobotBuildAction.setResult(RobotBuildAction.java:124)
      	at hudson.plugins.robot.RobotBuildAction.<init>(RobotBuildAction.java:95)
      	at hudson.plugins.robot.RobotPublisher.perform(RobotPublisher.java:291)
      	at jenkins.tasks.SimpleBuildStep.perform(SimpleBuildStep.java:123)
      	at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)
      	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:816)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:765)
      	at hudson.model.Build$BuildExecution.post2(Build.java:179)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:709)
      	at hudson.model.Run.execute(Run.java:1922)
      	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
      	at hudson.model.ResourceController.execute(ResourceController.java:101)
      	at hudson.model.Executor.run(Executor.java:442)
      Build step 'Publish Robot Framework test results' marked build as failure
      Finished: FAILURE 

      Given plugin's parser does not parse something that rebot parses, we probably need to fix this

            tattoo Tatu Kairi
            tattoo Tatu Kairi
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: