Skip to content

Remove Redundant Syntax Element Tests - #488

Merged
alexanderlinne merged 2 commits into
mainfrom
remove-redundant-syntax-element-tests
Aug 28, 2026
Merged

alexanderlinne merged 2 commits into
mainfrom
remove-redundant-syntax-element-tests

Conversation

@alexanderlinne

Copy link
Copy Markdown
Collaborator

No description provided.

Superseded by ObjectSyntaxElementsTests.FollowCustomConditionTest and
FollowCustomPredicateTest, which cover the same two syntax elements with
snapshots. Its only unique behavior (building its own architecture from
the ArchUnitNETTests assembly and using Check()/HasNoViolations()/GetObjects())
isn't custom-syntax-specific and is exercised elsewhere. CustomRuleTestClass
was referenced only from within this file, so it goes too.

Signed-off-by: Alexander Linne <alexander.linne@tngtech.com>
…atTest, extract var should in BeNestedTest/NotBeNestedTest

BeDeclaredInTypesThatTest and NotBeDeclaredInTypesThatTest duplicated the
"Complex conditions" sub-sections already present in BeDeclaredInTest and
NotBeDeclaredInTest - same helper objects, same assertions. Delete the
standalone tests rather than the sub-sections; coverage is unaffected since
BeDeclaredInTypesThat()/NotBeDeclaredInTypesThat() are already exercised there.

TypeSyntaxElementsTests.BeNestedTest/NotBeNestedTest inlined the full
Types().That().Are(...).Should() chain on every line instead of extracting
`var should = ...` like the rest of the file. No behavior change, so no
snapshot changes.

Signed-off-by: Alexander Linne <alexander.linne@tngtech.com>
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.49%. Comparing base (ec2373d) to head (d25ea24).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #488   +/-   ##
=======================================
  Coverage   83.49%   83.49%           
=======================================
  Files         259      259           
  Lines       12450    12450           
  Branches     1210     1210           
=======================================
  Hits        10395    10395           
  Misses       1696     1696           
  Partials      359      359           

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

@alexanderlinne
alexanderlinne merged commit 0849e0e into main Aug 28, 2026
10 checks passed
@alexanderlinne
alexanderlinne deleted the remove-redundant-syntax-element-tests branch August 28, 2026 16:04
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.

3 participants