You can subscribe to this list here.
2005 |
Jan
|
Feb
|
Mar
(66) |
Apr
(29) |
May
(85) |
Jun
(66) |
Jul
(24) |
Aug
(139) |
Sep
(72) |
Oct
(26) |
Nov
(142) |
Dec
(34) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(55) |
Feb
(72) |
Mar
(43) |
Apr
(60) |
May
(95) |
Jun
(22) |
Jul
(48) |
Aug
(17) |
Sep
(54) |
Oct
(30) |
Nov
(82) |
Dec
(17) |
2007 |
Jan
(23) |
Feb
(38) |
Mar
(46) |
Apr
(12) |
May
(77) |
Jun
(77) |
Jul
(94) |
Aug
(51) |
Sep
(38) |
Oct
(57) |
Nov
(39) |
Dec
(67) |
2008 |
Jan
(38) |
Feb
(56) |
Mar
(42) |
Apr
(46) |
May
(37) |
Jun
(43) |
Jul
(52) |
Aug
(22) |
Sep
(22) |
Oct
(34) |
Nov
(37) |
Dec
(29) |
2009 |
Jan
(27) |
Feb
(35) |
Mar
(67) |
Apr
(37) |
May
(31) |
Jun
(79) |
Jul
(71) |
Aug
(59) |
Sep
(31) |
Oct
(47) |
Nov
(36) |
Dec
(7) |
2010 |
Jan
(15) |
Feb
(87) |
Mar
(38) |
Apr
(33) |
May
(24) |
Jun
(47) |
Jul
(26) |
Aug
(28) |
Sep
(33) |
Oct
(13) |
Nov
(8) |
Dec
(36) |
2011 |
Jan
(32) |
Feb
(10) |
Mar
(29) |
Apr
(29) |
May
(17) |
Jun
(14) |
Jul
(33) |
Aug
(11) |
Sep
(7) |
Oct
(7) |
Nov
(6) |
Dec
(10) |
2012 |
Jan
(19) |
Feb
(12) |
Mar
(16) |
Apr
(6) |
May
(18) |
Jun
(18) |
Jul
(31) |
Aug
(25) |
Sep
|
Oct
(31) |
Nov
(21) |
Dec
(9) |
2013 |
Jan
(8) |
Feb
(16) |
Mar
(8) |
Apr
(7) |
May
(3) |
Jun
(29) |
Jul
(29) |
Aug
|
Sep
(7) |
Oct
(9) |
Nov
(1) |
Dec
(1) |
2014 |
Jan
(3) |
Feb
(4) |
Mar
|
Apr
(13) |
May
(8) |
Jun
(5) |
Jul
(2) |
Aug
(4) |
Sep
(4) |
Oct
(2) |
Nov
|
Dec
(2) |
2015 |
Jan
(1) |
Feb
|
Mar
(2) |
Apr
|
May
(2) |
Jun
(1) |
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2016 |
Jan
(2) |
Feb
|
Mar
|
Apr
(1) |
May
(1) |
Jun
(3) |
Jul
(3) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
(2) |
Feb
|
Mar
(1) |
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2018 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2025 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: John W. L. <Joh...@sa...> - 2010-12-31 00:15:31
|
There is a difference between ignore and exclude. Here is the relevant paragraph in the ant documentation: "You can tell Cobertura to ignore certain classes by passing in "ignore" regular expressions. The ignore pattern can be any valid perl 5 regular expression. This will ignore any calls to any method that matches the ignore regular expression. It will NOT skip over these classes during instrumention. To exclude classes from being instrumented, either exclude them from your fileset or use the alternative method below and specify an excludeClasses pattern." So, ignore is used to ignore lines of codes that have particular method calls. It sounds like you are interested in excluding. So try specifying the classes you wish to exclude using the <exclude>. Something like com/package/to/exclude/*.class. Unfortunately, I don't know a great deal about the maven plugin. It was developed by a different group. But, I will do what I can. John -----Original Message----- From: Pau...@us... [mailto:Pau...@us...] Sent: Thursday, December 30, 2010 4:47 PM To: cob...@li... Subject: [Cobertura-devel] Excluding Classes and or Packages from the coverage report Is there a way to exclude or ignore particular Classes or packages from the coverage report? I have tried to do the below but it looks like it is not working. <configuration> <instrumentation> <ignores> <ignore>com.package.to.exclude.*</ignore> </ignores> <excludes> <exclude>com/package/to/exclude/testtoexclude.class</exclude> </excludes> </instrumentation> </configuration> Thanks Paul ------------------------------------------------------------------------------ Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ Cobertura-devel mailing list Cob...@li... https://lists.sourceforge.net/lists/listinfo/cobertura-devel |
From: <Pau...@us...> - 2010-12-30 21:47:52
|
Is there a way to exclude or ignore particular Classes or packages from the coverage report? I have tried to do the below but it looks like it is not working. <configuration> <instrumentation> <ignores> <ignore>com.package.to.exclude.*</ignore> </ignores> <excludes> <exclude>com/package/to/exclude/testtoexclude.class</exclude> </excludes> </instrumentation> </configuration> Thanks Paul |
From: Steven C. <ste...@re...> - 2010-12-30 16:59:29
|
Is there a way we could get the coverage result percentage to allow for decimal precision, implement a new feature like in the .bat file have --precision 4, and it would do the percentages to 4 decimal places? When I saw 0% coverage, I assumed no coverage at all, but that's not the case. 0.13% > 0% On 12/30/2010 10:48 AM, Piotr Tabor wrote: > I think that rounding/truncating here is right. 0.13% is 0. > > Piotr > > On Thu, Dec 30, 2010 at 5:09 PM, Steven Christou > <ste...@re... > <mailto:ste...@re...>> wrote: > > I know the percentage is HORRIBLE. This is new feature development I'm > working on. Getting it to work was a tough task alone, but testing > with > cobertura shows I have a lot of testing development to do! I was > wondering if it should still produce 0% coverage, even though > there are > a few lines of code that are hit. If you want, I can take a look > at the > code base and provide a fix, and submit it. I've been wanting to > contribute for a while now :) > > On 12/30/2010 2:26 AM, John W. Lewis wrote: > > 3/2300 gives you 0.13%. I assume it is being rounded/truncated > to the nearest percentage point. > > > > The most horrible thing about it is that there is no more than > 1% coverage. :) > > > > I'm glad you got it working. > > > > -----Original Message----- > > From: Steven Christou [mailto:ste...@re... > <mailto:ste...@re...>] > > Sent: Wednesday, December 29, 2010 7:25 PM > > To: cob...@li... > <mailto:cob...@li...> > > Subject: [Cobertura-devel] Possible bug in html reporting file > > > > I believe I might have found a bug in the HTML format report. If > you have a file that has about 3 lines of coverage, but contains > about 2300 lines of code (I know this is HORRIBLE), it produces a > result of 0% coverage. I assume it should be producing a result of > 1%, because there still is coverage in the file, it's just not a > lot of coverage. > > Email Disclaimer: > > http://www.redprairie.com/emaildisclaimer/ > > > > > > > ------------------------------------------------------------------------------ > > Learn how Oracle Real Application Clusters (RAC) One Node allows > customers to consolidate database storage, standardize their > database environment, and, should the need arise, upgrade to a > full multi-node Oracle RAC database without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > > _______________________________________________ > > Cobertura-devel mailing list > > Cob...@li... > <mailto:Cob...@li...> > > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > > > Email Disclaimer: > http://www.redprairie.com/emaildisclaimer/ > > > ------------------------------------------------------------------------------ > Learn how Oracle Real Application Clusters (RAC) One Node allows > customers > to consolidate database storage, standardize their database > environment, and, > should the need arise, upgrade to a full multi-node Oracle RAC > database > without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > <mailto:Cob...@li...> > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > > > > > -- > Pozdrawiam, > Piotr Tabor Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: Piotr T. <pi...@ta...> - 2010-12-30 16:48:52
|
I think that rounding/truncating here is right. 0.13% is 0. Piotr On Thu, Dec 30, 2010 at 5:09 PM, Steven Christou < ste...@re...> wrote: > I know the percentage is HORRIBLE. This is new feature development I'm > working on. Getting it to work was a tough task alone, but testing with > cobertura shows I have a lot of testing development to do! I was > wondering if it should still produce 0% coverage, even though there are > a few lines of code that are hit. If you want, I can take a look at the > code base and provide a fix, and submit it. I've been wanting to > contribute for a while now :) > > On 12/30/2010 2:26 AM, John W. Lewis wrote: > > 3/2300 gives you 0.13%. I assume it is being rounded/truncated to the > nearest percentage point. > > > > The most horrible thing about it is that there is no more than 1% > coverage. :) > > > > I'm glad you got it working. > > > > -----Original Message----- > > From: Steven Christou [mailto:ste...@re...] > > Sent: Wednesday, December 29, 2010 7:25 PM > > To: cob...@li... > > Subject: [Cobertura-devel] Possible bug in html reporting file > > > > I believe I might have found a bug in the HTML format report. If you have > a file that has about 3 lines of coverage, but contains about 2300 lines of > code (I know this is HORRIBLE), it produces a result of 0% coverage. I > assume it should be producing a result of 1%, because there still is > coverage in the file, it's just not a lot of coverage. > > Email Disclaimer: > > http://www.redprairie.com/emaildisclaimer/ > > > > > > > ------------------------------------------------------------------------------ > > Learn how Oracle Real Application Clusters (RAC) One Node allows > customers to consolidate database storage, standardize their database > environment, and, should the need arise, upgrade to a full multi-node Oracle > RAC database without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > > _______________________________________________ > > Cobertura-devel mailing list > > Cob...@li... > > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > > > Email Disclaimer: > http://www.redprairie.com/emaildisclaimer/ > > > > ------------------------------------------------------------------------------ > Learn how Oracle Real Application Clusters (RAC) One Node allows customers > to consolidate database storage, standardize their database environment, > and, > should the need arise, upgrade to a full multi-node Oracle RAC database > without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > -- Pozdrawiam, Piotr Tabor |
From: Steven C. <ste...@re...> - 2010-12-30 16:09:36
|
I know the percentage is HORRIBLE. This is new feature development I'm working on. Getting it to work was a tough task alone, but testing with cobertura shows I have a lot of testing development to do! I was wondering if it should still produce 0% coverage, even though there are a few lines of code that are hit. If you want, I can take a look at the code base and provide a fix, and submit it. I've been wanting to contribute for a while now :) On 12/30/2010 2:26 AM, John W. Lewis wrote: > 3/2300 gives you 0.13%. I assume it is being rounded/truncated to the nearest percentage point. > > The most horrible thing about it is that there is no more than 1% coverage. :) > > I'm glad you got it working. > > -----Original Message----- > From: Steven Christou [mailto:ste...@re...] > Sent: Wednesday, December 29, 2010 7:25 PM > To: cob...@li... > Subject: [Cobertura-devel] Possible bug in html reporting file > > I believe I might have found a bug in the HTML format report. If you have a file that has about 3 lines of coverage, but contains about 2300 lines of code (I know this is HORRIBLE), it produces a result of 0% coverage. I assume it should be producing a result of 1%, because there still is coverage in the file, it's just not a lot of coverage. > Email Disclaimer: > http://www.redprairie.com/emaildisclaimer/ > > > ------------------------------------------------------------------------------ > Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: John W. L. <Joh...@sa...> - 2010-12-30 08:26:12
|
3/2300 gives you 0.13%. I assume it is being rounded/truncated to the nearest percentage point. The most horrible thing about it is that there is no more than 1% coverage. :) I'm glad you got it working. -----Original Message----- From: Steven Christou [mailto:ste...@re...] Sent: Wednesday, December 29, 2010 7:25 PM To: cob...@li... Subject: [Cobertura-devel] Possible bug in html reporting file I believe I might have found a bug in the HTML format report. If you have a file that has about 3 lines of coverage, but contains about 2300 lines of code (I know this is HORRIBLE), it produces a result of 0% coverage. I assume it should be producing a result of 1%, because there still is coverage in the file, it's just not a lot of coverage. Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ ------------------------------------------------------------------------------ Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ Cobertura-devel mailing list Cob...@li... https://lists.sourceforge.net/lists/listinfo/cobertura-devel |
From: Steven C. <ste...@re...> - 2010-12-30 00:25:34
|
I believe I might have found a bug in the HTML format report. If you have a file that has about 3 lines of coverage, but contains about 2300 lines of code (I know this is HORRIBLE), it produces a result of 0% coverage. I assume it should be producing a result of 1%, because there still is coverage in the file, it's just not a lot of coverage. Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: Steven C. <ste...@re...> - 2010-12-29 22:10:57
|
I'm sorry, I finally figured out my answer. The problem is that a windows service starts in c:\windows\system32, which is where conhost.exe is located (that's the executable that starts a windows service). The cobertura.ser file was located in this folder and I didn't notice that, so every time I was doing a flush, or even stopping the service, it was always reporting successfully, just in a location I did not expect. Thanks again, Steve On 12/29/2010 1:38 PM, John W. Lewis wrote: > There is another way that is used for webapps. There is a coberturaFlush.war file that can be loaded by a web server. Then, a URL can be retrieved that will cause a flush. > > The bottom line is that the process that runs the test either has to do the flush, or it has to listen for a flush request. Cobertura does not listen for a request at the moment. > > John > > > -----Original Message----- > From: Steven Christou [mailto:ste...@re...] > Sent: Wednesday, December 29, 2010 11:28 AM > To: John W. Lewis > Cc: cob...@li... > Subject: Re: [Cobertura-devel] Invoking Cobertura to report in source code > > Is there absolutely no other way to force a dump without making modification to my code. I would try if all possible to avoid making modifications like this to my code. The timer that saves data sounds very interesting, or might be what I'm looking for, although the patch still is open which leads me to believe that there is still work to be done with it. > Thanks. > > On 12/28/2010 2:51 PM, John W. Lewis wrote: >> The FAQ tells how you can dump the data before shutdown. >> >> -----Original Message----- >> From: Steven Christou [mailto:ste...@re...] >> Sent: Tuesday, December 28, 2010 2:50 PM >> To: John W. Lewis >> Cc: cob...@li... >> Subject: Re: [Cobertura-devel] Invoking Cobertura to report in source >> code >> >> I was thinking about a possible solution to this. I was wondering if it would be possible to write like a "flush" .bat file. When this .bat file is called, it will do an automatic flush of all the data, rather than expecting shutdown hooks to execute. If you run an application as a windows service, it will fail to execute any shutdown hooks(that's what's been happening with me at least). Either this, or right before a report file is generated it could do a flush of all the data, to make sure all the data is gathered. I might be talking over my head on this one but this is what I was thinking when instrumented items run currently: >> >> run application -> cobertura starts writing to .class files -> >> shutdown hook executes -> .class file writes to .ser file -> done >> >> >> On 7/7/2010 9:31 AM, John W. Lewis wrote: >>> Please see the last question in the FAQ. >>> >>> http://cobertura.sourceforge.net/faq.html >>> >>> >>> >>> -----Original Message----- >>> From: Steven Christou [mailto:ste...@re...] >>> Sent: Wednesday, July 07, 2010 9:51 AM >>> To: cob...@li... >>> Subject: [Cobertura-devel] Invoking Cobertura to report in source >>> code >>> >>> Hello, >>> In the product I am working on, we are doing a Process.destroy() >>> which essentially destroys the JVM and does not allow for shutdown >>> hooks to be ran. Since no shutdown hooks can be ran, cobertura fails >>> to run and produce the results we want. I was wondering if there was >>> a way we could have it produce results right before we do the call to >>> the Process.destroy()? >>> Thanks! >>> Email Disclaimer: >>> http://www.redprairie.com/emaildisclaimer/ >>> >>> >>> --------------------------------------------------------------------- >>> --------- This SF.net email is sponsored by Sprint What will you do >>> first with EVO, the first 4G phone? >>> Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first >>> _______________________________________________ >>> Cobertura-devel mailing list >>> Cob...@li... >>> https://lists.sourceforge.net/lists/listinfo/cobertura-devel >>> >> Email Disclaimer: >> http://www.redprairie.com/emaildisclaimer/ >> >> >> > Email Disclaimer: > http://www.redprairie.com/emaildisclaimer/ > > > Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: John W. L. <Joh...@sa...> - 2010-12-29 19:54:00
|
There is another way that is used for webapps. There is a coberturaFlush.war file that can be loaded by a web server. Then, a URL can be retrieved that will cause a flush. The bottom line is that the process that runs the test either has to do the flush, or it has to listen for a flush request. Cobertura does not listen for a request at the moment. John -----Original Message----- From: Steven Christou [mailto:ste...@re...] Sent: Wednesday, December 29, 2010 11:28 AM To: John W. Lewis Cc: cob...@li... Subject: Re: [Cobertura-devel] Invoking Cobertura to report in source code Is there absolutely no other way to force a dump without making modification to my code. I would try if all possible to avoid making modifications like this to my code. The timer that saves data sounds very interesting, or might be what I'm looking for, although the patch still is open which leads me to believe that there is still work to be done with it. Thanks. On 12/28/2010 2:51 PM, John W. Lewis wrote: > The FAQ tells how you can dump the data before shutdown. > > -----Original Message----- > From: Steven Christou [mailto:ste...@re...] > Sent: Tuesday, December 28, 2010 2:50 PM > To: John W. Lewis > Cc: cob...@li... > Subject: Re: [Cobertura-devel] Invoking Cobertura to report in source > code > > I was thinking about a possible solution to this. I was wondering if it would be possible to write like a "flush" .bat file. When this .bat file is called, it will do an automatic flush of all the data, rather than expecting shutdown hooks to execute. If you run an application as a windows service, it will fail to execute any shutdown hooks(that's what's been happening with me at least). Either this, or right before a report file is generated it could do a flush of all the data, to make sure all the data is gathered. I might be talking over my head on this one but this is what I was thinking when instrumented items run currently: > > run application -> cobertura starts writing to .class files -> > shutdown hook executes -> .class file writes to .ser file -> done > > > On 7/7/2010 9:31 AM, John W. Lewis wrote: >> Please see the last question in the FAQ. >> >> http://cobertura.sourceforge.net/faq.html >> >> >> >> -----Original Message----- >> From: Steven Christou [mailto:ste...@re...] >> Sent: Wednesday, July 07, 2010 9:51 AM >> To: cob...@li... >> Subject: [Cobertura-devel] Invoking Cobertura to report in source >> code >> >> Hello, >> In the product I am working on, we are doing a Process.destroy() >> which essentially destroys the JVM and does not allow for shutdown >> hooks to be ran. Since no shutdown hooks can be ran, cobertura fails >> to run and produce the results we want. I was wondering if there was >> a way we could have it produce results right before we do the call to >> the Process.destroy()? >> Thanks! >> Email Disclaimer: >> http://www.redprairie.com/emaildisclaimer/ >> >> >> --------------------------------------------------------------------- >> --------- This SF.net email is sponsored by Sprint What will you do >> first with EVO, the first 4G phone? >> Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first >> _______________________________________________ >> Cobertura-devel mailing list >> Cob...@li... >> https://lists.sourceforge.net/lists/listinfo/cobertura-devel >> > Email Disclaimer: > http://www.redprairie.com/emaildisclaimer/ > > > Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: Steven C. <ste...@re...> - 2010-12-29 17:03:58
|
If you want, there is a plugin for Hudson which produces method level coverage reports. http://wiki.hudson-ci.org/display/HUDSON/Cobertura+Plugin I currently am using this, and it will state something like: Methods 60% 60/100 On 12/29/2010 10:54 AM, Daniel Polkinghorne wrote: > > Hello, > > I've just moved over from EMMA, and Cobertura seems nice (and its > really simple) but my project needs method level coverage stats in > reports. Is it possible to customize the report in this (or any) way? > > I've looked for documentation, but the few pages on the project site > seem to be the extent of it. Are there any more detailed docs out there? > > Congrats on a great tool. > > Cheers, > > Dan > > ------------------------------------------------------------------------ > The information included in this email and any files transmitted with > it may contain information that is confidential and it must not be > used by, or its contents or attachments copied or disclosed, to > persons other than the intended addressee. If you have received this > email in error, please notify BJSS. In the absence of written > agreement to the contrary BJSS' relevant standard terms of contract > for any work to be undertaken will apply. Please carry out virus or > such other checks as you consider appropriate in respect of this > email. BJSS do not accept responsibility for any adverse effect upon > your system or data in relation to this email or any files transmitted > with it. BJSS Limited, a company registered in England and Wales > (Company Number 2777575), VAT Registration Number 613295452, > Registered Office Address, First Floor, Coronet House, Queen Street, > Leeds, LS1 2TW > > > ------------------------------------------------------------------------------ > Learn how Oracle Real Application Clusters (RAC) One Node allows customers > to consolidate database storage, standardize their database environment, and, > should the need arise, upgrade to a full multi-node Oracle RAC database > without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > > > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: Daniel P. <Dan...@bj...> - 2010-12-29 16:55:01
|
Hello, I've just moved over from EMMA, and Cobertura seems nice (and its really simple) but my project needs method level coverage stats in reports. Is it possible to customize the report in this (or any) way? I've looked for documentation, but the few pages on the project site seem to be the extent of it. Are there any more detailed docs out there? Congrats on a great tool. Cheers, Dan The information included in this email and any files transmitted with it may contain information that is confidential and it must not be used by, or its contents or attachments copied or disclosed, to persons other than the intended addressee. If you have received this email in error, please notify BJSS. In the absence of written agreement to the contrary BJSS' relevant standard terms of contract for any work to be undertaken will apply. Please carry out virus or such other checks as you consider appropriate in respect of this email. BJSS do not accept responsibility for any adverse effect upon your system or data in relation to this email or any files transmitted with it. BJSS Limited, a company registered in England and Wales (Company Number 2777575), VAT Registration Number 613295452, Registered Office Address, First Floor, Coronet House, Queen Street, Leeds, LS1 2TW |
From: Steven C. <ste...@re...> - 2010-12-29 16:28:01
|
Is there absolutely no other way to force a dump without making modification to my code. I would try if all possible to avoid making modifications like this to my code. The timer that saves data sounds very interesting, or might be what I'm looking for, although the patch still is open which leads me to believe that there is still work to be done with it. Thanks. On 12/28/2010 2:51 PM, John W. Lewis wrote: > The FAQ tells how you can dump the data before shutdown. > > -----Original Message----- > From: Steven Christou [mailto:ste...@re...] > Sent: Tuesday, December 28, 2010 2:50 PM > To: John W. Lewis > Cc: cob...@li... > Subject: Re: [Cobertura-devel] Invoking Cobertura to report in source code > > I was thinking about a possible solution to this. I was wondering if it would be possible to write like a "flush" .bat file. When this .bat file is called, it will do an automatic flush of all the data, rather than expecting shutdown hooks to execute. If you run an application as a windows service, it will fail to execute any shutdown hooks(that's what's been happening with me at least). Either this, or right before a report file is generated it could do a flush of all the data, to make sure all the data is gathered. I might be talking over my head on this one but this is what I was thinking when instrumented items run currently: > > run application -> cobertura starts writing to .class files -> shutdown hook executes -> .class file writes to .ser file -> done > > > On 7/7/2010 9:31 AM, John W. Lewis wrote: >> Please see the last question in the FAQ. >> >> http://cobertura.sourceforge.net/faq.html >> >> >> >> -----Original Message----- >> From: Steven Christou [mailto:ste...@re...] >> Sent: Wednesday, July 07, 2010 9:51 AM >> To: cob...@li... >> Subject: [Cobertura-devel] Invoking Cobertura to report in source code >> >> Hello, >> In the product I am working on, we are doing a Process.destroy() which >> essentially destroys the JVM and does not allow for shutdown hooks to be >> ran. Since no shutdown hooks can be ran, cobertura fails to run and >> produce the results we want. I was wondering if there was a way we could >> have it produce results right before we do the call to the >> Process.destroy()? >> Thanks! >> Email Disclaimer: >> http://www.redprairie.com/emaildisclaimer/ >> >> >> ------------------------------------------------------------------------------ >> This SF.net email is sponsored by Sprint >> What will you do first with EVO, the first 4G phone? >> Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first >> _______________________________________________ >> Cobertura-devel mailing list >> Cob...@li... >> https://lists.sourceforge.net/lists/listinfo/cobertura-devel >> > Email Disclaimer: > http://www.redprairie.com/emaildisclaimer/ > > > Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: John W. L. <Joh...@sa...> - 2010-12-28 21:07:05
|
The FAQ tells how you can dump the data before shutdown. -----Original Message----- From: Steven Christou [mailto:ste...@re...] Sent: Tuesday, December 28, 2010 2:50 PM To: John W. Lewis Cc: cob...@li... Subject: Re: [Cobertura-devel] Invoking Cobertura to report in source code I was thinking about a possible solution to this. I was wondering if it would be possible to write like a "flush" .bat file. When this .bat file is called, it will do an automatic flush of all the data, rather than expecting shutdown hooks to execute. If you run an application as a windows service, it will fail to execute any shutdown hooks(that's what's been happening with me at least). Either this, or right before a report file is generated it could do a flush of all the data, to make sure all the data is gathered. I might be talking over my head on this one but this is what I was thinking when instrumented items run currently: run application -> cobertura starts writing to .class files -> shutdown hook executes -> .class file writes to .ser file -> done On 7/7/2010 9:31 AM, John W. Lewis wrote: > Please see the last question in the FAQ. > > http://cobertura.sourceforge.net/faq.html > > > > -----Original Message----- > From: Steven Christou [mailto:ste...@re...] > Sent: Wednesday, July 07, 2010 9:51 AM > To: cob...@li... > Subject: [Cobertura-devel] Invoking Cobertura to report in source code > > Hello, > In the product I am working on, we are doing a Process.destroy() which > essentially destroys the JVM and does not allow for shutdown hooks to be > ran. Since no shutdown hooks can be ran, cobertura fails to run and > produce the results we want. I was wondering if there was a way we could > have it produce results right before we do the call to the > Process.destroy()? > Thanks! > Email Disclaimer: > http://www.redprairie.com/emaildisclaimer/ > > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by Sprint > What will you do first with EVO, the first 4G phone? > Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: Anderson v. <and...@gm...> - 2010-12-28 21:03:21
|
Hi I have one maven project with business implementations and another project that contains only unit tests. I configure in the master pom of the project the informations of cobertura plugin. But when i run the command mvn cobertura:cobetura in the root directory of the project, the cobertura plugin not associates the test of the project to the implementations. How May i resolve this? Follow the configurations and the projects structure. Maven builds first the dominio project and after builds the *tests-suite project.* <build> <plugins> .... <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>cobertura-maven-plugin</artifactId> <version>2.4</version> <executions> <execution> <goals> <goal>clean</goal> <goal>check</goal> </goals> </execution> </executions> </plugin> ... </build> </plugins> *|-- dominio* (Project with business implementations) | |-- src | | |-- main | | | |-- jasperreports | | | |-- java | | | `-- resources | | | `-- META-INF | | `-- test *|-- tests-suite (Project with tests)* | `-- src | `-- test | |-- java | `-- resources Thanks |
From: Steven C. <ste...@re...> - 2010-12-28 19:50:09
|
I was thinking about a possible solution to this. I was wondering if it would be possible to write like a "flush" .bat file. When this .bat file is called, it will do an automatic flush of all the data, rather than expecting shutdown hooks to execute. If you run an application as a windows service, it will fail to execute any shutdown hooks(that's what's been happening with me at least). Either this, or right before a report file is generated it could do a flush of all the data, to make sure all the data is gathered. I might be talking over my head on this one but this is what I was thinking when instrumented items run currently: run application -> cobertura starts writing to .class files -> shutdown hook executes -> .class file writes to .ser file -> done On 7/7/2010 9:31 AM, John W. Lewis wrote: > Please see the last question in the FAQ. > > http://cobertura.sourceforge.net/faq.html > > > > -----Original Message----- > From: Steven Christou [mailto:ste...@re...] > Sent: Wednesday, July 07, 2010 9:51 AM > To: cob...@li... > Subject: [Cobertura-devel] Invoking Cobertura to report in source code > > Hello, > In the product I am working on, we are doing a Process.destroy() which > essentially destroys the JVM and does not allow for shutdown hooks to be > ran. Since no shutdown hooks can be ran, cobertura fails to run and > produce the results we want. I was wondering if there was a way we could > have it produce results right before we do the call to the > Process.destroy()? > Thanks! > Email Disclaimer: > http://www.redprairie.com/emaildisclaimer/ > > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by Sprint > What will you do first with EVO, the first 4G phone? > Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > Email Disclaimer: http://www.redprairie.com/emaildisclaimer/ |
From: John W. L. <Joh...@sa...> - 2010-12-23 21:35:39
|
The maven plugin is actually developed by another group, so I am not the best person to ask, but check out the <excludes> here: http://mojo.codehaus.org/cobertura-maven-plugin/usage.html John -----Original Message----- From: stlecho [mailto:st...@gm...] Sent: Thursday, December 23, 2010 4:13 PM To: cob...@li... Subject: Re: [Cobertura-devel] Absent Code attribute in method that is not native or abstract in class file javax/ejb/EJBException Tests are indeed successfully when running without coverage. Could you please explain how to "exclude your EJB classes from the instrumentation" ? Regards, Stefan. John W. Lewis wrote: > > > I don't recall seeing that error message before. I don't know what to > say. > > Is it possible that you instrumented the EJBException class? > I assume that you can run the tests successfully without coverage? > If you exclude your EJB classes from the instrumentation, does that help? > > If you can isolate the issue down to a small set of non-proprietary source > files, please submit a bug and upload the project. That would be very > helpful. > > John > > -----Original Message----- > From: stlecho [mailto:st...@gm...] > Sent: Thursday, December 23, 2010 10:05 AM > To: cob...@li... > Subject: [Cobertura-devel] Absent Code attribute in method that is not > native or abstract in class file javax/ejb/EJBException > > > Hi, > > When running Cobertura, I'm getting the following error message: > "Absent Code attribute in method that is not native or abstract in > class file javax/ejb/EJBException ". Could someone please help me with > avoiding this error ? > > Details > Absent Code attribute in method that is not native or abstract in > class file javax/ejb/EJBException > java.lang.ClassFormatError: Absent Code attribute in method that is > not native or abstract in class file javax/ejb/EJBException at > java.lang.ClassLoader.defineClass1(Native Method) at > java.lang.ClassLoader.defineClass(ClassLoader.java:621) > at > java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124 > ) at java.net.URLClassLoader.defineClass(URLClassLoader.java:260) > at java.net.URLClassLoader.access$000(URLClassLoader.java:56) > at java.net.URLClassLoader$1.run(URLClassLoader.java:195) > at java.security.AccessController.doPrivileged(Native Method) at > java.net.URLClassLoader.findClass(URLClassLoader.java:188) > at java.lang.ClassLoader.loadClass(ClassLoader.java:307) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) > at java.lang.ClassLoader.loadClass(ClassLoader.java:252) > at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) > at > be.fgov.minfin.stir.fraude.ejb.test.BaseManagerBeanTestCase.setUp(Base > ManagerBeanTestCase.java:41) > at > be.fgov.minfin.stir.fraude.ejb.test.vooronderzoek.FraudeVoorOnderzoekT > estCase.setUp(FraudeVoorOnderzoekTestCase.java:26) > at junit.framework.TestCase.runBare(TestCase.java:128) > at junit.framework.TestResult$1.protect(TestResult.java:110) > at junit.framework.TestResult.runProtected(TestResult.java:128) > at junit.framework.TestResult.run(TestResult.java:113) > at junit.framework.TestCase.run(TestCase.java:120) > at junit.framework.TestSuite.runTest(TestSuite.java:228) > at junit.framework.TestSuite.run(TestSuite.java:223) > at > org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.j > ava:35) > at > org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.j > ava:62) > at > org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTest > Set(AbstractDirectoryTestSuite.java:140) > at > org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(Abs > tractDirectoryTestSuite.java:127) at > org.apache.maven.surefire.Surefire.run(Surefire.java:177) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.j > ava:39) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccess > orImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) > at > org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Sur > efireBooter.java:338) > at > org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.ja > va:997) > > Regards, Stefan Lecho. > -- > View this message in context: > http://old.nabble.com/Absent-Code-attribute-in-method-that-is-not-nati > ve-or-abstract-in-class-file-javax-ejb-EJBException-tp30522816p3052281 > 6.html Sent from the cobertura-devel mailing list archive at > Nabble.com. > > > ---------------------------------------------------------------------- > -------- Learn how Oracle Real Application Clusters (RAC) One Node > allows customers to consolidate database storage, standardize their > database environment, and, should the need arise, upgrade to a full > multi-node Oracle RAC database without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > > > ---------------------------------------------------------------------- > -------- Learn how Oracle Real Application Clusters (RAC) One Node > allows customers to consolidate database storage, standardize their > database environment, and, should the need arise, upgrade to a full > multi-node Oracle RAC database without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > > -- View this message in context: http://old.nabble.com/Absent-Code-attribute-in-method-that-is-not-native-or-abstract-in-class-file-javax-ejb-EJBException-tp30522816p30525116.html Sent from the cobertura-devel mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ Cobertura-devel mailing list Cob...@li... https://lists.sourceforge.net/lists/listinfo/cobertura-devel |
From: stlecho <st...@gm...> - 2010-12-23 21:12:47
|
Tests are indeed successfully when running without coverage. Could you please explain how to "exclude your EJB classes from the instrumentation" ? Regards, Stefan. John W. Lewis wrote: > > > I don't recall seeing that error message before. I don't know what to > say. > > Is it possible that you instrumented the EJBException class? > I assume that you can run the tests successfully without coverage? > If you exclude your EJB classes from the instrumentation, does that help? > > If you can isolate the issue down to a small set of non-proprietary source > files, please submit a bug and upload the project. That would be very > helpful. > > John > > -----Original Message----- > From: stlecho [mailto:st...@gm...] > Sent: Thursday, December 23, 2010 10:05 AM > To: cob...@li... > Subject: [Cobertura-devel] Absent Code attribute in method that is not > native or abstract in class file javax/ejb/EJBException > > > Hi, > > When running Cobertura, I'm getting the following error message: "Absent > Code attribute in method that is not native or abstract in class file > javax/ejb/EJBException ". Could someone please help me with avoiding this > error ? > > Details > Absent Code attribute in method that is not native or abstract in class > file javax/ejb/EJBException > java.lang.ClassFormatError: Absent Code attribute in method that is not > native or abstract in class file javax/ejb/EJBException at > java.lang.ClassLoader.defineClass1(Native Method) at > java.lang.ClassLoader.defineClass(ClassLoader.java:621) > at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124) > at java.net.URLClassLoader.defineClass(URLClassLoader.java:260) > at java.net.URLClassLoader.access$000(URLClassLoader.java:56) > at java.net.URLClassLoader$1.run(URLClassLoader.java:195) > at java.security.AccessController.doPrivileged(Native Method) at > java.net.URLClassLoader.findClass(URLClassLoader.java:188) > at java.lang.ClassLoader.loadClass(ClassLoader.java:307) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) > at java.lang.ClassLoader.loadClass(ClassLoader.java:252) > at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) > at > be.fgov.minfin.stir.fraude.ejb.test.BaseManagerBeanTestCase.setUp(BaseManagerBeanTestCase.java:41) > at > be.fgov.minfin.stir.fraude.ejb.test.vooronderzoek.FraudeVoorOnderzoekTestCase.setUp(FraudeVoorOnderzoekTestCase.java:26) > at junit.framework.TestCase.runBare(TestCase.java:128) > at junit.framework.TestResult$1.protect(TestResult.java:110) > at junit.framework.TestResult.runProtected(TestResult.java:128) > at junit.framework.TestResult.run(TestResult.java:113) > at junit.framework.TestCase.run(TestCase.java:120) > at junit.framework.TestSuite.runTest(TestSuite.java:228) > at junit.framework.TestSuite.run(TestSuite.java:223) > at > org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.java:35) > at > org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62) > at > org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140) > at > org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127) > at org.apache.maven.surefire.Surefire.run(Surefire.java:177) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:597) > at > org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:338) > at > org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:997) > > Regards, Stefan Lecho. > -- > View this message in context: > http://old.nabble.com/Absent-Code-attribute-in-method-that-is-not-native-or-abstract-in-class-file-javax-ejb-EJBException-tp30522816p30522816.html > Sent from the cobertura-devel mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------------ > Learn how Oracle Real Application Clusters (RAC) One Node allows customers > to consolidate database storage, standardize their database environment, > and, > should the need arise, upgrade to a full multi-node Oracle RAC database > without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > > > ------------------------------------------------------------------------------ > Learn how Oracle Real Application Clusters (RAC) One Node allows customers > to consolidate database storage, standardize their database environment, > and, > should the need arise, upgrade to a full multi-node Oracle RAC database > without downtime or disruption > http://p.sf.net/sfu/oracle-sfdevnl > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > > -- View this message in context: http://old.nabble.com/Absent-Code-attribute-in-method-that-is-not-native-or-abstract-in-class-file-javax-ejb-EJBException-tp30522816p30525116.html Sent from the cobertura-devel mailing list archive at Nabble.com. |
From: John W. L. <Joh...@sa...> - 2010-12-23 15:41:37
|
I don't recall seeing that error message before. I don't know what to say. Is it possible that you instrumented the EJBException class? I assume that you can run the tests successfully without coverage? If you exclude your EJB classes from the instrumentation, does that help? If you can isolate the issue down to a small set of non-proprietary source files, please submit a bug and upload the project. That would be very helpful. John -----Original Message----- From: stlecho [mailto:st...@gm...] Sent: Thursday, December 23, 2010 10:05 AM To: cob...@li... Subject: [Cobertura-devel] Absent Code attribute in method that is not native or abstract in class file javax/ejb/EJBException Hi, When running Cobertura, I'm getting the following error message: "Absent Code attribute in method that is not native or abstract in class file javax/ejb/EJBException ". Could someone please help me with avoiding this error ? Details Absent Code attribute in method that is not native or abstract in class file javax/ejb/EJBException java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstract in class file javax/ejb/EJBException at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:621) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124) at java.net.URLClassLoader.defineClass(URLClassLoader.java:260) at java.net.URLClassLoader.access$000(URLClassLoader.java:56) at java.net.URLClassLoader$1.run(URLClassLoader.java:195) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:307) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:252) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) at be.fgov.minfin.stir.fraude.ejb.test.BaseManagerBeanTestCase.setUp(BaseManagerBeanTestCase.java:41) at be.fgov.minfin.stir.fraude.ejb.test.vooronderzoek.FraudeVoorOnderzoekTestCase.setUp(FraudeVoorOnderzoekTestCase.java:26) at junit.framework.TestCase.runBare(TestCase.java:128) at junit.framework.TestResult$1.protect(TestResult.java:110) at junit.framework.TestResult.runProtected(TestResult.java:128) at junit.framework.TestResult.run(TestResult.java:113) at junit.framework.TestCase.run(TestCase.java:120) at junit.framework.TestSuite.runTest(TestSuite.java:228) at junit.framework.TestSuite.run(TestSuite.java:223) at org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.java:35) at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127) at org.apache.maven.surefire.Surefire.run(Surefire.java:177) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:338) at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:997) Regards, Stefan Lecho. -- View this message in context: http://old.nabble.com/Absent-Code-attribute-in-method-that-is-not-native-or-abstract-in-class-file-javax-ejb-EJBException-tp30522816p30522816.html Sent from the cobertura-devel mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ Cobertura-devel mailing list Cob...@li... https://lists.sourceforge.net/lists/listinfo/cobertura-devel |
From: stlecho <st...@gm...> - 2010-12-23 15:05:23
|
Hi, When running Cobertura, I'm getting the following error message: "Absent Code attribute in method that is not native or abstract in class file javax/ejb/EJBException ". Could someone please help me with avoiding this error ? Details Absent Code attribute in method that is not native or abstract in class file javax/ejb/EJBException java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstract in class file javax/ejb/EJBException at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:621) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124) at java.net.URLClassLoader.defineClass(URLClassLoader.java:260) at java.net.URLClassLoader.access$000(URLClassLoader.java:56) at java.net.URLClassLoader$1.run(URLClassLoader.java:195) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:307) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:252) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) at be.fgov.minfin.stir.fraude.ejb.test.BaseManagerBeanTestCase.setUp(BaseManagerBeanTestCase.java:41) at be.fgov.minfin.stir.fraude.ejb.test.vooronderzoek.FraudeVoorOnderzoekTestCase.setUp(FraudeVoorOnderzoekTestCase.java:26) at junit.framework.TestCase.runBare(TestCase.java:128) at junit.framework.TestResult$1.protect(TestResult.java:110) at junit.framework.TestResult.runProtected(TestResult.java:128) at junit.framework.TestResult.run(TestResult.java:113) at junit.framework.TestCase.run(TestCase.java:120) at junit.framework.TestSuite.runTest(TestSuite.java:228) at junit.framework.TestSuite.run(TestSuite.java:223) at org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.java:35) at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127) at org.apache.maven.surefire.Surefire.run(Surefire.java:177) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:338) at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:997) Regards, Stefan Lecho. -- View this message in context: http://old.nabble.com/Absent-Code-attribute-in-method-that-is-not-native-or-abstract-in-class-file-javax-ejb-EJBException-tp30522816p30522816.html Sent from the cobertura-devel mailing list archive at Nabble.com. |
From: Piotr T. <pi...@ta...> - 2010-12-22 19:05:46
|
How did you generated the instrumented code ? Are you using any decompiling tool ? I hope it is a problem in decompilation process. The names are only for debugging reasons in JVM code and we are not doing the renaming process. Piotr 2010/12/22 Tamás Kende <ken...@gm...> > Hi all, > > I've got a strange problem with cobertura. I have a Spring3 application, > and I don't understand the result of the instrumentation. Cobertura renames > the parameter of the method, but keeps the original name in the method > itself. > For example a setter from a class: > > From the original decompiled class: > > private List<String> domain; > public void setDomain(List<String> domain) { > this.domain = domain; > } > > From the instrumented class: > > private List<String> domain; > public void setDomain(List<String> arg1) { > int i = 0; int __cobertura__branch__number__ = -1; > int __cobertura__line__number__; > TouchCollector.touch("org.something.Class", 42); this.domain = domain; > TouchCollector.touch("org.something.Class", 43); > } > > So the domain string was renamed to arg1, but it was not changed in the > method. Why is this happening? Is this because the class level variable has > the same name as the method level? > > > Thank you for your help, > > Regards > > Tamas > > > ------------------------------------------------------------------------------ > Forrester recently released a report on the Return on Investment (ROI) of > Google Apps. They found a 300% ROI, 38%-56% cost savings, and break-even > within 7 months. Over 3 million businesses have gone Google with Google > Apps: > an online email calendar, and document program that's accessible from your > browser. Read the Forrester report: http://p.sf.net/sfu/googleapps-sfnew > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > > -- Pozdrawiam, Piotr Tabor |
From: Tamás K. <ken...@gm...> - 2010-12-22 11:36:11
|
Hi all, I've got a strange problem with cobertura. I have a Spring3 application, and I don't understand the result of the instrumentation. Cobertura renames the parameter of the method, but keeps the original name in the method itself. For example a setter from a class: >From the original decompiled class: private List<String> domain; public void setDomain(List<String> domain) { this.domain = domain; } >From the instrumented class: private List<String> domain; public void setDomain(List<String> arg1) { int i = 0; int __cobertura__branch__number__ = -1; int __cobertura__line__number__; TouchCollector.touch("org.something.Class", 42); this.domain = domain; TouchCollector.touch("org.something.Class", 43); } So the domain string was renamed to arg1, but it was not changed in the method. Why is this happening? Is this because the class level variable has the same name as the method level? Thank you for your help, Regards Tamas |
From: Charles H. <ch...@ho...> - 2010-12-16 01:04:34
|
Quite simple for Cobertura to skip. In the ClassVisitor method visitMethod, the access parameter should be checked against OpcodesACC_SYNTHETIC. If this bit is set, don't instrument the method. chas On 12/15/2010 2:39 AM, Petter Mahlen wrote: > That's interesting, I've had this problem (Cobertura reporting uncovered > methods in the presence of generics) before, and the only solution I've been > able to come up with is to reduce the requirements for code coverage. And > that's not that great. > > > From my perspective, this is a bug in Cobertura. It is probably very hard to > fix, but since (if I understand bridge methods) you can't call bridge > methods directly from test code, Cobertura shouldn't even consider their > presence. You shouldn't have to use reflection in your unit tests to get > good-enough test coverage in the presence of type erasure. I guess it is > really hard to figure out when a method is a real one and when it is a > bridge method, but it feels like that is needed? > > / Petter > > > On 15/12/2010 02:50, "Charles Honton"<ch...@ho...> wrote: > >> Julien, >> >> The java compiler is generating a bridge method which is not being >> called by your tests. >> >> See >> http://www.angelikalanger.com/GenericsFAQ/FAQSections/TechnicalDetails.html#FA >> Q103 >> and >> http://www.java2s.com/Code/Java/Language-Basics/JavagenericAsituationthatcreat >> esabridgemethod.htm >> for more information about bridge methods. >> >> chas >> >> On 12/9/2010 7:06 AM, Julien HENRY wrote >>> Hi, >>> >>> Sonar is using Cobertura to compute code coverage. Could you please explain >>> me >>> why in this case the line is reported as not covered? >>> http://nemo.sonarsource.org/resource/index/com.googlecode.lambdaj:lambdaj:ch. >>> lambdaj.collection.LambdaMap?metric=coverage >>> >>> >>> public class LambdaMap<K, V> implements Map<K, V>, Cloneable {Thanks, >>> >>> Julien >> ------------------------------------------------------------------------------ >> Lotusphere 2011 >> Register now for Lotusphere 2011 and learn how >> to connect the dots, take your collaborative environment >> to the next level, and enter the era of Social Business. >> http://p.sf.net/sfu/lotusphere-d2d >> _______________________________________________ >> Cobertura-devel mailing list >> Cob...@li... >> https://lists.sourceforge.net/lists/listinfo/cobertura-devel >> > |
From: Petter M. <PM...@sh...> - 2010-12-15 07:39:31
|
That's interesting, I've had this problem (Cobertura reporting uncovered methods in the presence of generics) before, and the only solution I've been able to come up with is to reduce the requirements for code coverage. And that's not that great. >From my perspective, this is a bug in Cobertura. It is probably very hard to fix, but since (if I understand bridge methods) you can't call bridge methods directly from test code, Cobertura shouldn't even consider their presence. You shouldn't have to use reflection in your unit tests to get good-enough test coverage in the presence of type erasure. I guess it is really hard to figure out when a method is a real one and when it is a bridge method, but it feels like that is needed? / Petter On 15/12/2010 02:50, "Charles Honton" <ch...@ho...> wrote: > Julien, > > The java compiler is generating a bridge method which is not being > called by your tests. > > See > http://www.angelikalanger.com/GenericsFAQ/FAQSections/TechnicalDetails.html#FA > Q103 > and > http://www.java2s.com/Code/Java/Language-Basics/JavagenericAsituationthatcreat > esabridgemethod.htm > for more information about bridge methods. > > chas > > On 12/9/2010 7:06 AM, Julien HENRY wrote >> Hi, >> >> Sonar is using Cobertura to compute code coverage. Could you please explain >> me >> why in this case the line is reported as not covered? >> http://nemo.sonarsource.org/resource/index/com.googlecode.lambdaj:lambdaj:ch. >> lambdaj.collection.LambdaMap?metric=coverage >> >> >> public class LambdaMap<K, V> implements Map<K, V>, Cloneable {Thanks, >> >> Julien > > ------------------------------------------------------------------------------ > Lotusphere 2011 > Register now for Lotusphere 2011 and learn how > to connect the dots, take your collaborative environment > to the next level, and enter the era of Social Business. > http://p.sf.net/sfu/lotusphere-d2d > _______________________________________________ > Cobertura-devel mailing list > Cob...@li... > https://lists.sourceforge.net/lists/listinfo/cobertura-devel > |
From: Charles H. <ch...@ho...> - 2010-12-15 04:15:32
|
It might be because of the way cobertura instruments classes. To prevent re-instrumentation, cobertura adds an marker interface to class. This marker interface ( net.sourceforge.cobertura.coveragedata.HasBeenInstrumented ) may be interfering with the container's normal behavior. I have seen this problem with a JBoss EJB3 container. I have submitted a patch which uses an annotation instead of an interface as a marker. > When running unit tests with Maven, all the tests pass. When running the same > tests wih Cobertura, the tests fail with the an exception. Running the same > tests in Eclipse works perfectly. The project uses EJB3 and JPA. The unit > tests are run within an embedded Glassfish container. > > Exception > javax.naming.NamingException: Lookup failed for > 'java:global/classes/HVATRManagerImpl' in SerialContext [Root exception is > javax.naming.NameNotFoundException: HVATRManagerImpl not found] > > Can someone please help me with the issue ? > |
From: Charles H. <ch...@ho...> - 2010-12-15 04:07:34
|
Julien, The java compiler is generating a bridge method which is not being called by your tests. See http://www.angelikalanger.com/GenericsFAQ/FAQSections/TechnicalDetails.html#FAQ103 and http://www.java2s.com/Code/Java/Language-Basics/JavagenericAsituationthatcreatesabridgemethod.htm for more information about bridge methods. chas On 12/9/2010 7:06 AM, Julien HENRY wrote > Hi, > > Sonar is using Cobertura to compute code coverage. Could you please explain me > why in this case the line is reported as not covered? > http://nemo.sonarsource.org/resource/index/com.googlecode.lambdaj:lambdaj:ch.lambdaj.collection.LambdaMap?metric=coverage > > > public class LambdaMap<K, V> implements Map<K, V>, Cloneable {Thanks, > > Julien |