[
https://issues.apache.org/jira/browse/AVRO-81?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Thiruvalluvan M. G. updated AVRO-81:
------------------------------------
Attachment: AVRO-81.patch
This is the modified version of the patch by Konstantin. This fixes the problem
reported by him. The trouble was testng can distinguish between arrays and
scalars in assertEquals() and do the right thing. JUnit requires you to call
assertArrayEquals() explicitly for arrays.
Now those tests pass. Still I see three errors in TestInvocationReporter,
TestOutputInterceptor and TestSuiteInterceptor.
I've noticed the following (all of them subtle, not serious):
- The classes from from both Junit4 and Junit3 are used. Junit3 package
names start with "junit" and Junit4 package names with "org.junit". Though they
seem to work together, it's better to stick to one version.
- The order of arguments for assertEquals() is different from Testng and
Junit. In junit, the first argument is the expected value and for testng it is
the actual. Again, there is no harm if we use the wrong order because, after
all, it checks for equality. But the error messages will be confusing.
- The fields of parametrized test classes, it is possible to make the input
fields final.
I've fixed these for tests in avro.io package. Other packages may have these.
I saw some opportunities, in Junit context, to refactor and reduce test code
for avro.io package. I'll take that up once conversion to Junit is over.
> Switch Avro's tests back to JUnit from current TestNG framework
> ---------------------------------------------------------------
>
> Key: AVRO-81
> URL: https://issues.apache.org/jira/browse/AVRO-81
> Project: Avro
> Issue Type: Test
> Reporter: Konstantin Boudnik
> Assignee: Konstantin Boudnik
> Attachments: AVRO-81.patch, AVRO-81.patch
>
>
> This issue has been opened in order to track possible future switch of
> testing framework for Avro. Currently it is based on TestNG, however because
> of a number of limitations this test framework is not likely to be used by
> any of Hadoop's subproject. Thus, Avro will have to be start using JUnit
> again.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.