2023-09-06 20:07:08 +00:00
|
|
|
|
using FFMpegCore.Extensions.Downloader;
|
2023-04-12 04:42:51 +00:00
|
|
|
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
2023-04-12 03:55:30 +00:00
|
|
|
|
|
|
|
|
|
namespace FFMpegCore.Test;
|
|
|
|
|
|
2023-04-12 04:42:51 +00:00
|
|
|
|
[TestClass]
|
2023-04-12 03:55:30 +00:00
|
|
|
|
public class DownloaderTests
|
|
|
|
|
{
|
2023-04-12 04:42:51 +00:00
|
|
|
|
[TestMethod]
|
2023-09-06 07:25:51 +00:00
|
|
|
|
public void GetAllLatestSuiteTest()
|
2023-04-12 04:42:51 +00:00
|
|
|
|
{
|
2023-10-10 21:59:11 +00:00
|
|
|
|
var binaries = FFMpegDownloader.DownloadFFMpegSuite(binaries: FFMpegDownloader.FFMpegBinaries.FFMpeg).Result;
|
|
|
|
|
Assert.IsTrue(binaries.Count == 1); // many platforms have only ffmpeg and ffprobe
|
2023-04-12 04:42:51 +00:00
|
|
|
|
}
|
2023-09-06 07:25:51 +00:00
|
|
|
|
|
2023-04-12 04:42:51 +00:00
|
|
|
|
[TestMethod]
|
2023-09-06 07:25:51 +00:00
|
|
|
|
public void GetSpecificVersionTest()
|
2023-04-12 04:42:51 +00:00
|
|
|
|
{
|
2023-10-10 21:59:11 +00:00
|
|
|
|
var binaries = FFMpegDownloader.DownloadFFMpegSuite(FFMpegDownloader.FFMpegVersions.V4_0, binaries: FFMpegDownloader.FFMpegBinaries.FFMpeg).Result;
|
|
|
|
|
Assert.IsTrue(binaries.Count == 1);
|
2023-04-12 03:55:30 +00:00
|
|
|
|
}
|
|
|
|
|
}
|