mihaibudiu commented on code in PR #3482:
URL: https://github.com/apache/calcite/pull/3482#discussion_r1372150912


##########
testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java:
##########
@@ -919,8 +919,8 @@ void testCastIntervalToInterval(CastType castType, 
SqlOperatorFixture f) {
   void testCastWithRoundingToScalar(CastType castType, SqlOperatorFixture f) {
     f.setFor(SqlStdOperatorTable.CAST, VmName.EXPAND);
 
-    f.checkFails("cast(1.25 as int)", "INTEGER", true);
-    f.checkFails("cast(1.25E0 as int)", "INTEGER", true);
+    f.checkScalar("cast(1.25 as int)", 1, "INTEGER NOT NULL");

Review Comment:
   The new version of this test looks correct to me. I wonder why the original 
test was expected to fail.



##########
core/src/test/java/org/apache/calcite/test/SqlOperatorUnparseTest.java:
##########
@@ -99,6 +99,11 @@ String rewrite(String sql) throws SqlParseException {
     }
   }
 
+  @Override @Disabled("Runtime error message differs after parsing and 
unparsing")

Review Comment:
   Something is weird here, because the super function called doesn't have the 
same name. 
   But since the test is disabled, it doesn't really matter.
   This fixture was created to find bugs in unparsing, and it's possible that 
it does find such a bug. I will investigate, and if that's the case I will file 
an issue for it.



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to