Q

Choosing code coverage tools

Code coverage is an important aspect of software testing, so how do you choose the right tool? Testing expert Mike Kelly discusses tools he's used what points testers should consider when it comes to code coverage.

This Content Component encountered an error
I am doing my project in test case privatization using Java. Which tool is the best one for finding code coverage? Which tool gives the intermediate results while finding code coverage?

I've personally worked on project teams where we've used EMMA, Atlassian's Clover, and IBM Rational's PureCoverage (currently part of the PurifyPlus suite of tools) to capture code coverage information.

More important than the focus on tools, I'd recommend some articles on code coverage.
EMMA is an open source tool, and I know you can find other open source tools for code coverage in Java on Java-Source.net. I never developed a particular affinity for one tool over the other. I walked away from these experiences with the feeling we could have been equally effective with any of them.

More important than the focus on tools, I'd recommend some articles on code coverage that might help make sure you're focusing on the right aspects:

  • Depending on your level of experience with code coverage, Steve Cornett's article Code Coverage Analysis can serve as a good primer for the topic. If you already know what you're looking at, skip that one and move on to the next couple of references.


  • Next, take a look at Andrew Glover's article In pursuit of code quality: Don't be fooled by the coverage report. It has some excellent examples and covers a lot of the early mistakes I made when first evaluating coverage tools.


  • Finally, no list on code coverage articles would be complete without Brian Marick's paper, How to Misuse Code Coverage (PDF). It's an essential read for a number of reasons, not the least of which is that it provides more useful examples that might help you evaluate the tools you look at.
  • Software testing resources:
    How to determine test coverage

    Find software bugs, defects using code coverage

    Test coverage: Finding all the defects in your application

    I would recommend trying a couple of different tools and see which you like best. Depending on your support requirements, you might want to evaluate some of the commercial options available. There are many of them out there, each with their own claim to fame.

    This was first published in September 2008

    Dig deeper on Software Testing and QA Fundamentals

    Pro+

    Features

    Enjoy the benefits of Pro+ membership, learn more and join.

    Have a question for an expert?

    Please add a title for your question

    Get answers from a TechTarget expert on whatever's puzzling you.

    You will be able to add details on the next page.

    0 comments

    Oldest 

    Forgot Password?

    No problem! Submit your e-mail address below. We'll send you an email containing your password.

    Your password has been sent to:

    -ADS BY GOOGLE

    SearchSOA

    TheServerSide

    SearchCloudApplications

    SearchAWS

    SearchBusinessAnalytics

    SearchFinancialApplications

    SearchHealthIT

    Close