public void MetaWrapper_GetMetaData_returns_null_if_item_not_registered() { var entity = new Entity(); var result = MetaWrapper <Entity, EntityMetaData> .GetMetaData(entity); Assert.IsNull(result); }
public void Meta_wrapper_identity_property_cast_is_same() { var entity = new Entity(); var wrapped = MetaWrapper <Entity, EntityMetaData> .Create(entity, new EntityMetaData() { Id = Guid.NewGuid().ToString() }); MetaWrapper <Entity, EntityMetaData> unwrapped = wrapped; Assert.AreEqual(unwrapped.Meta.Id, MetaWrapper <Entity, EntityMetaData> .GetMetaData(wrapped).Id); }