asolimando opened a new pull request #139: URL: https://github.com/apache/calcite-avatica/pull/139
This PR complements https://github.com/apache/calcite-avatica/pull/105/ by adding unit-tests for the fix, and improving coverage for Double/Float/Real in classes with tests related to the mapping of these data types (notably, `ArrayImplTest.java` and `ArrayTypeTest.java`). The PR has 5 commits: 1. improved test coverage for avatica/util/ArrayImplTest.java 2. reduced warnings in avatica/remote/ArrayTypeTest.java 3. improved test coverage for avatica/remote/ArrayTypeTest 4. [CALCITE-3163] Mapping of Float and Real in AbstractCursor#convertValue() does not adhere to JDBC specifications (unit-tests added) 5. [CALCITE-3163] Mapping of Float and Real in AbstractCursor#convertValue() does not adhere to JDBC specifications What each commit does: 1. Adds coverage for Float/Double/Real array component (before only Integer was covered) 2. Reduces few warnings (lambda replacing anonymous classes, redundant boxing, double negation in JUnit assert) 3. Added coverage to `Float` and `Real` (the latter treated "specially" since hsqldb does not adhere to JDBC standard, it maps `Real` to `Double` instead of `Float, it took me while to understand why the test was working, as it is now it's explicit, it serves as documentation and might save time to people down the line) 4. The unit-tests for the fix strictly speaking 5. The original commit 4. and 5. must be kept, 1-3 are optional but I think they add value, If 1-3 are dropped, I'd merge the two classes introduced in commit '2', since `UtilTestCommon` would have a method used only by `AbstractCursorTest`, it would make little sense. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
