public void PushOne_CountShouldBecomeOne() { IFragment fragment = new FakeFragment(); this.collection.Push(fragment); Assert.AreEqual(1, this.collection.Count()); }
public void PopOneWhenCountOne_CountShouldBecomeZero() { IFragment fragment = new FakeFragment(); this.collection.Push(fragment); this.collection.Pop(); Assert.AreEqual(0, this.collection.Count()); }
public void PeekShouldNotChangeCount() { IFragment fragment = new FakeFragment(); this.collection.Push(fragment); int count1 = this.collection.Count(); fragment = this.collection.Peek(); int count2 = this.collection.Count(); Assert.AreEqual(count1, count2); }