From 01057278f59a114c14191ec0023b63227d53ca06 Mon Sep 17 00:00:00 2001
From: filzrev <103790468+filzrev@users.noreply.github.com>
Date: Fri, 22 Aug 2025 04:02:13 +0900
Subject: [PATCH] Modify GetOutputDevice/GetClientInfo get service API
---
.../Services/ServiceProviderExtensions.cs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/Platform/Microsoft.Testing.Platform/Services/ServiceProviderExtensions.cs b/src/Platform/Microsoft.Testing.Platform/Services/ServiceProviderExtensions.cs
index 1c74ea6a2d..37dfe7833d 100644
--- a/src/Platform/Microsoft.Testing.Platform/Services/ServiceProviderExtensions.cs
+++ b/src/Platform/Microsoft.Testing.Platform/Services/ServiceProviderExtensions.cs
@@ -93,7 +93,7 @@ public static ILoggerFactory GetLoggerFactory(this IServiceProvider serviceProvi
/// The service provider.
/// The output device.
public static IOutputDevice GetOutputDevice(this IServiceProvider serviceProvider)
- => serviceProvider.GetRequiredServiceInternal();
+ => serviceProvider.GetRequiredService();
///
/// Gets the IClientInfo from the .
@@ -102,7 +102,7 @@ public static IOutputDevice GetOutputDevice(this IServiceProvider serviceProvide
/// The IClientInfo object.
[Experimental("TPEXP", UrlFormat = "https://aka.ms/testingplatform/diagnostics#{0}")]
public static IClientInfo GetClientInfo(this IServiceProvider serviceProvider)
- => serviceProvider.GetRequiredServiceInternal();
+ => serviceProvider.GetRequiredService();
// Internals extensions
internal static TService GetRequiredServiceInternal(this IServiceProvider provider)