Add explicit [Experimental] protected constructors to McpClient and McpServer (#1363)
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: stephentoub <2642209+stephentoub@users.noreply.github.com> Co-authored-by: jeffhandley <1031940+jeffhandley@users.noreply.github.com> Co-authored-by: Jeff Handley <jeffhandley@users.noreply.github.com>
This commit is contained in:
parent
9b2aaedc9a
commit
124b43b5c1
1 changed files with 44 additions and 2 deletions
|
|
@ -943,7 +943,9 @@ public class McpServerTests : LoggedTest
|
|||
await tcs.Task.WaitAsync(TestConstants.DefaultTimeout, cancellationToken);
|
||||
}
|
||||
|
||||
#pragma warning disable MCPEXP002
|
||||
private sealed class TestServerForIChatClient(bool supportsSampling) : McpServer
|
||||
#pragma warning restore MCPEXP002
|
||||
{
|
||||
public override ClientCapabilities? ClientCapabilities =>
|
||||
supportsSampling ? new ClientCapabilities { Sampling = new SamplingCapability() } :
|
||||
|
|
|
|||
Loading…
Reference in a new issue