diff --git a/Directory.Packages.props b/Directory.Packages.props index a4f3d7d..eb40604 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -44,7 +44,7 @@ - + diff --git a/tests/MCPsharp.Tests/Services/SearchServiceTests.cs b/tests/MCPsharp.Tests/Services/SearchServiceTests.cs index 25d3c25..547f3a0 100644 --- a/tests/MCPsharp.Tests/Services/SearchServiceTests.cs +++ b/tests/MCPsharp.Tests/Services/SearchServiceTests.cs @@ -398,8 +398,8 @@ public async Task SearchTextAsync_CancellationToken_CancelsOperation() Pattern = "line" }; - // Act & Assert - Assert.ThrowsAsync( + // Act & Assert - use CatchAsync to accept both OperationCanceledException and TaskCanceledException + Assert.CatchAsync( async () => await _searchService.SearchTextAsync(request, cts.Token)); }