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

RSpec XML output processing could be improved to avoid hard-to-diagnose problems

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major Major
    • junit-plugin
    • None
    • Platform: All, OS: All

      [I currently have Hudson ver. 1.320]

      I run Ruby Selenium tests via RSpec (run in a rake task), my tests generate XML
      output (using ci_reporter, http://github.com/nicksieger/ci_reporter), which I
      use Hudson's "Publish JUnit test result report" feature to process.

      I was having sporadic problems with XML processing (sometimes it worked fine,
      sometimes it didn't) until I figured out that the problem occurred when I
      included a period in the describe statement of an RSpec example.

      If a build completed with test failures, the path to the test result output (the
      link with the test name, in the "test result" page) was incorrectly set so the
      link would be pointing to an invalid address and I would get a 404 error. I have
      created an example below to easily repro the problem.

      describe 'A period at the end of this sentence breaks xml processing.' do
      it 'a dummy spec method.' do
      (2 + 2).should == 5
      end
      end

      If this test is run in Hudson and the xml output generated (via ci_reporter) is
      processed by Hudson, you should see the problem when attempting to view the test
      results.

      [Note: a period in the "it .. do" statement does not seem to cause any problem.]

      I didn't log this as a defect as I doubt hudson was designed to handle this
      case. However, it would be great if this case could be handled, as it was
      difficult to determine the cause of my problems, and the XML processing for
      RSpec/ci_reporter output works great otherwise.

            Unassigned Unassigned
            dlillis dlillis
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated: