This commit is contained in:
StellaOps Bot
2025-12-26 21:43:56 +02:00
354 changed files with 354 additions and 0 deletions

View File

@@ -465,6 +465,7 @@ internal class LedgerProjectionReducer
private static string ComputeCycleHash(IList<LedgerEvent> events)
{
using var sha256 = SHA256.Create();
using StellaOps.TestKit;
var combined = new StringBuilder();
foreach (var evt in events.OrderBy(e => e.Sequence))

View File

@@ -272,6 +272,7 @@ public sealed class FindingsLedgerWebServiceContractTests : IDisposable
var content = await response.Content.ReadAsStringAsync();
using var doc = JsonDocument.Parse(content);
using StellaOps.TestKit;
// Navigate to FindingSummary schema
if (doc.RootElement.TryGetProperty("components", out var components) &&
components.TryGetProperty("schemas", out var schemas) &&

View File

@@ -23,6 +23,7 @@ public class HarnessRunnerTests
var json = await File.ReadAllTextAsync(tempReport);
using var doc = JsonDocument.Parse(json);
using StellaOps.TestKit;
doc.RootElement.GetProperty("eventsWritten").GetInt64().Should().BeGreaterThan(0);
doc.RootElement.GetProperty("status").GetString().Should().Be("pass");
doc.RootElement.GetProperty("tenant").GetString().Should().Be("tenant-test");

View File

@@ -195,6 +195,7 @@ public class LedgerMetricsTests
public void VersionInfoGauge_EmitsConstantOne()
{
using var listener = CreateListener();
using StellaOps.TestKit;
var measurements = new List<(long Value, KeyValuePair<string, object?>[] Tags)>();
listener.SetMeasurementEventCallback<long>((instrument, measurement, tags, state) =>

View File

@@ -90,6 +90,7 @@ public sealed class PolicyEngineEvaluationServiceTests
var factory = new TestHttpClientFactory(handler);
var options = CreateOptions(baseAddress: null);
using var cache = new PolicyEvaluationCache(options.PolicyEngine, NullLogger<PolicyEvaluationCache>.Instance);
using StellaOps.TestKit;
var inline = new InlinePolicyEvaluationService(NullLogger<InlinePolicyEvaluationService>.Instance);
var service = new PolicyEngineEvaluationService(factory, inline, cache, Microsoft.Extensions.Options.Options.Create(options), NullLogger<PolicyEngineEvaluationService>.Instance);