db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Manjula Kutty (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-2458) Convert lang/unaryArithmeticDynamicParamter.java to junit
Date Mon, 19 Mar 2007 19:35:32 GMT

    [ https://issues.apache.org/jira/browse/DERBY-2458?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12482190

Manjula Kutty commented on DERBY-2458:

>>Patch doesn't compile for me, 
>> [javac] C:\_work\svn_clean4\trunk\java\testing\org\apache\derbyTesting\funct 
>>nTests\tests\lang\UnaryArithmeticParameterTest.java:262: assertColumnTypes(jav 
>>a.sql.ResultSet,int[]) in org.apache.derbyTesting.junit.JDBC cannot be applied t 
>>o (java.sql.PreparedStatement,int[]) 
>>    [javac] JDBC.assertColumnTypes(ps,expectedTypes); 
>>    [javac] ^ 

>>Seems like some other changes are missing. 
Sorry  that in the last patch I forgot to include the changes I made in the junit/JDBC.java

>>The comments don't indicate why this test requires JDBC 3? I couldn't see anything
obvious that would stop this running on JSR169. 
Added comments to to reason why we need JDBC3. Also if I do specify only about JDBC3, I thought
the test will run in JSR 169 (I may be wrong here...Please clear me if I'm wrong).

>>FYI - a single patch file is much more convienent, than a separate one for the change
to the suite file. 
Sure I will be attaching the recent patch in a single set.

>>For code like this: 
>>+ Object[][] expectedRows = new Object[][]{{new String("-2"),new String("2")},{new
String("-2"),new String("2")}}; 
>>+ JDBC.assertFullResultSet(ps.executeQuery(), expectedRows, true); 

>>it can be cleaned up a couple of ways: 
>>   - new String("-2") is kind of pointless, "-2" is a String object, just it can be
used directly. 
>>   - a utility assertFullResultSet method exists that takes strings, so the code could

>> + String[][] expectedRows = new String[][]{{"-2", "2"},{-2","2"}}; 
>>+ JDBC.assertFullResultSet(ps.executeQuery(), expectedRows); 

Will be fxing this in the next patch

>>It looks like the suite method runs the fixtures twice in embedded, once adding them
directly and once through defaultSuite 
I thought I give 
return   TestConfiguration.defaultSuite(UnaryArithmeticParameterTest.class);
The test will run both embedded and n/w server mode. (Please correct me if I'm wrong)

> Convert lang/unaryArithmeticDynamicParamter.java to junit
> ---------------------------------------------------------
>                 Key: DERBY-2458
>                 URL: https://issues.apache.org/jira/browse/DERBY-2458
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>    Affects Versions:
>            Reporter: Manjula Kutty
>         Assigned To: Manjula Kutty
>            Priority: Trivial
>             Fix For:
>         Attachments: DERBY-2458_diff_03_16.txt, DERBY-2458_diff_03_16_ver2.txt, DERBY-2458_diff_ver1.txt,
> Place holder to convert lang/unaryArithmeticDynamicParameter.java to junit

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message