예제 #1
0
 public void GetFeedsShouldReturnListOfFeeds()
 {
     var catalog = new Catalog("jdoe");
     var feeds = catalog.GetFeeds();
     Assert.AreEqual(2, feeds.Count());
     catalog = new Catalog("another");
     feeds = catalog.GetFeeds();
     Assert.AreEqual(1, feeds.Count());
 }
예제 #2
0
 public void SaveFeedShouldCreateNewFeed()
 {
     var catalog = new Catalog("jdoe");
     var feed = catalog.AddFeed(new AtomFeed("http://mytest/"));
     Assert.IsNotNull(feed);
     Assert.AreEqual("jdoe", feed.Owner);
     Assert.AreEqual("http://mytest/", feed.Locator);
     Assert.AreEqual(3, catalog.GetFeeds().Count());
     Assert.AreEqual(4, this.context.Feeds.Count());
 }