Fix TestingGitHubService. Needs an actual HttpMessageHandler here

This commit is contained in:
Jordan Dominion
2025-02-16 20:32:33 -05:00
parent 963f4087a5
commit 8fab9985b2
@@ -16,6 +16,7 @@ using Tgstation.Server.Host.Configuration;
using Tgstation.Server.Host.Extensions;
using Tgstation.Server.Host.Security;
using Tgstation.Server.Host.System;
using Tgstation.Server.Host.Tests;
using Tgstation.Server.Host.Utils.GitHub;
namespace Tgstation.Server.Tests.Live
@@ -39,7 +40,7 @@ namespace Tgstation.Server.Tests.Live
GitHubAccessToken = Environment.GetEnvironmentVariable("TGS_TEST_GITHUB_TOKEN")
});
var gitHubClientFactory = new GitHubClientFactory(new AssemblyInformationProvider(), Mock.Of<IHttpMessageHandlerFactory>(), Mock.Of<ILogger<GitHubClientFactory>>(), mockOptions.Object);
var gitHubClientFactory = new GitHubClientFactory(new AssemblyInformationProvider(), new BasicHttpMessageHandlerFactory(), Mock.Of<ILogger<GitHubClientFactory>>(), mockOptions.Object);
RealClient = gitHubClientFactory.CreateClient(CancellationToken.None).GetAwaiter().GetResult();
}