diff options
| author | Bond_009 <bond.009@outlook.com> | 2021-04-04 23:02:28 +0200 |
|---|---|---|
| committer | Bond_009 <bond.009@outlook.com> | 2021-08-30 15:40:52 +0200 |
| commit | 963ab2dab6a8c4dafadae61312b36ed5fbb1f323 (patch) | |
| tree | 0224812fb2f3cce08e36fe2519adc8d105631aed /tests/Jellyfin.MediaEncoding.Tests/EncoderValidatorTests.cs | |
| parent | 32a11c006dfe93d569910b842bc7770d056d9eba (diff) | |
Simplify the way we choose our ffmpeg
* no longer search $PATH
* no longer require a full path
* don't fall back
Diffstat (limited to 'tests/Jellyfin.MediaEncoding.Tests/EncoderValidatorTests.cs')
| -rw-r--r-- | tests/Jellyfin.MediaEncoding.Tests/EncoderValidatorTests.cs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/Jellyfin.MediaEncoding.Tests/EncoderValidatorTests.cs b/tests/Jellyfin.MediaEncoding.Tests/EncoderValidatorTests.cs index 39fd8afda..cc429b442 100644 --- a/tests/Jellyfin.MediaEncoding.Tests/EncoderValidatorTests.cs +++ b/tests/Jellyfin.MediaEncoding.Tests/EncoderValidatorTests.cs @@ -9,12 +9,13 @@ namespace Jellyfin.MediaEncoding.Tests { public class EncoderValidatorTests { + private readonly EncoderValidator _encoderValidator = new EncoderValidator(new NullLogger<EncoderValidatorTests>(), "ffmpeg"); + [Theory] [ClassData(typeof(GetFFmpegVersionTestData))] public void GetFFmpegVersionTest(string versionOutput, Version? version) { - var val = new EncoderValidator(new NullLogger<EncoderValidatorTests>()); - Assert.Equal(version, val.GetFFmpegVersion(versionOutput)); + Assert.Equal(version, _encoderValidator.GetFFmpegVersion(versionOutput)); } [Theory] @@ -28,8 +29,7 @@ namespace Jellyfin.MediaEncoding.Tests [InlineData(EncoderValidatorTestsData.FFmpegGitUnknownOutput, false)] public void ValidateVersionInternalTest(string versionOutput, bool valid) { - var val = new EncoderValidator(new NullLogger<EncoderValidatorTests>()); - Assert.Equal(valid, val.ValidateVersionInternal(versionOutput)); + Assert.Equal(valid, _encoderValidator.ValidateVersionInternal(versionOutput)); } private class GetFFmpegVersionTestData : IEnumerable<object?[]> |
