public void SetParent()
        {
            var dl = new List <TestItemDM>();
            var bl = new DerivedList {
                Metadata = { DataProvider = { Data = dl } }
            };

            bl.Add(new TestItemBM());
            bl.Add(new TestItemBM());
        }
        public void AddSameItemToMultipleLists()
        {
            var bl = new DerivedList {
                Metadata = { DataProvider = { Data = new List <TestItemDM>() } }
            };
            var bi = new TestItemBM();

            bl.Add(bi);
            var bl2 = new DerivedList {
                Metadata = { DataProvider = { Data = new List <TestItemDM>() } }
            };

            Assert.Throws <InvalidOperationException>(delegate { bl2.Add(bi); });
        }