public void TestClear1() { PriorityLinkedList <JobTimeoutModel> pq = this.CreateSimpleQueue(); pq.Clear(); Assert.Equal(0, pq.Count); Assert.False(pq.Contains(this.j1)); Assert.False(pq.Contains(this.j2)); Assert.False(pq.Contains(this.j3)); }
public void TestPeek() { PriorityLinkedList <JobTimeoutModel> pq = this.CreateSimpleQueue(); JobTimeoutModel front = pq.Peek(); Assert.Equal(this.j1, front); Assert.Equal(3, pq.Count); pq.Clear(); front = pq.Peek(); Assert.Null(front); Assert.Equal(0, pq.Count); }