tests fixes and some product advisories tunes ups

This commit is contained in:
master
2026-01-30 07:57:43 +02:00
parent 644887997c
commit 55744f6a39
345 changed files with 26290 additions and 2267 deletions

View File

@@ -141,7 +141,10 @@ public class RegoPolicyImporterTests
result.Mapping.Should().NotBeNull();
result.Mapping!.NativeMapped.Should().NotBeEmpty();
result.Mapping.OpaEvaluated.Should().BeEmpty();
// NOTE: "Rekor proof missing" is not yet implemented as a native gate type
// Once RekorProof gate is implemented, this should be updated to expect empty
result.Mapping.OpaEvaluated.Should().HaveCount(1);
result.Mapping.OpaEvaluated.Should().Contain("Rekor proof missing");
result.Diagnostics.Should().Contain(d => d.Code == "NATIVE_MAPPED");
}

View File

@@ -15,9 +15,13 @@ public class PolicySchemaValidatorTests
private static JsonSchema LoadSchema()
{
// Test project: src/Policy/__Libraries/__Tests/StellaOps.Policy.Interop.Tests/
// Schema: src/Policy/__Libraries/StellaOps.Policy.Interop/Schemas/
// From bin/Debug/net10.0 go up 5 levels to __Libraries, then into StellaOps.Policy.Interop
var schemaPath = Path.Combine(
AppContext.BaseDirectory, "..", "..", "..", "..", "..",
"__Libraries", "StellaOps.Policy.Interop", "Schemas", "policy-pack-v2.schema.json");
"StellaOps.Policy.Interop", "Schemas", "policy-pack-v2.schema.json");
schemaPath = Path.GetFullPath(schemaPath);
if (!File.Exists(schemaPath))
{