[Issue 1323] New - Cobertura configuration inconsistent when using CVS

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

[Issue 1323] New - Cobertura configuration inconsistent when using CVS

mpilone
https://hudson.dev.java.net/issues/show_bug.cgi?id=1323
                 Issue #|1323
                 Summary|Cobertura configuration inconsistent when using CVS
               Component|hudson
                 Version|current
                Platform|All
              OS/Version|All
                     URL|
                  Status|NEW
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P4
            Subcomponent|cobertura
             Assigned to|stephenconnolly
             Reported by|mpilone






------- Additional comments from [hidden email] Wed Feb 20 19:05:57 +0000 2008 -------
I was having a problem with the cobertura plugin in Hudson so I did some digging
through the code. I found that when using CVS the search path is relative to the
first module. Issue 916 discusses this, but it looks like the implemented hack
only supports subversion and not CVS:

197            if (project.getScm() instanceof SubversionSCM) {
198                 // hack of the first kind
199                 SubversionSCM scm = SubversionSCM.class.cast(project.getScm());
200                 multipleModuleRoots = scm.getLocations().length > 1;
201             } else {
202                 multipleModuleRoots = false;
203             }

I could work around this if the includes supported '..', but as issue 916 points
out, that doesn't work either. So I've worked around it by copying the
coverage.xml file to the first module in my Job config, but others may have the
same problem.

The SCM interface now supports getting the root module, but that returns the
first module in the CVS implementation. The documentation on the Cobertura
plugin describes how SVN works with multiple modules, but it isn't clear about
CVS (which also supports multiple modules).

Maybe the right solution would be to apply the search path to each module
defined in order until a match is found or if there are multiple modules
(regardless of the SCM used), switch to using the workspace as the root.

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Issue 1323] Cobertura configuration inconsistent when using CVS

davidmc24-2
https://hudson.dev.java.net/issues/show_bug.cgi?id=1323



User davidmc24 changed the following:

                What    |Old value                 |New value
================================================================================
             Assigned to|stephenconnolly           |davidmc24
--------------------------------------------------------------------------------




------- Additional comments from [hidden email] Thu Jun 11 02:03:36 +0000 2009 -------
I'll work on this issue.  It makes sense that the behavior should be consistent across all SCMs that support
multiple modules, rather than treating Subversion differently.  Thus, I'm planning on making it such that if
the SCM says that there are multiple module roots, the default base directory will be the workspace.

Also, note that there is now an enhancement ticket (3862) for the ability to configure where the base
directory should be, to support cases where the default value isn't what the user needs.

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Issue 1323] Cobertura configuration inconsistent when using CVS

scm_issue_link
In reply to this post by mpilone
https://hudson.dev.java.net/issues/show_bug.cgi?id=1323



User scm_issue_link changed the following:

                What    |Old value                 |New value
================================================================================
                  Status|NEW                       |RESOLVED
--------------------------------------------------------------------------------
              Resolution|                          |FIXED
--------------------------------------------------------------------------------




------- Additional comments from [hidden email] Wed Jul  8 01:38:47 +0000 2009 -------
Code changed in hudson
User: : davidmc24
Path:
 trunk/hudson/plugins/cobertura/pom.xml
 trunk/hudson/plugins/cobertura/src/main/java/hudson/plugins/cobertura/CoberturaPublisher.java
 trunk/hudson/plugins/cobertura/src/main/resources/hudson/plugins/cobertura/CoberturaPublisher/config.jelly
http://fisheye4.cenqua.com/changelog/hudson/?cs=19514
Log:
Removed Cobertura plugin's dependency on Subversion.
[FIXED HUDSON-1323] Now the Cobertura plugin will treat all multi-module SCMs equally.  If multiple modules are configured, the coverage XML pattern will be resolved relative to the workspace, as opposed to the module root.  Previously, this behavior was hardcoded to only apply to Subversion.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Issue 1323] Cobertura configuration inconsistent when using CVS

davidmc24-2
In reply to this post by mpilone
https://hudson.dev.java.net/issues/show_bug.cgi?id=1323






------- Additional comments from [hidden email] Wed Jul  8 04:21:47 +0000 2009 -------
Included in Cobertura plugin version 0.8.9

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]