From 73aabdabda6b7c43844316fa859dc54542b18e03 Mon Sep 17 00:00:00 2001 From: Jason Dove <1695733+jasongdove@users.noreply.github.com> Date: Sat, 29 Nov 2025 10:34:32 -0600 Subject: [PATCH] fix transcoding tests (#2675) [no ci] --- ErsatzTV.Scanner.Tests/Core/FFmpeg/TranscodingTests.cs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ErsatzTV.Scanner.Tests/Core/FFmpeg/TranscodingTests.cs b/ErsatzTV.Scanner.Tests/Core/FFmpeg/TranscodingTests.cs index a3a0065e9..fe4661657 100644 --- a/ErsatzTV.Scanner.Tests/Core/FFmpeg/TranscodingTests.cs +++ b/ErsatzTV.Scanner.Tests/Core/FFmpeg/TranscodingTests.cs @@ -242,7 +242,7 @@ public class TranscodingTests var fileSystem = new MockFileSystem(); var tempFilePool = new TempFilePool(); - ImageCache mockImageCache = Substitute.For(localFileSystem, tempFilePool); + ImageCache mockImageCache = Substitute.For(fileSystem, localFileSystem, tempFilePool); // always return the static watermark resource mockImageCache.GetPathForImage( @@ -682,7 +682,7 @@ public class TranscodingTests var tempFilePool = new TempFilePool(); - ImageCache mockImageCache = Substitute.For(localFileSystem, tempFilePool); + ImageCache mockImageCache = Substitute.For(fileSystem, localFileSystem, tempFilePool); // always return the static watermark resource mockImageCache.GetPathForImage( @@ -702,13 +702,15 @@ public class TranscodingTests watermarks.AddRange(watermarkSelector.GetWatermarkOptions(channel, wm, Option.None)); } + var mediaItem = new OtherVideo { MediaVersions = [v] }; + PlayoutItemResult playoutItemResult = await service.ForPlayoutItem( ExecutableName("ffmpeg"), ExecutableName("ffprobe"), true, channel, - new MediaItemVideoVersion(null, v), - new MediaItemAudioVersion(null, v), + new MediaItemVideoVersion(mediaItem, v), + new MediaItemAudioVersion(mediaItem, v), file, file, _ => subtitles.AsTask(),