0

Is there any way to assert that all properties of objectA are different from all properties of objectB using FluentAssertions? objectA and objectB are instances of the same class.

.BeEquivalentTo() checks if any of the property is different. I'm looking for the same check that passes only if both objects have no equal properties and fails if at least one property is the same.

Andrei
  • 450
  • 2
  • 9

1 Answers1

0

Unfortunately not. I recommend requesting an improvement at https://github.com/fluentassertions/fluentassertions/issues

Dennis Doomen
  • 8,368
  • 1
  • 32
  • 44
  • Asked [a feature request for that now](https://github.com/fluentassertions/fluentassertions/issues/2289) as it apparently really is not possible as [I have had the same question](https://stackoverflow.com/questions/77025806/throw-on-additional-members-in-source-object-with-fluentassertions-which-are-not). – rklec Sep 01 '23 at 20:21