diff --git a/VideoDownloader.Server/ServerHost.cs b/VideoDownloader.Server/ServerHost.cs
index 8054ed1..92c4a05 100644
--- a/VideoDownloader.Server/ServerHost.cs
+++ b/VideoDownloader.Server/ServerHost.cs
@@ -98,7 +98,7 @@ public sealed class ServerHost : IAsyncDisposable
// ── 라이브러리 / 스트리밍 ──
// ── 라이브러리 + 썸네일/해상도(M2) ──
var thumbnailer = options.Thumbnailer ?? ServerOptionsDefaults.DefaultThumbnailer();
- var ffmpeg = VideoDownloader.Core.Platform.DesktopMediaMuxer.Default.ResolveFfmpeg(new VideoDownloader.Core.Config.AppConfig());
+ var ffmpeg = options.FfmpegPath ?? VideoDownloader.Core.Platform.DesktopMediaMuxer.Default.ResolveFfmpeg(new VideoDownloader.Core.Config.AppConfig());
app.MapGet("/api/library", async (HttpContext ctx) =>
{
var items = MediaLibrary.List(options.LibraryFolder);
diff --git a/VideoDownloader.Server/ServerModels.cs b/VideoDownloader.Server/ServerModels.cs
index 2ce8dc7..bfc2534 100644
--- a/VideoDownloader.Server/ServerModels.cs
+++ b/VideoDownloader.Server/ServerModels.cs
@@ -24,6 +24,8 @@ public sealed class ServerOptions
public string DeviceName { get; init; } = Environment.MachineName;
/// 썸네일/해상도 생성기(기본: DesktopProcessRunner 기반 ffmpeg). 테스트 주입 가능.
public Thumbnailer? Thumbnailer { get; init; }
+ /// ffmpeg 경로 오버라이드(기본: 설정→PATH 탐색). 호스트 ffmpeg 없는 환경 테스트용.
+ public string? FfmpegPath { get; init; }
}
/// 기본 썸네일러 팩토리.
diff --git a/VideoDownloader.Tests/Server/RemoteServerE2ETests.cs b/VideoDownloader.Tests/Server/RemoteServerE2ETests.cs
index 19b8cf0..cee6393 100644
--- a/VideoDownloader.Tests/Server/RemoteServerE2ETests.cs
+++ b/VideoDownloader.Tests/Server/RemoteServerE2ETests.cs
@@ -167,7 +167,8 @@ public class RemoteServerE2ETests : IDisposable
{
Behavior = (spec, _, _) =>
{
- File.WriteAllBytes(spec.Args[^1], new byte[] { 0xFF, 0xD8, 0xFF, 0xE0, 0x01 });
+ if (spec.Args[^1].EndsWith(".jpg", StringComparison.OrdinalIgnoreCase)) // 해상도 프로브(미디어 경로)는 미오염
+ File.WriteAllBytes(spec.Args[^1], new byte[] { 0xFF, 0xD8, 0xFF, 0xE0, 0x01 });
return Task.FromResult(new VideoDownloader.Core.Platform.ProcessResult(0, "", ""));
},
};
@@ -177,6 +178,7 @@ public class RemoteServerE2ETests : IDisposable
Port = 0, Token = "thumb-token", LibraryFolder = _libDir,
Queue = new FakeQueue(),
Thumbnailer = new Thumbnailer(fake),
+ FfmpegPath = "ffmpeg", // 호스트 ffmpeg 무관(가짜 러너가 프로세스를 대신함)
});
using var http = new HttpClient { BaseAddress = new Uri($"http://127.0.0.1:{server.Port}") };