• Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • cobertura-plugin
    • Windows 7

      coverage.xml contains filename attributes.
      If this attribute is absolute based on hudson.FilePath implementation,
      canvas FilePath object is created as absolute and outside of the intended cobertura job directory. SourceCodePainter overwrites this file in paintSourceCode().

      Attached is a very simple patch, pointing to the problem.
      coverage.xml is produced on Windows by patched gcovr.py using QNX cross compiler tools. It is simplified for testing.

          [JENKINS-16252] SourceCodePainter overwrites original files

          Code changed in jenkins
          User: ssogabe
          Path:
          src/main/java/hudson/plugins/cobertura/CoberturaCoverageParser.java
          src/test/java/hudson/plugins/cobertura/CoberturaCoverageParserTest.java
          src/test/resources/hudson/plugins/cobertura/coverage_16252.xml
          http://jenkins-ci.org/commit/cobertura-plugin/a024c9843ef42709058fcf4a253b9343de8ef546
          Log:
          [FIXED JENKINS-16252] filename in xml should be relative

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: ssogabe Path: src/main/java/hudson/plugins/cobertura/CoberturaCoverageParser.java src/test/java/hudson/plugins/cobertura/CoberturaCoverageParserTest.java src/test/resources/hudson/plugins/cobertura/coverage_16252.xml http://jenkins-ci.org/commit/cobertura-plugin/a024c9843ef42709058fcf4a253b9343de8ef546 Log: [FIXED JENKINS-16252] filename in xml should be relative

            sogabe sogabe
            myukselen Murat Yukselen
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: