docs re-org, audit fixes, build fixes
This commit is contained in:
@@ -44,7 +44,7 @@ public sealed class AdvisoryClient : IAdvisoryClient
|
||||
|
||||
var normalized = cveId.Trim().ToUpperInvariant();
|
||||
var cacheKey = $"advisory:cve:{normalized}";
|
||||
if (_cache.TryGetValue(cacheKey, out AdvisorySymbolMapping cached))
|
||||
if (_cache.TryGetValue(cacheKey, out AdvisorySymbolMapping? cached) && cached is not null)
|
||||
{
|
||||
return cached;
|
||||
}
|
||||
|
||||
@@ -249,7 +249,7 @@ internal static class PythonDistributionLoader
|
||||
return false;
|
||||
}
|
||||
|
||||
private static void AddFileEvidence(LanguageAnalyzerContext context, string path, string source, ICollection<LanguageComponentEvidence> evidence)
|
||||
private static void AddFileEvidence(LanguageAnalyzerContext context, string? path, string source, ICollection<LanguageComponentEvidence> evidence)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(path) || !File.Exists(path))
|
||||
{
|
||||
|
||||
@@ -14,7 +14,7 @@ public sealed class RiskScoreTests
|
||||
[Fact]
|
||||
public void RiskScore_Zero_ReturnsNegligibleLevel()
|
||||
{
|
||||
var score = RiskScore.Zero;
|
||||
var score = RiskScore.Zero();
|
||||
|
||||
Assert.Equal(0.0f, score.OverallScore);
|
||||
Assert.Equal(RiskCategory.Unknown, score.Category);
|
||||
|
||||
@@ -34,7 +34,7 @@ public sealed class SurfaceValidatorRunnerTests
|
||||
Array.Empty<string>(),
|
||||
new SurfaceSecretsConfiguration("kubernetes", "", null, null, null, false),
|
||||
string.Empty,
|
||||
new SurfaceTlsConfiguration(null, null, null));
|
||||
new SurfaceTlsConfiguration(null, null, null)) { CreatedAtUtc = DateTimeOffset.UtcNow };
|
||||
|
||||
var context = SurfaceValidationContext.Create(services, "TestComponent", environment);
|
||||
|
||||
@@ -60,7 +60,7 @@ public sealed class SurfaceValidatorRunnerTests
|
||||
Array.Empty<string>(),
|
||||
new SurfaceSecretsConfiguration("kubernetes", "tenant-a", null, "stellaops", null, false),
|
||||
"tenant-a",
|
||||
new SurfaceTlsConfiguration(null, null, null));
|
||||
new SurfaceTlsConfiguration(null, null, null)) { CreatedAtUtc = DateTimeOffset.UtcNow };
|
||||
|
||||
var services = CreateServices();
|
||||
var runner = services.GetRequiredService<ISurfaceValidatorRunner>();
|
||||
@@ -86,7 +86,7 @@ public sealed class SurfaceValidatorRunnerTests
|
||||
Array.Empty<string>(),
|
||||
new SurfaceSecretsConfiguration("inline", "tenant-a", Root: null, Namespace: null, FallbackProvider: null, AllowInline: false),
|
||||
"tenant-a",
|
||||
new SurfaceTlsConfiguration(null, null, null));
|
||||
new SurfaceTlsConfiguration(null, null, null)) { CreatedAtUtc = DateTimeOffset.UtcNow };
|
||||
|
||||
var services = CreateServices();
|
||||
var runner = services.GetRequiredService<ISurfaceValidatorRunner>();
|
||||
@@ -118,7 +118,7 @@ public sealed class SurfaceValidatorRunnerTests
|
||||
Array.Empty<string>(),
|
||||
new SurfaceSecretsConfiguration("file", "tenant-a", Root: missingRoot, Namespace: null, FallbackProvider: null, AllowInline: false),
|
||||
"tenant-a",
|
||||
new SurfaceTlsConfiguration(null, null, null));
|
||||
new SurfaceTlsConfiguration(null, null, null)) { CreatedAtUtc = DateTimeOffset.UtcNow };
|
||||
|
||||
var services = CreateServices();
|
||||
var runner = services.GetRequiredService<ISurfaceValidatorRunner>();
|
||||
|
||||
Reference in New Issue
Block a user