Styling: remove a few redundant parens from object initializer expressions. (#548)
* Styling: remove a few redundant parens from object initializer expressions. * Fix build error.
This commit is contained in:
parent
802424ee08
commit
55bda787ae
5 changed files with 108 additions and 108 deletions
|
|
@ -31,7 +31,7 @@ public abstract class MapMcpTests(ITestOutputHelper testOutputHelper) : KestrelI
|
|||
// Default behavior when no options are provided
|
||||
path ??= UseStreamableHttp ? "/" : "/sse";
|
||||
|
||||
await using var transport = new SseClientTransport(transportOptions ?? new SseClientTransportOptions()
|
||||
await using var transport = new SseClientTransport(transportOptions ?? new SseClientTransportOptions
|
||||
{
|
||||
Endpoint = new Uri($"http://localhost{path}"),
|
||||
TransportMode = UseStreamableHttp ? HttpTransportMode.StreamableHttp : HttpTransportMode.Sse,
|
||||
|
|
|
|||
|
|
@ -195,7 +195,7 @@ public partial class SseIntegrationTests(ITestOutputHelper outputHelper) : Kestr
|
|||
app.MapMcp();
|
||||
await app.StartAsync(TestContext.Current.CancellationToken);
|
||||
|
||||
var sseOptions = new SseClientTransportOptions()
|
||||
var sseOptions = new SseClientTransportOptions
|
||||
{
|
||||
Endpoint = new Uri("http://localhost/sse"),
|
||||
Name = "In-memory SSE Client",
|
||||
|
|
@ -222,7 +222,7 @@ public partial class SseIntegrationTests(ITestOutputHelper outputHelper) : Kestr
|
|||
app.MapMcp();
|
||||
await app.StartAsync(TestContext.Current.CancellationToken);
|
||||
|
||||
var sseOptions = new SseClientTransportOptions()
|
||||
var sseOptions = new SseClientTransportOptions
|
||||
{
|
||||
Endpoint = new Uri("http://localhost/sse"),
|
||||
Name = "In-memory SSE Client",
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ public class SseServerIntegrationTestFixture : IAsyncDisposable
|
|||
|
||||
public SseServerIntegrationTestFixture()
|
||||
{
|
||||
var socketsHttpHandler = new SocketsHttpHandler()
|
||||
var socketsHttpHandler = new SocketsHttpHandler
|
||||
{
|
||||
ConnectCallback = (context, token) =>
|
||||
{
|
||||
|
|
|
|||
|
|
@ -85,7 +85,7 @@ public class StreamableHttpClientConformanceTests(ITestOutputHelper outputHelper
|
|||
return Results.Json(new JsonRpcResponse
|
||||
{
|
||||
Id = request.Id,
|
||||
Result = JsonSerializer.SerializeToNode(new CallToolResult()
|
||||
Result = JsonSerializer.SerializeToNode(new CallToolResult
|
||||
{
|
||||
Content = [new TextContentBlock { Text = parameters.Arguments["message"].ToString() }],
|
||||
}, McpJsonUtilities.DefaultOptions),
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ public class KestrelInMemoryTest : LoggedTest
|
|||
Builder.Services.AddSingleton<IConnectionListenerFactory>(_inMemoryTransport);
|
||||
Builder.Services.AddSingleton(XunitLoggerProvider);
|
||||
|
||||
HttpClient = new HttpClient(new SocketsHttpHandler()
|
||||
HttpClient = new HttpClient(new SocketsHttpHandler
|
||||
{
|
||||
ConnectCallback = (context, token) =>
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue