LediReader
/
EpubReader
/Source
/VersOne.Epub.Test
/Unit
/Schema
/Opf
/Metadata
/EpubMetadataFormatTests.cs
| using VersOne.Epub.Schema; | |
| namespace VersOne.Epub.Test.Unit.Schema.Opf.Metadata | |
| { | |
| public class EpubMetadataFormatTests | |
| { | |
| private const string FORMAT = "test-format"; | |
| private const string ID = "format"; | |
| [] | |
| public void ConstructorWithNonNullParametersTest() | |
| { | |
| EpubMetadataFormat epubMetadataFormat = new(FORMAT, ID); | |
| Assert.Equal(FORMAT, epubMetadataFormat.Format); | |
| Assert.Equal(ID, epubMetadataFormat.Id); | |
| } | |
| [] | |
| public void ConstructorWithNullContributorTest() | |
| { | |
| Assert.Throws<ArgumentNullException>(() => new EpubMetadataFormat(null!, ID)); | |
| } | |
| [] | |
| public void ConstructorWithNullIdTest() | |
| { | |
| EpubMetadataFormat epubMetadataFormat = new(FORMAT, null); | |
| Assert.Equal(FORMAT, epubMetadataFormat.Format); | |
| Assert.Null(epubMetadataFormat.Id); | |
| } | |
| } | |
| } | |