Refactor code structure and optimize performance across multiple modules

This commit is contained in:
StellaOps Bot
2025-12-26 20:03:22 +02:00
parent c786faae84
commit f10d83c444
1385 changed files with 69732 additions and 10280 deletions

View File

@@ -13,7 +13,8 @@ namespace StellaOps.Scanner.Diff.Tests;
public sealed class ComponentDifferTests
{
[Fact]
[Trait("Category", TestCategories.Unit)]
[Fact]
public void Compute_CapturesAddedRemovedAndChangedComponents()
{
var oldFragments = new[]
@@ -173,7 +174,8 @@ public sealed class ComponentDifferTests
Assert.False(removedJson.TryGetProperty("introducingLayer", out _));
}
[Fact]
[Trait("Category", TestCategories.Unit)]
[Fact]
public void Compute_UsageView_FiltersComponents()
{
var oldFragments = new[]
@@ -218,7 +220,8 @@ public sealed class ComponentDifferTests
Assert.False(parsed.RootElement.TryGetProperty("newImageDigest", out _));
}
[Fact]
[Trait("Category", TestCategories.Unit)]
[Fact]
public void Compute_MetadataChange_WhenEvidenceDiffers()
{
var oldFragments = new[]
@@ -277,7 +280,8 @@ public sealed class ComponentDifferTests
Assert.Equal(1, change.OldComponent!.Evidence.Length);
}
[Fact]
[Trait("Category", TestCategories.Unit)]
[Fact]
public void Compute_MetadataChange_WhenBuildIdDiffers()
{
var oldFragments = new[]
@@ -333,6 +337,7 @@ public sealed class ComponentDifferTests
var json = DiffJsonSerializer.Serialize(document);
using var parsed = JsonDocument.Parse(json);
using StellaOps.TestKit;
var changeJson = parsed.RootElement
.GetProperty("layers")[0]
.GetProperty("changes")[0];