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

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

The patch looks like a good improvement. Some small comments about the test:

- testDerby2927() should probably use this bug number (5945) instead.

- The try/catch statements in testDerby2927() should call fail() last in the 
try blocks to report if the call unexpectedly succeeds.

- When checking the message text, maybe use getMessage() instead of toString(), 
since toString() includes the exception class name, and I suspect the assert 
will fail on Java 5 (where it's a plain SQLException vs SQLSyntaxErrorException 
on Java 6 and later).

- testDerby2927() ends with a call to rollback(), but it never disables 
auto-commit, so that's presumably a no-op.

- The suite() method sets the locale by using territory based collation. 
Strictly speaking, changing the collation isn't necessary, so an alternative is 
to use TestConfiguration.singleUseDatabaseDecorator() + LocaleTestSetup.
                
> Inappropriate error message when calling a procedure as a function (as if it 
> had a return value)
> ------------------------------------------------------------------------------------------------
>
>                 Key: DERBY-5945
>                 URL: https://issues.apache.org/jira/browse/DERBY-5945
>             Project: Derby
>          Issue Type: Improvement
>          Components: JDBC, SQL
>            Reporter: Holger Rehn
>            Assignee: Dag H. Wanvik
>            Priority: Minor
>         Attachments: derby-2927-5945-diag-2.diff, 
> derby-2927-5945-diag-2.stat, derby-2927-5945-diag-3.diff, 
> derby-2927-5945-diag-3.stat, derby-2927-5945-diag.diff, 
> derby-2927-5945-diag.stat
>
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to