Repository navigation
Conversation
…d short-circuit Add parameterized LogicExpressionTest covering the full 3x3 TRUE/FALSE/ UNKNOWN matrix for AND and OR, the UNKNOWN-matches-false rule, and short-circuit proofs via evaluation-counting operands.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #11348 +/- ##
=============================================
- Coverage 49.73% 49.69% -0.05%
+ Complexity 14348 14340 -8
=============================================
Files 1390 1390
Lines 103246 103246
Branches 13502 13502
=============================================
- Hits 51354 51310 -44
- Misses 45696 45742 +46
+ Partials 6196 6194 -2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
RockteMQ-AI
left a comment
There was a problem hiding this comment.
Review by github-manager-bot
Summary
Adds parameterized LogicExpressionTest pinning the SQL92 three-valued boolean logic truth tables and short-circuit behavior.
Findings
- [Info]
LogicExpressionTest.java— The 3x3 operand matrix (TRUE/FALSE/UNKNOWN) for both AND and OR is comprehensive. TheOperandstub with evaluation counting is a clean way to verify short-circuit behavior. - [Info] The UNKNOWN-matches-false rule (
matches()returns false for null) is correctly tested.
Suggestions
- None. Well-structured parameterized tests that pin important semantic behavior.
Automated review by github-manager-bot
|
Issue Evaluation Category: The need for direct LogicExpression truth-table tests is valid. The SQL92 three-valued logic (TRUE/FALSE/UNKNOWN) used in property-filter subscriptions currently lacks explicit coverage for:
Impact: Without these tests, regressions in filter logic could silently change message routing behavior. The proposed parameterized test approach (9 combinations × 6 methods = 54 test cases) provides comprehensive coverage. Test-only change with no production code impact. Automated evaluation by github-manager-bot |
2615309 to
905bb93
Compare
|
Hi @RongtongJin, sorry for the ping — this PR has been open for a while without a review yet. The change is small and focused (pin LogicExpression truth table and short-circuit), and all tests and CI pass on my side. Would you mind taking a look when you get a chance? If it looks good, merging it would be much appreciated — happy to adjust anything if needed. Thanks a lot! |
Which Issue(s) This PR Fixes
Fixes #11339
Brief Description
Adds a parameterized
LogicExpressionTestpinning the SQL92 boolean logic every property-filter subscription compiles through:ANDandOR, including UNKNOWN propagation (null AND TRUE= UNKNOWN,null OR FALSE= UNKNOWN);matches()treats UNKNOWN as no-match;FALSE AND …/TRUE OR …is already decided, and provably is evaluated otherwise.Test-only change; no production code touched.
How Did You Test This Change?
mvn -pl filter -Dtest=LogicExpressionTest -Dsurefire.failIfNoSpecifiedTests=false test(JDK 11, PR base commit):Tests run: 54, Failures: 0, Errors: 0(9 parameter combinations x 6 test methods).