I am trying to compare two lists with
CollectionAssert.AreEqual(ListExpected, ListActual);
But I get an exception
Expected and actual are both <System.Collections.Generic.List`1[API.Program.Relation]> with 11 elements Values differ at index [0] Expected: <API.Program.Relation> But was: <API.Program.Relation>
But when I compared the null element using Assert.AreEqual in a field by field, everything was fine.
Any idea why I can't compare using CollectionAssert
Night walker
source share