Skip to content

Commit

Permalink
Merge pull request #21 from StevanFreeborn/stevanfreeborn/chore/updat…
Browse files Browse the repository at this point in the history
…e-vuln-dep

fix: address vulnerabilities in dependencies
  • Loading branch information
StevanFreeborn authored Nov 19, 2024
2 parents 87f363e + 24bd877 commit 9d99750
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion src/AnthropicClient/AnthropicClient.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@

<ItemGroup>
<PackageReference Include="Microsoft.Bcl.AsyncInterfaces" Version="8.0.0" />
<PackageReference Include="System.Text.Json" Version="8.0.4" />
<PackageReference Include="System.Text.Json" Version="8.0.5" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="All" />
</ItemGroup>

Expand Down
12 changes: 6 additions & 6 deletions tests/AnthropicClient.Tests/AnthropicClient.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,21 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="FluentAssertions" Version="6.12.0" />
<PackageReference Include="FluentAssertions" Version="6.12.2" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="8.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.12.0" />
<PackageReference Include="RichardSzalay.MockHttp" Version="7.0.0" />
<PackageReference Include="System.Linq.Async" Version="6.0.1" />
<PackageReference Include="SystemTextJson.JsonDiffPatch.Xunit" Version="2.0.0" />
<PackageReference Include="xunit" Version="2.5.3" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.3" />
<PackageReference Include="coverlet.collector" Version="6.0.0">
<PackageReference Include="xunit" Version="2.9.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.8.2" />
<PackageReference Include="coverlet.collector" Version="6.0.2">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="coverlet.msbuild" Version="6.0.0">
<PackageReference Include="coverlet.msbuild" Version="6.0.2">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
Expand Down
16 changes: 8 additions & 8 deletions tests/AnthropicClient.Tests/Unit/Models/ToolTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ public class ToolTests : SerializationTest
[InlineData(null)]
[InlineData("")]
[InlineData(" ")]
public void Constructor_WhenGivenInvalidNameValue_ItShouldThrowArgumentException(string name)
public void Constructor_WhenGivenInvalidNameValue_ItShouldThrowArgumentException(string? name)
{
var method = () => true;
var function = new AnthropicFunction(method.Method);
var action = () => new Tool(name, "description", function);
var action = () => new Tool(name!, "description", function);

action.Should().Throw<ArgumentException>();
}
Expand All @@ -21,11 +21,11 @@ public void Constructor_WhenGivenInvalidNameValue_ItShouldThrowArgumentException
[InlineData(null)]
[InlineData("")]
[InlineData(" ")]
public void Constructor_WhenGivenInvalidDescriptionValue_ItShouldThrowArgumentException(string description)
public void Constructor_WhenGivenInvalidDescriptionValue_ItShouldThrowArgumentException(string? description)
{
var method = () => true;
var function = new AnthropicFunction(method.Method);
var action = () => new Tool("name", description, function);
var action = () => new Tool("name", description!, function);

action.Should().Throw<ArgumentException>();
}
Expand Down Expand Up @@ -86,9 +86,9 @@ public void Constructor_WhenCalledAndGivenCacheControl_ItShouldInitializeCacheCo
[InlineData(typeof(TestClass), "")]
[InlineData(typeof(TestClass), " ")]
[InlineData(typeof(TestClass), "MadeUpMethod")]
public void CreateFromStaticMethod_WhenGivenInvalidMethodName_ItShouldThrowArgumentException(Type type, string methodName)
public void CreateFromStaticMethod_WhenGivenInvalidMethodName_ItShouldThrowArgumentException(Type type, string? methodName)
{
var action = () => Tool.CreateFromStaticMethod("name", "description", type, methodName);
var action = () => Tool.CreateFromStaticMethod("name", "description", type, methodName!);

action.Should().Throw<ArgumentException>();
}
Expand Down Expand Up @@ -158,9 +158,9 @@ public void CreateFromStaticMethod_WhenCalledWithCacheControl_ItShouldReturnTool
[InlineData("")]
[InlineData(" ")]
[InlineData("MadeUpMethod")]
public void CreateFromInstanceMethod_WhenGivenInvalidMethodName_ItShouldThrowArgumentException(string methodName)
public void CreateFromInstanceMethod_WhenGivenInvalidMethodName_ItShouldThrowArgumentException(string? methodName)
{
var action = () => Tool.CreateFromInstanceMethod("name", "description", new TestClass(), methodName);
var action = () => Tool.CreateFromInstanceMethod("name", "description", new TestClass(), methodName!);

action.Should().Throw<ArgumentException>();
}
Expand Down

0 comments on commit 9d99750

Please sign in to comment.