我必须考虑到只有共享属性比较两个集合。 如果我了解丹尼斯对How to combine collection and property assertions using fluent-assertions?的评论,则应该从2.0版开始工作。FluentAssertions:比较名单成员的共享属性
我使用这个API:
ActualOes.ShouldHave().SharedProperties().EqualTo(expectedOes);
ActualOes是IEnumerable<IOe>
型和expectedOes是IEnumerable<Object>
其中的元素的一个匿名类型的共享对象只是与实际IOe
接口的一些特性。
当我运行这个,FA抱怨失踪的属性。
我使用了错误的API吗?
已更新为使该仿制药在帖子中正确显示。 – paulroho