[ 
https://issues.apache.org/jira/browse/DERBY-5851?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13409554#comment-13409554
 ] 

Knut Anders Hatlen commented on DERBY-5851:
-------------------------------------------

That's very odd...

I applied your patch and added
    System.out.println("I AM CALLED!");
at the beginning of LogicalPreparedStatement40.setNString() before I ran the 
emma-single target. I saw that "I AM CALLED!" got printed to the console, but 
the EMMA coverage report claimed that setNString() hadn't been called.

So it would look like an EMMA bug. However, I ran the same experiment with 
JaCoCo (ran the jacoco-junit-single target instead of emma-single) and got the 
exact same results: "I AM CALLED!" was printed, but the coverage report said 
the code wasn't exercised.

It must be something our tests do that confuses the code coverage tools, but I 
don't know what it could be.
                
> Inconsistent code coverage shown for LogicalPreparedStatement40
> ---------------------------------------------------------------
>
>                 Key: DERBY-5851
>                 URL: https://issues.apache.org/jira/browse/DERBY-5851
>             Project: Derby
>          Issue Type: Bug
>            Reporter: Mohamed Nufail
>            Priority: Minor
>         Attachments: derby-5851-CPdecorator.patch
>
>
> I tried running 
> org.apache.derbyTesting.functionTests.tests.jdbc4.PreparedStatementTest with 
> a connectionCPDecorator in a JDBC4 environment. So this should actually run 
> the test with LogicalPreparedStatement40 statements. 
> But in code coverage report methods such as setNClob show no coverage in 
> LogicalPreparedStatement40 class. But in PreparedStatement40 class all these 
> methods are shown as covered. Actually those method calls should go to 
> PreparedStatement40 through LogicalPreparedStatement40. But it is not shown 
> in emma code coverage report.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to