Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Add missing assertion in ObjectSyntaxElementsTests
Signed-off-by: Alexander Linne <[email protected]>
  • Loading branch information
alexanderlinne committed Sep 26, 2025
commit ad21b7b98f39e3022e8d64b3d645f6d73ce18468
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,7 @@ public async Task HaveAnyAttributesTest()
should = Types().That().Are(helper.ClassWithTwoAttributes).Should();

helper.AddSnapshotSubHeader("Conditions");
should.HaveAnyAttributes();
should.HaveAnyAttributes().AssertOnlyViolations(helper);
should.HaveAnyAttributes(new List<Attribute>()).AssertOnlyViolations(helper);
should.HaveAnyAttributes(new List<System.Type>()).AssertOnlyViolations(helper);
should.HaveAnyAttributes(Attributes().That().HaveFullName(helper.NonExistentObjectName)).AssertOnlyViolations(helper);
Expand Down Expand Up @@ -1650,7 +1650,7 @@ public async Task NotCallAnyTest()
should = MethodMembers().That().Are(helper.MethodWithSingleDependency).Should();

helper.AddSnapshotSubHeader("Conditions");
should.NotCallAny();
should.NotCallAny().AssertNoViolations(helper);
should.NotCallAny(new List<MethodMember>()).AssertNoViolations(helper);

helper.AddSnapshotSubHeader("Predicates");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,15 @@ Message:



Query: Types that are "AttributeNamespace.ClassWithTwoAttributes" should have any of no attributes (impossible)
Result: False
Description: AttributeNamespace.ClassWithTwoAttributes only has attributes "AttributeNamespace.Attribute1" and "AttributeNamespace.Attribute2"
Message:
"Types that are "AttributeNamespace.ClassWithTwoAttributes" should have any of no attributes (impossible)" failed:
AttributeNamespace.ClassWithTwoAttributes only has attributes "AttributeNamespace.Attribute1" and "AttributeNamespace.Attribute2"



Query: Types that are "AttributeNamespace.ClassWithTwoAttributes" should have any Attributes that have full name "NotTheNameOfAnyObject"
Result: False
Description: AttributeNamespace.ClassWithTwoAttributes only has attributes "AttributeNamespace.Attribute1" and "AttributeNamespace.Attribute2"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,12 @@ Description: System.Void MethodDependencyNamespace.MethodDependencyClass::Method
Message:
All Evaluations passed

Query: Method members that are "System.Void MethodDependencyNamespace.MethodDependencyClass::MethodWithSingleDependency()" should not call any of no methods (always true)
Result: True
Description: System.Void MethodDependencyNamespace.MethodDependencyClass::MethodWithSingleDependency() passed
Message:
All Evaluations passed

----- Predicates -----

Query: Method members that are "System.Void MethodDependencyNamespace.MethodDependencyClass::MethodWithSingleDependency()" should be Method members that do not call any of no methods (always true)
Expand Down
Loading