Jonas Nyrup
Jonas Nyrup
If your AST class overrides `bool Equals(object obj)` a workaround right now would be to use `oneAST.Should().Be(anotherAST);` should work. But I agree that it could be beneficial to have some...
The framework currently assumes that when a class implements `IEnumerable` or `IEnumerable`, two instances of that class are equivalent, when the implemented enumerable parts are equivalent. If possible you could...
@grahambunce We had a lot of changes between 4.X and 5.0, see https://www.continuousimprover.com/2018/02/fluent-assertions-50-best-unit-test.html#redefining-equivalency You should probably use ```cs result.Should().BeEquivalentTo( new IFragmentInjector[]{...}, opt => opt.RespectingRuntimeTypes()) ``` If that does not help,...
Can we add a test to exercise the missed path? i.e. the getter for `CollectionMemberObjectInfo.ParentType`. I tried out the added test `Can_exclude_all_properties_of_the_parent_type` locally, and omitting `si.ParentType == expectation.GetType()` still makes...
Thanks for reporting this. I did some quick investigations, but I don't have a solution/workaround yet. Here are my findings so far. The case can effectively be reduced to this:...
`ComparingByValue` is not currently available on `IDataEquivalencyAssertionOptions` which is what `DataTableAssertions.BeEquivalentTo` uses, but it could easily be exposed. One workaround for now is to define an extension method ```cs public...
> To add it as a well-known type to the HasValueSemantics type. Ahh, had thought about that one. Sounds reasonable.
Another workaround for now is to hook into the default `AssertionOptions`. MSTest has [`[AssemblyInitialize]`](https://www.meziantou.net/mstest-v2-test-lifecycle-attributes.htm#initialize-cleanup-b). For xUnit it can be done using a custom framework. https://fluentassertions.com/tips/#using-global-assertionoptions For .NET 5 or greater...
For anyone willing to pick up this task, be aware that comparing sequences with `BeEquivalentTo` can compare collections in either `WithStrictOrdering()` or `WithoutStrictOrdering()`, where the latter is the default. The...
Which part don't you get? `a → b` is called implication and is read "a implies b" and is logically equivalent to `!a || b`. https://en.m.wikipedia.org/wiki/Material_conditional