public void GenerateMemoryThumbnail_HappyPath_Ok() { using var tempFile = new TempFile(TestFileUrl, BaseTestFolder); var buffer = DroneDB.GenerateThumbnail(tempFile.FilePath, 300); buffer.Length.Should().BeGreaterThan(0); }
public void GenerateThumbnail_HappyPath_Ok() { using var tempFile = new TempFile(TestFileUrl, BaseTestFolder); var destPath = Path.Combine(Path.GetTempPath(), "test.jpg");//Path.GetTempFileName(); try { DroneDB.GenerateThumbnail(tempFile.FilePath, 300, destPath); var info = new FileInfo(destPath); info.Exists.Should().BeTrue(); info.Length.Should().BeGreaterThan(0); } finally { if (File.Exists(destPath)) { File.Delete(destPath); } } }