CLOVER question

V

vipulk

I'm using the CLOVER eclipse plugin. I have set of JUnit tests to test
my client side APIs. When I get the coverage report I see that
interface classes are not in it. I assume that since the interfaces
dont have any executable body, CLOVER removes from its report.

Please let me know with CLOVER, how can I get the coverage of methods
which are in the interfaces as all of my client side services are
provided as interfaces.

Also if CLOVER does not support this is there any other tool which
supports my requerement?

Thanks.
-Vipul
 
A

a_szczeblewski

I'm using the CLOVER eclipse plugin. I have set of JUnit tests to test
my client side APIs. When I get the coverage report I see that
interface classes are not in it. I assume that since the interfaces
dont have any executable body, CLOVER removes from its report.

Please let me know with CLOVER, how can I get the coverage of methods
which are in the interfaces as all of my client side services are
provided as interfaces.

That doesn't make sense. As you've noticed, interfaces contain
declarations, not implementations (bodies) of methods. A declaration is
never called, it's the actual implementation that is executed, so can
be measured. There is no definition of method declaration coverage.

You write unit tests for implementations (actual code) - classes rather
than interfaces.
 
V

vipulk

Thanks for the reply.

Quite true. But the problem is I (and other members in my team) are
working in a project which has a framework defined by our customer and
we are not in a position to change it. Customer's requirement is to
test and see the coverage of client side methods which are provided by
interfaces.

As a trial I created the CLOVER report and manually made a summary for
the coverage of methods (in interfaces) by going through the report
analysing coverage of the implementation classes and creoss checking
them with respective interfaces. As it is a time consuming task, I want
a method to get the required coverage information which we can do more
frequentry.

Hope you can understand my situation. :)
 
A

a_szczeblewski

Thanks for the reply.

Quite true. But the problem is I (and other members in my team) are
working in a project which has a framework defined by our customer and
we are not in a position to change it. Customer's requirement is to
test and see the coverage of client side methods which are provided by
interfaces.

As a trial I created the CLOVER report and manually made a summary for
the coverage of methods (in interfaces) by going through the report
analysing coverage of the implementation classes and creoss checking
them with respective interfaces. As it is a time consuming task, I want
a method to get the required coverage information which we can do more
frequentry.

Hope you can understand my situation. :)

Sure, customer is always right ;)

The requirement is somehow strange. Coverage is measured for unit test,
and unit tests are (should be) run on actual implementations, but there
is no point for you in writing unit tests for your customer's code
(unless they outsource - and pay - you to do that).
What they really want is a coverage report for integration testing, and
I haven't seen a tool for that.

Maybe you could mock their implementation classes and show coverage of
those? Results would be the same...
 
Joined
Aug 11, 2006
Messages
1
Reaction score
0
Getting clover problem

Hi,

We have developed a web based API in eclipse and this is deployed on OC4J. Its functioning perfect, and we are interested to get the code coverage for this.
When I compile the application without enabling the clover, and put the jar file in OC4J, its working fine. But when I compile the application with enabling the clover and make the jar file of all the classes in .clover folder with classpaths while deploying this jar file, its gives the loading problem.

When I check all the classes are available in the jar file.

Can you please suggest me the possible reason and their solution. I also like to know, is clover compatible with OC4J?

Thanks and regards,
Dhananjay
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,262
Messages
2,571,049
Members
48,769
Latest member
Clifft

Latest Threads

Top