public void SeveralDisposeCallsNotThrowsException() { RichQueue <int> richQueue = new RichQueue <int>(); richQueue.Dispose(); richQueue.Dispose(); }
public void PushThrowsOnDisposedObject() { RichQueue <int> richQueue = new RichQueue <int>(); richQueue.Dispose(); Assert.Catch <ObjectDisposedException>(() => richQueue.Push(5)); }
public void CountThrowsOnDisposedObject() { RichQueue <int> richQueue = new RichQueue <int>(); richQueue.Push(5); richQueue.Dispose(); Assert.Catch <ObjectDisposedException>(() => { var count = richQueue.Count; }); }