Update content according to latest spec (#513)

* Update content according to latest spec

* Add Title to a bunch of types

* Add _meta to lots of types

* Address feedback, more cleanup, fix NAOT test failure
This commit is contained in:
Stephen Toub 2025-06-16 19:39:41 -04:00 • committed by GitHub
commit 2bcff315f8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -17,7 +17,7 @@ public partial class McpClientResourceTemplateTests : ClientServerTestBase
mcpServerBuilder.WithReadResourceHandler((request, cancellationToken) =>
new ValueTask<ReadResourceResult>(new ReadResourceResult()
{
Contents = [new TextResourceContents() { Text = request.Params?.Uri ?? string.Empty }]
Contents = [new TextResourceContents { Text = request.Params?.Uri ?? string.Empty }]
}));
}
@ -95,10 +95,10 @@ public partial class McpClientResourceTemplateTests : ClientServerTestBase
public int Level { get; set; } = 4;
[JsonPropertyName("variables")]
public Dictionary<string, JsonElement> Variables { get; set; } = [];
public IDictionary<string, JsonElement> Variables { get; set; } = new Dictionary<string, JsonElement>();
[JsonPropertyName("testcases")]
public List<List<JsonElement>> TestCases { get; set; } = [];
public IList<List<JsonElement>> TestCases { get; set; } = [];
}
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.SnakeCaseLower)]