public void RemoveFromACollection(HasProperty val) { aCollection.Remove(val); }
public void CreateProxyWithVirtualRemoveFrom() { Type proxyType = ProxyCreator.CreateProxyType(typeof (HasCollectionWithVirtualAccessors)); var proxy = (HasCollectionWithVirtualAccessors) Activator.CreateInstance(proxyType); injector.InitDomainObject(proxy); var hasProperty = new HasProperty(); proxy.ACollection.Add(hasProperty); Assert.IsTrue(proxy.ACollection.Contains(hasProperty)); proxy.RemoveFromACollection(hasProperty); Assert.IsFalse(proxy.ACollection.Contains(hasProperty)); }
public void AddToACollection(HasProperty val) { aCollection.Add(val); }