Refactor code structure and optimize performance across multiple modules
This commit is contained in:
@@ -11,7 +11,8 @@ namespace StellaOps.Concelier.Models.Tests;
|
||||
|
||||
public sealed class ProvenanceDiagnosticsTests
|
||||
{
|
||||
[Fact]
|
||||
[Trait("Category", TestCategories.Unit)]
|
||||
[Fact]
|
||||
public void RecordMissing_AddsExpectedTagsAndDeduplicates()
|
||||
{
|
||||
ResetState();
|
||||
@@ -44,7 +45,8 @@ public sealed class ProvenanceDiagnosticsTests
|
||||
Assert.Equal(ProvenanceFieldMasks.References, second.Tags["fieldMask"]);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[Trait("Category", TestCategories.Unit)]
|
||||
[Fact]
|
||||
public void ReportResumeWindow_ClearsTrackedEntries_WhenWindowBackfills()
|
||||
{
|
||||
ResetState();
|
||||
@@ -68,7 +70,8 @@ public sealed class ProvenanceDiagnosticsTests
|
||||
}
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[Trait("Category", TestCategories.Unit)]
|
||||
[Fact]
|
||||
public void ReportResumeWindow_RetainsEntries_WhenWindowTooRecent()
|
||||
{
|
||||
ResetState();
|
||||
@@ -86,7 +89,8 @@ public sealed class ProvenanceDiagnosticsTests
|
||||
}
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[Trait("Category", TestCategories.Unit)]
|
||||
[Fact]
|
||||
public void RecordRangePrimitive_EmitsCoverageMetric()
|
||||
{
|
||||
var range = new AffectedVersionRange(
|
||||
@@ -108,6 +112,7 @@ public sealed class ProvenanceDiagnosticsTests
|
||||
var measurements = new List<(string Instrument, long Value, IReadOnlyDictionary<string, object?> Tags)>();
|
||||
using var listener = CreateListener(measurements, "concelier.range.primitives");
|
||||
|
||||
using StellaOps.TestKit;
|
||||
ProvenanceDiagnostics.RecordRangePrimitive("source-D", range);
|
||||
|
||||
listener.Dispose();
|
||||
|
||||
Reference in New Issue
Block a user