Skip to content

Fix And/Or not being commutative when combining rules - #504

Open
brandhuf wants to merge 2 commits into
TNG:mainfrom
brandhuf:commutative-and-or
Open

brandhuf wants to merge 2 commits into
TNG:mainfrom
brandhuf:commutative-and-or

Conversation

@brandhuf

@brandhuf brandhuf commented Oct 2, 2026

Copy link
Copy Markdown
Contributor
  • ArchRule.And/Or and SliceRule.And/Or now pass this instead of _ruleCreator to CombinedArchRule and CombinedArchRuleDefinition
  • ArchRuleCreator.HasNoViolations now correctly returns false when RequirePositiveResults is set but no objects matched the predicate

Signed-off-by: Fritz Brandhuber <fritz.brandhuber@tngtech.com>
Signed-off-by: Fritz Brandhuber <fritz.brandhuber@tngtech.com>
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.33%. Comparing base (dcf76a3) to head (57b0a6c).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #504      +/-   ##
==========================================
- Coverage   86.33%   86.33%   -0.01%     
==========================================
  Files         260      260              
  Lines       12496    12495       -1     
  Branches     1216     1215       -1     
==========================================
- Hits        10789    10788       -1     
  Misses       1372     1372              
  Partials      335      335              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants