public void List_Remove_WithValidItem_RemovesItem()
            {
                var source = new List <int> {
                    13
                };
                var  list   = new ReadWriteList <int>(source);
                bool result = list.Remove(13);

                Assert.IsTrue(result, "Item should be found.");
                Assert.IsTrue(source.SequenceEqual(new int[] { }), "Item should be removed.");
            }
            public void List_Remove_WithInvalidItem_DoesNotFindItem()
            {
                var source = new List <int> {
                    13
                };
                var  list   = new ReadWriteList <int>(source);
                bool result = list.Remove(17);

                Assert.IsFalse(result, "Item should not be found.");
                Assert.IsTrue(source.SequenceEqual(new[] { 13 }), "Item should not be removed.");
            }
Beispiel #3
0
 public void RemoveChannel(AbstractNetowrkChannel channel)
 {
     _channels.Remove(channel);
 }