0

We in our team are trying to get cobertura reports generated from selenium tests run out of the production deployment of our JBoss based applications. We use JBoss 6.1.0 for this purpose.

For some reason, the server doesn't seem to write into the cobertura.ser file. I followed the steps mentioned in the links at

for this but still not able to get coverage information written into that file. Out of the many suggestions, I tried

  1. Starting JBoss from folder where the cobertura.ser file is present (bin folder).

  2. Using -Djboss.shutdown.forceHalt=false

  3. Using -Dnet.sourceforge.cobertura.datafile=$JBOSS_HOME/bin/cobertura.ser.

  4. Ensured cobertura.ser has file permissions at 666 for it to get updated.

After adding datafile property, I see the file is being touched by some process (through change in file modified timestamp) but doesn't have coverage information added. (All classes still show 0% coverage)

I checked that the machine doesn't have any other cobertura.ser file anywhere besides the one placed by me in the bin directory.

I am not so keen on writing the code snippet into our codebase to get cobertura to forcefully write the coverage information here, hence would like to seek suggestions as to what else can I do to generate coverage information serialized into the cobertura.ser file.

  1. Is there anyway to debug the status of cobertura on the server.
  2. Is there any other work-around to make it serialize without needing to add code to the JBoss runtimes.

Any help is appreciated.

P.S: We used to use an older version of JBoss were apparently the same steps work. So surprised its not working in 6.1.0

With Regards

Shankar
  • 13
  • 4
  • Cobertura version used by me is 1.9.4.1 – Shankar Mar 06 '15 at 01:02
  • I tried one more thing, I removed the instrumented cobertura.ser file from the bin folder and attempted the test. A new cobertura.ser file got generated after the JBoss shutdown. But on attempting to gnerate a report, didn't have any class's coverage info in it. Not sure if this test was of any relevance for this case. – Shankar Mar 06 '15 at 14:05

0 Answers0