2

Possible Duplicate:
Testng, Emma, Cobertura, coverage and JDK 7 result in ClassFormatError and VerifyError

I have recently moved JDK6 to JDK7.In my eclipse i have installed emma plugin for code coverage.Its works fine in jdk1.6.Now I have used JDK7.But Its does not works.I have googled and searching some of code coverage tools like,

1.emma
2.Jacoco
3.cobertura  

but none of them support JDK1.7.

can anyone tell me which tool support JDK1.7 for both windows and linux platform?

I think compare to other emma is better one.but it doesnot support.

Thanks in advance.

Community
  • 1
  • 1
Ami
  • 4,241
  • 6
  • 41
  • 75

2 Answers2

0

I don't use code coverage. But Google CodePro AnalytiX works with Eclipse and includes code coverage. Apparently based on EMMA, and I do not know if it works with Java 7. But it's worth a try.

Has QUIT--Anony-Mousse
  • 76,138
  • 12
  • 138
  • 194
  • If i install this plugin and run the test cases.It shows follows error."CodePro: collecting runtime coverage data ... CodePro: runtime controller started on port [47653] CodePro: no metadata collected at runtime [no reports generated] [CodePro v6.1, build 10012 (unsupported private build)] emmarun: [MAIN_CLASS_NOT_FOUND] application class could not be loaded Exception in thread "main" com.vladium.emma.EMMARuntimeException: [MAIN_CLASS_NOT_FOUND] application class could not be loaded.Caused by: java.lang.ClassNotFoundException: at com.vladium.emma.run.InstrClassLoader" – Ami Dec 21 '12 at 10:51
0

According the the paper "EclEmma 2.0", Jacoco (that you looked) is supposed to work with Java 1.7.
(see all Jacoco releases here)

Java Runtime: As JaCoCo requires Java 1.5 the same minimum JRE is required for the Eclipse instance running EclEmma and the application under test.
Note that this does not apply to the Java class files under test: Any class file version ranging from Java 1.0 to 1.7 is possible.

The latest changes history mentions:

Release 0.6.0 (2012/10/06)

New Features

Full support for Java 7 including INVOKEDYNAMIC as JaCoCo is now based on ASM 4.0 (GitHub #5).

(since then, 0.6.1, 2012/12/19 has been released)

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • thanks.Are you sure Jacoco working fine? because i have tried but Its does not working.can you send me the link which going to install in eclipse? – Ami Dec 21 '12 at 10:39
  • @ILLA no, I am not sure as I haven't tested it directly, but the EclEmma 2.0 should allow you to install Jacoco in your Eclipse (http://www.eclemma.org/jacoco/index.html), and check if indeed 1.7 classes are supported. For more information, I would suggest https://groups.google.com/d/forum/jacoco . – VonC Dec 21 '12 at 11:47