From: Grzegorz L. <ha...@gm...> - 2005-08-25 11:05:53
|
By default JBoss at the end of its shutdown uses=20 Runtime.getRuntime().halt(0);=20 so that JVM is forced to halt. If other shutdown hooks are working there are terminated - so Cobertura can be terminated in the middle of serializing datafile (halt method documentation: http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Runtime.html#halt(int)) In case of Tomcat it seems that they do not use such brutal methods, and Cactus uses standard Tomcat shutdown. But Tomcat shutdown is fired from separate thread, maybe cobertura-report is run when Tomcat has not finished its shutdown yet? Could you add sleep task before launching cobertura-report? Maybe it will help. Below are presented some technical details and possible solution for JBoss users. Grzegorz ---------------------------------------------------------------------------= ----------------------------- JBoss ServerImpl.java - source: http://cvs.sourceforge.net/viewcvs.py/jboss/jboss-system/src/main/org/jboss= /system/server/ServerImpl.java?view=3Dmarkup Interesting sections: -------------- ServerImpl.java public ShutdownHook(final ObjectName controller, final ObjectName mainDeployer) { =09 ... =20 String value =3D System.getProperty("jboss.shutdown.forceHalt", nu= ll); if (value !=3D null) { forceHalt =3D new Boolean(value).booleanValue(); } -------------- public void run() { shutdown(); // later bitch if (forceHalt) { System.out.println("Halting VM"); Runtime.getRuntime().halt(0); } } -------------- BTW. Nice comment ;) ---------------------------------------------------------------------------= ----------------------------- JBoss changelog: http://sourceforge.net/project/shownotes.php?release_id=3D97289 Section: Changes between JBoss_3_0_1RC1 and JBoss_3_0_0 Added jboss.shutdown.forceHalt system property, which defaults to true. This value controls whether or not the shutdown hook will force the vm to exit after shutdown has been completed. This might help for situat= ions where the vm is crazy, locked up in socket io or something... or not. ------------ You can use this option to prevent Runtime.halt use: run -Djboss.shutdown.forceHalt=3Dfalse You should see these lines at JBoss shutdown (this lines are written on standard output, so won't see them in logs): Shutdown complete When this option is not used additionaly this line is presented: Shutdown complete Halting VM NOTICE: I will be able to test it with Cobertura installation on Linux tomo= rrow. On 8/24/05, yamaduc <ya...@gm...> wrote: > Here's the stack, see below. >=20 > Thanks for your help. >=20 > Maybe I can get a thread dump, if that'll help. >=20 >=20 > [cobertura-report] java.io.EOFException > [cobertura-report] at > java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.jav= a:2165) > [cobertura-report] at > java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStrea= m.java:2631) > [cobertura-report] at > java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:734) > [cobertura-report] at > java.io.ObjectInputStream.<init>(ObjectInputStream.java:253) > [cobertura-report] at > net.sourceforge.cobertura.coveragedata.CoverageDataFileHandler.loadCovera= geData(CoverageDataFileHandler.java:97) > [cobertura-report] at > net.sourceforge.cobertura.coveragedata.CoverageDataFileHandler.loadCovera= geData(CoverageDataFileHandler.java:68) > [cobertura-report] at > net.sourceforge.cobertura.reporting.Main.parseArguments(Main.java:91) > [cobertura-report] at > net.sourceforge.cobertura.reporting.Main.main(Main.java:161) >=20 >=20 >=20 > On 8/24/05, Grzegorz Lukasik <ha...@gm...> wrote: > > Yeah, it looks pretty strange. I have noticed it recently when running > > instrumented application in JBoss. On Windows it worked ok, but under > > Linux I got EOFException when reporting task was reading cobertura.ser > > - it seems that cobertura.ser was truncated (or maybe not fully > > written) during instrumentation. I have no time to investigate it yet, > > but now I see it was no accident, and I will look at it. > > > > cobertura.ser is written during virtual machine shutdown, maybe some > > applications that also perfom some actions on VM shutdown use > > java.lang.Runtime.halt method at the end? I am not sure. > > > > Grzegorz > > > > PS. Eh, I won't be able to do anything today. > > > > On 8/24/05, yamaduc <ya...@gm...> wrote: > > > well, this is strange. > > > > > > I put all the cobertura jar in the war file. > > > > > > The classes get instrumented, but during the report, it deletes > > > everything in the cobertura.ser > > > > > > Then an EOF exception is thrown. > > > > > > On 8/24/05, Grzegorz Lukasik <ha...@gm...> wrote: > > > > Hmmmm... I am not sure what is the cause. Have you add cobertura.ja= r > > > > and all depended libraries to the war (or to Tomcat's lib directory= )? > > > > And have you put all classes and other resources that were not > > > > instrumented (e.g. interfaces, files with properties) to these > > > > instrumented? > > > > > > > > Grzegorz > > > > > > > > On 8/24/05, yamaduc <ya...@gm...> wrote: > > > > > Cobertura isn't throwing any exception. > > > > > If I put the instrumented classes in the war file I get the follo= wing error. > > > > > > > > > > [cactus] --------------------------------------------------------= --------- > > > > > [cactus] Running tests against Tomcat 4.1.27 @ http://localhost:8= 810 > > > > > [cactus] --------------------------------------------------------= --------- > > > > > [cactus] Testsuite: com.goldengate.veridata.struts.actions.TestCr= eateGroupAction > > > > > [cactus] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0.63= sec > > > > > > > > > > [cactus] ------------- Standard Error ----------------- > > > > > [cactus] log4j:WARN No appenders could be found for logger > > > > > (org.apache.cactus.internal.configuration.ConfigurationInitialize= r). > > > > > [cactus] log4j:WARN Please initialize the log4j system properly. > > > > > [cactus] ------------- ---------------- --------------- > > > > > [cactus] Testcase: > > > > > testExceptionBean(org.apache.cactus.ServletTestCase): Caused = an > > > > > ERROR > > > > > [cactus] Error while initializing ActionServlet: Parsing error > > > > > processing resource path /WEB-INF/struts-config.xml > > > > > [cactus] junit.framework.AssertionFailedError: Error while > > > > > initializing ActionServlet: Parsing error processing resource pat= h > > > > > /WEB-INF/struts-config. > > > > > [cactus] at > > > > > servletunit.struts.CactusStrutsTestCase.getActionServlet(CactusSt= rutsTestCase.java:486) > > > > > [cactus] at > > > > > servletunit.struts.CactusStrutsTestCase.actionPerform(CactusStrut= sTestCase.java:536) > > > > > [cactus] at > > > > > com.goldengate.veridata.struts.actions.TestCreateGroupAction.test= ExceptionBean(TestCreateGroupAction.java:63) > > > > > [cactus] at > > > > > org.apache.cactus.internal.AbstractCactusTestCase.runBareServer(A= bstractCactusTestCase.java:153) > > > > > [cactus] at > > > > > org.apache.cactus.internal.server.AbstractWebTestCaller.doTest(Ab= stractWebTestCaller.java:119) > > > > > [cactus] at > > > > > org.apache.cactus.internal.server.AbstractWebTestController.handl= eRequest_aroundBody0(AbstractWebTestController.java:93) > > > > > [cactus] at > > > > > org.apache.cactus.internal.server.AbstractWebTestController.handl= eRequest_aroundBody1$advice(AbstractWebTestController.java:217) > > > > > [cactus] at > > > > > org.apache.cactus.internal.server.AbstractWebTestController.handl= eRequest(AbstractWebTestController.java) > > > > > [cactus] at > > > > > org.apache.cactus.server.ServletTestRedirector.doPost_aroundBody2= (ServletTestRedirector.java:101) > > > > > [cactus] at > > > > > org.apache.cactus.server.ServletTestRedirector.doPost_aroundBody3= $advice(ServletTestRedirector.java:217) > > > > > [cactus] at > > > > > org.apache.cactus.server.ServletTestRedirector.doPost(ServletTest= Redirector.java) > > > > > [cactus] at > > > > > org.apache.cactus.server.ServletTestRedirector.doGet_aroundBody0(= ServletTestRedirector.java:72) > > > > > [cactus] at > > > > > org.apache.cactus.server.ServletTestRedirector.doGet_aroundBody1$= advice(ServletTestRedirector.java:217) > > > > > [cactus] at > > > > > org.apache.cactus.server.ServletTestRedirector.doGet(ServletTestR= edirector.java) > > > > > [cactus] at javax.servlet.http.HttpServlet.service(HttpServle= t.java:740) > > > > > [cactus] at javax.servlet.http.HttpServlet.service(HttpServle= t.java:853) > > > > > [cactus] at > > > > > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(= ApplicationFilterChain.java:247) > > > > > [cactus] at > > > > > org.apache.catalina.core.ApplicationFilterChain.doFilter(Applicat= ionFilterChain.java:193) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrap= perValve.java:256) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValveCo= ntext.invokeNext(StandardPipeline.java:643) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline= .java:480) > > > > > [cactus] at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:= 995) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardContextValve.invoke(StandardCont= extValve.java:191) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValveCo= ntext.invokeNext(StandardPipeline.java:643) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline= .java:480) > > > > > [cactus] at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:= 995) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardContext.invoke(StandardContext.j= ava:2416) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardHostValve.invoke(StandardHostVal= ve.java:180) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValveCo= ntext.invokeNext(StandardPipeline.java:643) > > > > > [cactus] at > > > > > org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispa= tcherValve.java:171) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValveCo= ntext.invokeNext(StandardPipeline.java:641) > > > > > [cactus] at > > > > > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportVal= ve.java:172) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValveCo= ntext.invokeNext(StandardPipeline.java:641) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline= .java:480) > > > > > [cactus] at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:= 995) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardEngineValve.invoke(StandardEngin= eValve.java:174) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValveCo= ntext.invokeNext(StandardPipeline.java:643) > > > > > [cactus] at > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline= .java:480) > > > > > [cactus] at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:= 995) > > > > > [cactus] at > > > > > org.apache.catalina.connector.http.HttpProcessor.process(HttpProc= essor.java:1040) > > > > > [cactus] at > > > > > org.apache.catalina.connector.http.HttpProcessor.run(HttpProcesso= r.java:1151) > > > > > [cactus] at java.lang.Thread.run(Thread.java:534) > > > > > > > > > > On 8/23/05, Grzegorz Lukasik <ha...@gm...> wrote: > > > > > > Try to run ant with -v option, there should be stack trace with= more detail. > > > > > > Did you put only instrumented classes into war? If Cobertura do= es not > > > > > > instrument class for some reason (e.g. for interface) it does n= ot put > > > > > > uninstrumented file among instrumented. Maybe some interface is > > > > > > missing? (You should copy all remaining files to the war). > > > > > > > > > > > > Or maybe Cobertura library is not in Tomcat libs? > > > > > > > > > > > > I am just guessing. > > > > > > > > > > > > Grzegorz > > > > > > > > > > > > PS. I am going sleep, so I won't be able to answer today. > > > > > > > > > > > > On 8/24/05, yamaduc <ya...@gm...> wrote: > > > > > > > Here's what happens when i put the instrumented classes in th= e war file. > > > > > > > > > > > > > > [cactus] Testcase: > > > > > > > testExceptionBean(org.apache.cactus.ServletTestCase): Cau= sed an > > > > > > > ERROR > > > > > > > [cactus] Error while initializing ActionServlet: Parsing erro= r > > > > > > > processing resource path /WEB-INF/struts-config.xml > > > > > > > [cactus] junit.framework.AssertionFailedError: Error while > > > > > > > initializing ActionServlet: Parsing error processing resource= path > > > > > > > /WEB-INF/struts-config.xml > > > > > > > > > > > > > > I tried it without the instrumented classes in the war file a= nd this > > > > > > > message does not appear. > > > > > > > > > > > > > > > > > > > > > On 8/23/05, Grzegorz Lukasik <ha...@gm...> wrote: > > > > > > > > If you put insturmented classes in serverclasses dir for We= blogic, > > > > > > > > then they were treaten as part of web application. > > > > > > > > > > > > > > > > You can try (at least for test) to instrument war - it shou= ld be > > > > > > > > possible from Cobertura 1.5. Be aware that you will need co= bertura.jar > > > > > > > > (and dependend) in some tomcat lib subdirectory (or you can= pack it > > > > > > > > into war). > > > > > > > > > > > > > > > > Grzegorz > > > > > > > > > > > > > > > > On 8/23/05, yamaduc <ya...@gm...> wrote: > > > > > > > > > I had this working before with weblogic just fine. > > > > > > > > > > > > > > > > > > I'm using tomcat now. > > > > > > > > > > > > > > > > > > With weblogic, i didn't need to put the instrumented clas= ses in the > > > > > > > > > war/ear file. > > > > > > > > > > > > > > > > > > I put the instrumented classes in the server's classpath = and it worked fine. > > > > > > > > > > > > > > > > > > I'll try to put them in the war and see what happens. > > > > > > > > > > > > > > > > > > On 8/23/05, Grzegorz Lukasik <ha...@gm...> wrote: > > > > > > > > > > Correct me if I'm wrong, cactus task work this way: > > > > > > > > > > > > > > > > > > > > - deploy war inside application container > > > > > > > > > > - run tests on deployed application by cactus > > > > > > > > > > > > > > > > > > > > So if I get it right, classes packed into war are used = when performing > > > > > > > > > > tests. When you specifiy classpath inside cactus task, = it specifies > > > > > > > > > > classpath for test classes. So you need insturmented cl= asses packed > > > > > > > > > > into war, so that they are run during tests. > > > > > > > > > > > > > > > > > > > > Grzegorz > > > > > > > > > > > > > > > > > > > > On 8/23/05, yamaduc <ya...@gm...> wrote: > > > > > > > > > > > so i should have the instrumented classes instead of = the standard classes? > > > > > > > > > > > > > > > > > > > > > > On 8/23/05, Grzegorz Lukasik <ha...@gm...> wrot= e: > > > > > > > > > > > > One more hit, maybe in created war you do not have = instrumented classes? > > > > > > > > > > > > > > > > > > > > > > > > On 8/23/05, yamaduc <ya...@gm...> wrote: > > > > > > > > > > > > > The date never changes. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 8/23/05, Grzegorz Lukasik <ha...@gm...> = wrote: > > > > > > > > > > > > > > Yes, it should be updated when tests are run bu= t size will be the > > > > > > > > > > > > > > same. Check file change date. > > > > > > > > > > > > > > > > > > > > > > > > > > > > Reports does not update cobertura.ser. > > > > > > > > > > > > > > > > > > > > > > > > > > > > Grzegorz > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 8/23/05, yamaduc <ya...@gm...> wrote: > > > > > > > > > > > > > > > Is the cobertura.ser supposed to update durin= g the report process? > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > I watched it after instrumentation, its 691k. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > After my tests run and the reports are execut= ed, it's still the same 691k. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 8/23/05, yamaduc <ya...@gm...> wrote= : > > > > > > > > > > > > > > > > Well, I tried passing it in as a runtime pa= ramter to the jvm. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Then the report task complained, couldn't f= ind cobertura.ser. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > So, I added datafile to the ant task and th= e error message went away, > > > > > > > > > > > > > > > > see ant target below. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > I only have one .ser file. > > > > > > > > > > > > > > > > <cobertura-instrument datafile=3D"${test.di= r}/cobertura.ser" > > > > > > > > > > > > > > > > todir=3D"${instrumented.classes}"> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <target name=3D"coverage" descripti= on=3D"HTML coverage reports can be > > > > > > > > > > > > > > > > found in build/coverage"> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <mkdir dir=3D"${test.result= s}/coverage"/> > > > > > > > > > > > > > > > > <cobertura-report srcdir=3D= "${src.dir}" > > > > > > > > > > > > > > > > destdir=3D"${test.results}/coverage" > > > > > > > > > > > > > > > > datafile=3D"${test.dir}/cobertura.ser"/> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <echo> > > > > > > > > > > > > > > > > Cobertura reports h= ave been generated. > > > > > > > > > > > > > > > > The HTML report is = ${test.results}/coverage/index.html > > > > > > > > > > > > > > > > </echo> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > </target> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 8/23/05, Grzegorz Lukasik <hauserx@gmail= .com> wrote: > > > > > > > > > > > > > > > > > Hey, > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > You probably do not set property net.sour= ceforge.cobertura.datafile > > > > > > > > > > > > > > > > > when running tests (I do not know how to = do it inside cactus task). Do > > > > > > > > > > > > > > > > > you get additional cobertura.ser in direc= tory where tests are run? > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Grzegorz > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 8/23/05, yamaduc <ya...@gm...> w= rote: > > > > > > > > > > > > > > > > > > Hi all, > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > I have the following build script. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <target name=3D"instrument" depends=3D"= compile" description=3D"Add Cobertura > > > > > > > > > > > > > > > > > > instrumentation"> > > > > > > > > > > > > > > > > > > <!-- instrument the app= lication classes, writing the instrumented > > > > > > > > > > > > > > > > > > classes into ${instrumented.classes}. -= -> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <cobertura-instrument d= atafile=3D"${test.dir}/cobertura.ser" > > > > > > > > > > > > > > > > > > todir=3D"${instrumented.classes}"> > > > > > > > > > > > > > > > > > > <!-- Note that = the following line causes instrument to ignore any > > > > > > > > > > > > > > > > > > source lin= e containing a reference to log4j, for the purposes > > > > > > > > > > > > > > > > > > of cov= erage reporting. --> > > > > > > > > > > > > > > > > > > <ignore regex= =3D"org.apache.log4j.*"/> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <fileset dir=3D= "${classes.dir}"> > > > > > > > > > > > > > > > > > > <!-- in= strument all the application classes, but don't instrument > > > > > > > > > > > > > > > > > > the test classes. --> > > > > > > > > > > > > > > > > > > <includ= e name=3D"**/*.class"/> > > > > > > > > > > > > > > > > > > <exclud= e name=3D"**/*Test.class"/> > > > > > > > > > > > > > > > > > > </fileset> > > > > > > > > > > > > > > > > > > </cobertura-instrument> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > </target> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <target name=3D"test" depends=3D"prepar= e.test.package" description=3D"Run > > > > > > > > > > > > > > > > > > the tests on the defined container"> > > > > > > > > > > > > > > > > > > <!-- Run the tests --> > > > > > > > > > > > > > > > > > > <mkdir dir=3D"${test.re= sults}/tomcat4x"/> > > > > > > > > > > > > > > > > > > <cactus warfile=3D"${te= st-war.dir}/${app.name}-${app.version}.war" > > > > > > > > > > > > > > > > > > fork=3D"yes" failureproperty=3D"tests.f= ailed" haltonerror=3D"true"> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <!-- Configure = the cactus task for logging --> > > > > > > > > > > > > > > > > > > <cactusproperty= server=3D"false" > > > > > > > > > > > > > > > > > > propert= iesFile=3D"${meta.dir}/${configtype}/test/logging_client.properties"/> > > > > > > > > > > > > > > > > > > <cactusproperty= server=3D"true" > > > > > > > > > > > > > > > > > > propert= iesFile=3D"${meta.dir}/${configtype}/test/logging_server.properties"/> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <!-- Additional= jars that will be added to the classpath used to start the > > > > > > > > > > > > > > > > > > contai= ner (in addition to the container jars themseleves which are > > > > > > > > > > > > > > > > > > automa= tically added by the <cactus> task --> > > > > > > > > > > > > > > > > > > <containerclass= path> > > > > > > > > > > > > > > > > > > <pathel= ement path=3D"${test-props.dir}"/> > > > > > > > > > > > > > > > > > > </containerclas= spath> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <classpath> > > > > > > > > > > > > > > > > > > <pathel= ement path=3D"${instrumented.classes}"/> > > > > > > > > > > > > > > > > > > <pathel= ement path=3D"${classes.dir}"/> > > > > > > > > > > > > > > > > > > <pathel= ement location=3D"${test-lib.dir}/my-tests.jar"/> > > > > > > > > > > > > > > > > > > <path r= efid=3D"project.classpath"/> > > > > > > > > > > > > > > > > > > </classpath> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <containerset> > > > > > > > > > > > > > > > > > > <tomcat= 4x if=3D"tomcat-dist.dir" > > > > > > > > > > > > > > > > > > = dir=3D"${tomcat-dist.dir}" port=3D"${test.port}" > > > > > > > > > > > > > > > > > > = output=3D"${test.results}/tomcat4x.out" > > > > > > > > > > > > > > > > > > = todir=3D"${test.results}/tomcat4x" > > > > > > > > > > > > > > > > > > = tmpdir=3D"${test.temp.dir}" > > > > > > > > > > > > > > > > > > = jvmArgs=3D"-DGG_HOME=3DC:/test"/> > > > > > > > > > > > > > > > > > > </containerset> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <formatter type= =3D"brief" usefile=3D"false"/> > > > > > > > > > > > > > > > > > > <formatter type= =3D"xml"/> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <batchtest> > > > > > > > > > > > > > > > > > > <filese= t dir=3D"${testsrc.dir}"> > > > > > > > > > > > > > > > > > > = <include name=3D"**/Test*.java"/> > > > > > > > > > > > > > > > > > > = <exclude name=3D"**/Test*All.java"/> > > > > > > > > > > > > > > > > > > </files= et> > > > > > > > > > > > > > > > > > > </batchtest> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > </cactus> > > > > > > > > > > > > > > > > > > <!-- Generate the JUnit reports --> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <junitreport todir=3D"$= {test.results}/tomcat4x"> > > > > > > > > > > > > > > > > > > <fileset dir=3D= "${test.results}/tomcat4x" > > > > > > > > > > > > > > > > > > = includes=3D"TEST-*.xml"/> > > > > > > > > > > > > > > > > > > <report todir= =3D"${test.results}/tomcat4x" > > > > > > > > > > > > > > > > > > = format=3D"frames"/> > > > > > > > > > > > > > > > > > > </junitreport> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <fail if=3D"tests.faile= d">At least one test failed!</fail> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > </target> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <target name=3D"coverage" description= =3D"HTML coverage reports can be > > > > > > > > > > > > > > > > > > found in build/coverage"> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <mkdir dir=3D"${test.re= sults}/coverage"/> > > > > > > > > > > > > > > > > > > <cobertura-report srcdi= r=3D"${src.dir}" > > > > > > > > > > > > > > > > > > destdir=3D"${test.results}/coverage" > > > > > > > > > > > > > > > > > > datafile=3D"${test.dir}/cobertura.ser"/= > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <echo> > > > > > > > > > > > > > > > > > > Cobertura repor= ts have been generated. > > > > > > > > > > > > > > > > > > The HTML report= is ${test.results}/coverage/index.html > > > > > > > > > > > > > > > > > > </echo> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > </target> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > I'm getting 0% coverage for all tests. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Is there a way to see if the classes ha= ve been instrumented? > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ---------------------------------------= ---------------- > > > > > > > > > > > > > > > > > > SF.Net email is Sponsored by the Better= Software Conference & EXPO > > > > > > > > > > > > > > > > > > September 19-22, 2005 * San Francisco, = CA * Development Lifecycle Practices > > > > > > > > > > > > > > > > > > Agile & Plan-Driven Development * Manag= ing Projects & Teams * Testing & QA > > > > > > > > > > > > > > > > > > Security * Process Improvement & Measur= ement * http://www.sqe.com/bsce5sf > > > > > > > > > > > > > > > > > > _______________________________________= ________ > > > > > > > > > > > > > > > > > > Cobertura-devel mailing list > > > > > > > > > > > > > > > > > > Cob...@li... > > > > > > > > > > > > > > > > > > https://lists.sourceforge.net/lists/lis= tinfo/cobertura-devel > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > |