From: John W. L. <Joh...@sa...> - 2010-07-12 18:40:49
|
You might also want to try creating the jar first. Then, instrument the jar. I also don’t see the cobertura.jar on your classpath. John From: Michel MAURICE [mailto:mic...@ya...] Sent: Monday, July 12, 2010 1:37 PM To: cob...@li... Subject: [Cobertura-devel] Unable to access jar file Hi, I cannot solve a problem. The steps are the following: 1. I compile my application and generate the jar file with the good manifest 2. I run it : ok 3. I instrumente with cobertura using the bat file and create the instumented jar file with the same manifest file, see the commands in the context below: Rem : Instrumentation de l'application Editeur de courbes pour mesure de couverture Echo on cd c:\editeur_graphe\ rmdir instrumented del cobertura.ser call cobertura-instrument.bat --destination .\instrumented .\executables Rem : Copy des ressources cd instrumented xcopy ..\ressources\*.class .\fr\guehenneux\graphe\fonction /e /y Rem : Generation du jar de l'application Editeur de courbes jar cvmf ..\ressources\MANIFEST.MF .\EditeurGraphe.jar *.* Rem : Fin de generation echo off cd .. 4. I want to run some use cases for test, using the command bellow, as explain in your documentation: java -classpath .;C:\Editeur_Graphe\instrumented;C:\Editeur_Graphe\executables;C:\Editeur_Graphe\sources -Dnet.sourceforge.cobertura.datafile=C:\Editeur_Graphe\cobertura.ser -jar EditeurGraphe.jar; I hope the instrumented application running, but I have the message Unable to access jar file ... For your information I have use your procedure with a simple .class it's OK, I can report coverage. Many thanks for your help. Best regards. Michel MAURICE |