public class Student
{
public string Name { get; set; }
public int ID { get; set; }
}
...
var st1 = new Student
{
ID = 20,
Name = "ligaoren",
};
var st2 = new Student
{
ID = 20,
Name = "ligaoren",
};
Assert.AreEqual<Student>(st1, st2);// How to Compare two object in Unit test?
如何在单元测试中比较两个集合?