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

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

Thanks for the patch, Junjie! I added a couple of line breaks so that no lines 
were longer than 80 characters and committed the patch with revision 673057.

A couple of additional things that could be done:

1) The test should be added to the _Suite class in the unitTest/junit directory 
to make it run with the rest of the regression tests.

2) The original code also verified that the compressed length was increased at 
the correct boundaries (it only printed it, though). Perhaps it is possible to 
add some code to checkInt() and checkLong() to see that the length is as 
expected? Currently, it compares the return value from sizeInt() with the 
actual length, which is fine, but it would be good also to verify that 
sizeInt() and sizeLong() return the correct value.

> Move test code from CompressedNumber to a unit test
> ---------------------------------------------------
>
>                 Key: DERBY-3742
>                 URL: https://issues.apache.org/jira/browse/DERBY-3742
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Knut Anders Hatlen
>            Assignee: Junjie Peng
>            Priority: Minor
>         Attachments: derby-3742-patch.txt
>
>
> The class org.apache.derby.iapi.services.io.CompressedNumber contains a 
> significant amount of test code. This code should be moved into a unit test 
> to reduce the footprint of the product jars and to ensure that the code is 
> tested in the regression tests. The test code is located in the methods 
> checkInt(), checkLong() and main().

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

Reply via email to