[
https://issues.apache.org/jira/browse/AVRO-2245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16667635#comment-16667635
]
ASF GitHub Bot commented on AVRO-2245:
--------------------------------------
nandorKollar commented on issue #351: [AVRO-2245] Improve java tests for
compression codecs
URL: https://github.com/apache/avro/pull/351#issuecomment-434046221
Thanks for spotting this problem! I support refactoring these to
parametrized tests. Could you please address my only concern? Also (despite
probably not very often used part of Avro) Trevni has similar meaningless tests
(with the same name as these), if it requires only low effort, could you please
fix those too?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> Java codec testing improvements
> -------------------------------
>
> Key: AVRO-2245
> URL: https://issues.apache.org/jira/browse/AVRO-2245
> Project: Avro
> Issue Type: Improvement
> Components: java
> Reporter: Jacob Tolar
> Priority: Minor
>
> In the Avro Java implementation, TestBZip2Codec and TestZstandardCodec are
> both laughably wrong.
> For example, the last lines of TestBZip2Codec:
> {code:java}
> byte[] outputByteArray = decompressedBuffer.array();
> for (int i = 0; i < inputByteSize; i++) {
> inputByteArray[i] = outputByteArray[i];
> }
> {code}
> There should be an assertEquals in there not an assignment statement. (And if
> you put assertEquals there, the test actually fails...).
> I will send a PR that replaces these tests with a correct parametrized test
> for all codecs.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)