Ejemplo n.º 1
0
        public void Test_EditEntryTitle_EntryRecord()
        {
            EntryRecord  h = new EntryRecord("Test", CompareBy.AlphabetTitle, false);
            EntryElement e = new EntryElement("http://www.duckduckgo.com", "DuckDuckGo", CompareBy.AlphabetTitle);

            h.AddEntry(e, false);
            Assert.AreEqual(h.GetList()[0].Title, "DuckDuckGo", "Expected and Actual Title mismatch");

            h.EditEntryTitle("DuckDuckGo", "DifferentTitle", false);
            Assert.AreEqual(h.GetList()[0].Title, "DifferentTitle", "Expected and Actual Title mismatch");
        }
Ejemplo n.º 2
0
        public void Test_EditEntryTitleException_EntryRecord()
        {
            EntryRecord h = new EntryRecord("Test", CompareBy.AlphabetTitle, false);

            Assert.ThrowsException <System.ArgumentOutOfRangeException>(() => h.EditEntryTitle("DuckDuckGo", "DifferentTitle", false));
        }