mihaibudiu commented on PR #3344: URL: https://github.com/apache/calcite/pull/3344#issuecomment-1660614422
I actually wrote a long email on the dev mailing list about this problem. That's the interesting thing: you actually *have* added tests for these cases for SPLIT in SqlOperatorTest, but the tests didn't hit these bugs. That's because that compilation path take in that line of tests does not apply the reduction rules which cause the incorrect expansions. Every test should be evaluate in two ways: compile time evaluation, and run-time evaluation, and the two results should be identical. Currently SqlOperatorTest only tests the "run-time" evaluation. I think there should be a fixture to do this kind of testing; it is pointless to write each test twice. I bet it will catch quite a few bugs, I have seen this happen with many other functions. -- 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]
