public void ClearBogtyvenChaptersTest() { var writer = new EpubWriter(EpubReader.Read(@"Samples/epub-assorted/bogtyven.epub")); writer.ClearChapters(); var epub = WriteAndRead(writer); Assert.AreEqual(0, epub.TableOfContents.Count); }
public void ClearBogtyvenChaptersTest() { var writer = new EpubWriter(EpubReader.Read(@"Samples/epub-assorted/afrique_du_sud_2016_carnet_petit_fute.epub", null)); writer.ClearChapters(); var epub = WriteAndRead(writer); Assert.AreEqual(0, epub.TableOfContents.EpubChapters.Count()); }
public void ClearChaptersTest() { var writer = new EpubWriter(); writer.AddChapter("Chapter 1", "bla bla bla"); writer.AddChapter("Chapter 2", "foo bar"); writer.AddChapter("Chapter 3", "fooz barz"); var epub = WriteAndRead(writer); Assert.AreEqual(3, epub.TableOfContents.Count); writer = new EpubWriter(epub); writer.ClearChapters(); epub = WriteAndRead(writer); Assert.AreEqual(0, epub.TableOfContents.Count); }