csharp-sdk/tests/ModelContextProtocol.Tests
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Stephen Toub 848c9df433
Allow notification handlers post-creation temporary registration (#223)
- We still allow notification handlers to be configured pre-creation, eliminating any race conditions that may result from missed notifications. But now we also allow for post-creation notification handler registration.
- Handlers may now also be removed. This permits temporary registrations that may be created in a scoped manner.
- Registration handling is thread-safe.
- Handlers are now cancelable.
- Exceptions from notification handlers trigger all normal exception handling in the dispatch pipeline.

This also:
- Adds a WithStreamServerTransport as a counterpart to WithStdioServerTransport. The latter was used in several tests in a hacky way, and that's now simplified via the former's existence.
2025-04-06 21:17:00 -04:00
..
Client Allow notification handlers post-creation temporary registration (#223) 2025-04-06 21:17:00 -04:00
Configuration Allow notification handlers post-creation temporary registration (#223) 2025-04-06 21:17:00 -04:00
Protocol Allow notification handlers post-creation temporary registration (#223) 2025-04-06 21:17:00 -04:00
Server Allow notification handlers post-creation temporary registration (#223) 2025-04-06 21:17:00 -04:00
Transport Move notification handler registrations to capabilities (#207) 2025-04-04 13:11:07 -04:00
Utils Reduce dependencies to 8.x versions of packages (#195) 2025-04-03 14:01:46 -04:00
ClientIntegrationTestFixture.cs Move notification handler registrations to capabilities (#207) 2025-04-04 13:11:07 -04:00
ClientIntegrationTests.cs Allow notification handlers post-creation temporary registration (#223) 2025-04-06 21:17:00 -04:00
DiagnosticTests.cs Move notification handler registrations to capabilities (#207) 2025-04-04 13:11:07 -04:00
EverythingSseServerFixture.cs Refactor transports to help enable graceful shutdown (#142) 2025-03-30 17:10:14 -07:00
GlobalUsings.cs Rename project and namespaces 2025-03-19 15:02:38 +02:00
McpJsonUtilitiesTests.cs Hardcode the source generator in one remaining location and simplify McpJsonUtilities. (#204) 2025-04-03 13:42:42 -04:00
ModelContextProtocol.Tests.csproj Move notification handler registrations to capabilities (#207) 2025-04-04 13:11:07 -04:00
SseIntegrationTests.cs Allow notification handlers post-creation temporary registration (#223) 2025-04-06 21:17:00 -04:00
SseServerIntegrationTestFixture.cs Move notification handler registrations to capabilities (#207) 2025-04-04 13:11:07 -04:00
SseServerIntegrationTests.cs Move notification handler registrations to capabilities (#207) 2025-04-04 13:11:07 -04:00
TestAttributes.cs Add initial Activity / Metric support (#183) 2025-04-02 11:09:05 -04:00