public void Get_and_set_unique_key() { var m = new AllPropertiesMappingManager(); m.SetUniqueKey(typeof(Entity).GetProperty("Id")); var pk = m.GetUniqueKey(typeof (Entity)); Assert.IsNotNull(pk); Assert.IsNotNull(pk.Property); Assert.IsNotNull(pk.FieldName); Assert.AreEqual("Id", pk.Property.Name); Assert.AreEqual("Id", pk.FieldName); }
public void SetUniqueKey_null_throws() { var m = new AllPropertiesMappingManager(); m.SetUniqueKey(null); }