public void GetNext() { Assert.AreEqual(0, _unitUnderTest.Count); PageToCrawl page1 = new PageToCrawl(new Uri("http://a.com/1")); PageToCrawl page2 = new PageToCrawl(new Uri("http://a.com/2")); PageToCrawl page3 = new PageToCrawl(new Uri("http://a.com/3")); _unitUnderTest.Add(page1); _unitUnderTest.Add(page2); _unitUnderTest.Add(page3); Assert.AreEqual(3, _unitUnderTest.Count); Assert.AreEqual(page1.Uri, _unitUnderTest.GetNext().Uri); Assert.AreEqual(page2.Uri, _unitUnderTest.GetNext().Uri); Assert.AreEqual(page3.Uri, _unitUnderTest.GetNext().Uri); Assert.AreEqual(0, _unitUnderTest.Count); }