You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Details

Recommendation type: Uncovered code blocks

Configurable: Yes

Filter category: Uncovered code blocks

Description

This type of recommendations helps you identify blocks of code that is not covered. By default, UTA detects 5 or more subsequent lines of uncovered code.

Example

 @Test
    public void testTryThis1()
        throws Throwable
    {
        ExampleServlet THIS = new ExampleServlet();
        try {
            THIS.tryThis((ServletContext)null);
        } catch (NullPointerException npe) {
            // expected
            return;
        }
        fail();
    }

The above test is incomplete and will not cover the tested method:

  • No labels