public void When_Entity_Compared_To_SameTypeEntity_SameId_Then_True() { ObjectId id = ObjectId.GenerateNewId(); var a1 = new TestEntityA(id); var a2 = new TestEntityA(id); Assert.True(a1 == a2); }
public void When_Entity_Compared_To_DifferentTypeEntity_Then_False() { var aId = ObjectId.GenerateNewId(); var bId = ObjectId.GenerateNewId(); var a = new TestEntityA(aId); var b = new TestEntityB(bId); Assert.False(a == b); }
public void When_Entity_Compared_To_SameTypeEntity_DifferentId_Then_False() { var aId = ObjectId.GenerateNewId(); var bId = ObjectId.GenerateNewId(); var a1 = new TestEntityA(aId); var a2 = new TestEntityA(bId); Assert.False(a1 == a2); }
public void When_Entity_Compared_To_NullEntity_Then_False() { var e = new TestEntityA(); Assert.False(e == null); }