public void TestImageFromLocalFile() { string fileName = Path.GetTempFileName(); Image image = new Bitmap(4, 4); image.Save(fileName); try { string imageName = Path.GetFileName(fileName); string filePath = Path.GetDirectoryName(fileName); renderer = new LinkInlineRenderer(filePath); inline.IsImage = true; Assert.DoesNotThrow(() => renderer.GetImage(imageName).Dispose()); } finally { File.Delete(fileName); } }
public void TestImageFromResource(string resourceName) { Assert.DoesNotThrow(() => renderer.GetImage(resourceName).Dispose()); }