Skip to content

Commit 769a15b

Browse files
committed
refactor(spicedb): remove unused gRPC channel methods and dependencies
1 parent dda1cf8 commit 769a15b

File tree

4 files changed

+0
-29
lines changed

4 files changed

+0
-29
lines changed

src/Testcontainers.SpiceDB/SpiceDBContainer.cs

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -25,19 +25,4 @@ public string GetGrpcConnectionString()
2525
var endpoint = new UriBuilder(scheme, Hostname, GetMappedPublicPort(SpiceDBBuilder.SpiceDBPort));
2626
return endpoint.ToString();
2727
}
28-
29-
public GrpcChannel GetGrpcChannel()
30-
{
31-
return GrpcChannel.ForAddress(GetGrpcConnectionString());
32-
}
33-
34-
public async Task<string> GetStateAsync(CancellationToken cancellationToken = default)
35-
{
36-
var healthClient = new Health.HealthClient(GetGrpcChannel());
37-
var response = await healthClient.CheckAsync(new HealthCheckRequest
38-
{
39-
Service = string.Empty,
40-
}, null, null, cancellationToken);
41-
return response.Status.ToString();
42-
}
4328
}

src/Testcontainers.SpiceDB/Testcontainers.SpiceDB.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77

88
<ItemGroup>
99
<PackageReference Include="Grpc.HealthCheck" />
10-
<PackageReference Include="Grpc.Net.Client" />
1110
<PackageReference Include="JetBrains.Annotations" VersionOverride="2023.3.0" PrivateAssets="All"/>
1211
</ItemGroup>
1312

src/Testcontainers.SpiceDB/Usings.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,4 @@
66
global using DotNet.Testcontainers.Containers;
77
global using JetBrains.Annotations;
88
global using Grpc.Health.V1;
9-
global using Grpc.Net.Client;
109
global using Grpc.Core;

tests/Testcontainers.SpiceDB.Tests/SpiceDBContainerTest.cs

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -17,18 +17,6 @@ public ValueTask DisposeAsync()
1717
return _spicedbContainer.DisposeAsync();
1818
}
1919

20-
[Fact]
21-
[Trait(nameof(DockerCli.DockerPlatform), nameof(DockerCli.DockerPlatform.Linux))]
22-
public async Task ContainerStartsSuccessfully()
23-
{
24-
// Given
25-
var containerState = await _spicedbContainer.GetStateAsync(TestContext.Current.CancellationToken)
26-
.ConfigureAwait(false);
27-
28-
// When & Then
29-
Assert.Equal(containerState, "started");
30-
}
31-
3220
[Fact]
3321
[Trait(nameof(DockerCli.DockerPlatform), nameof(DockerCli.DockerPlatform.Linux))]
3422
public void ExpectedPortIsMapped()

0 commit comments

Comments
 (0)