public void AfterAddingAFontWithTagFontShouldReturnAsTaggedWithTheRightTag() { AssetPlugin plugin = new TestAssetPlugin(); plugin.AddFont(new BaseFont() { Name = "Bold", FontFilename = "Bold.otf" }); plugin.AddFont(new BaseFont() { Name = "H1", FontFilename = "H1.otf" }, new FontTag("Bold", "b")); plugin.GetFontByName("H1").Should().NotBeNull(); plugin.GetFontByName("Bold").Should().NotBeNull(); plugin.GetFontByTag("H1", "b").Should().NotBeNull(); plugin.GetFontByTag("H1", "b").Name.Should().Be("Bold"); }
public void GettingANonExistingTagReturnsNull() { AssetPlugin plugin = new TestAssetPlugin(); plugin.AddFont(new BaseFont() { Name = "H1", FontFilename = "H1.otf" }, new FontTag("Bold", "b")); plugin.GetFontByTag("H1", "c").Should().BeNull(); }
public void GettingANonExistingFontTagReturnsNull() { AssetPlugin plugin = new TestAssetPlugin(); plugin.GetFontByTag("Banana", "a").Should().BeNull(); }