db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bryan Pendleton (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (DERBY-5851) Inconsistent code coverage shown for LogicalPreparedStatement40
Date Sat, 14 Jul 2012 15:11:34 GMT

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

Bryan Pendleton commented on DERBY-5851:
----------------------------------------

As one more way to confirm that the problem is directly related to methods which exit by
throwing exceptions, why don't you try this:

1) Change one of those PreparedStatement40 methods so that instead of throwing an
exception, it just prints a message to the screen and returns normally. Also put a print
message in the LogicalPreparedStatement40 method that calls it
2) Run the PreparedstatementTest. It should fail, because it expects the method to throw
an exception. But it should show that both print statements are printed to the screen.
3) Check the code coverage report. Now it should show that the method is fully covered,
in BOTH PreparedStatement40 and LogicalPreparedStatement40

                
> 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
>            Assignee: 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

        

Mime
View raw message