fix missing aot model SourceGenerationContext (#1636)

* Add VersionTestAsync to validate Kubernetes client version retrieval

* Add SourceGenerationContextGenerator and update registration in KubernetesClientSourceGenerator
This commit is contained in:
Boshi Lian
2025-06-02 19:08:37 -07:00
committed by GitHub
parent f1125e9435
commit 8d0547bcff
5 changed files with 50 additions and 12 deletions

View File

@@ -370,6 +370,15 @@ namespace k8s.E2E
}
}
[MinikubeFact]
public async Task VersionTestAsync()
{
using var client = CreateClient();
var version = await client.Version.GetCodeAsync().ConfigureAwait(false);
Assert.NotNull(version);
}
public static IKubernetes CreateClient()
{
return new Kubernetes(KubernetesClientConfiguration.BuildDefaultConfig());