stabilize tests

This commit is contained in:
master
2026-02-01 21:37:40 +02:00
parent 55744f6a39
commit 5d5e80b2e4
6435 changed files with 33984 additions and 13802 deletions

View File

@@ -1,5 +1,6 @@
using System;
using StellaOps.Scanner.Analyzers.Lang.Plugin;
using System;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet;

View File

@@ -1,6 +1,7 @@
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Bundling;
using System.Collections.Immutable;
using System.Globalization;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Bundling;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal;

View File

@@ -1,3 +1,4 @@
using System.Collections.Immutable;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Bundling;

View File

@@ -1,3 +1,4 @@
using System.Collections.Immutable;
using System.Reflection;
using System.Reflection.Metadata;

View File

@@ -1,3 +1,4 @@
using System.Collections.Immutable;
using System.Security.Cryptography;
using System.Text;

View File

@@ -1,6 +1,7 @@
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
using System.Text.Json;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Config;

View File

@@ -1,5 +1,6 @@
using System.Collections.Immutable;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Conflicts;

View File

@@ -1,6 +1,7 @@
using System.Collections.Immutable;
using StellaOps.Scanner.Core.Contracts;
using StellaOps.Scanner.Emit.Cbom;
using System.Collections.Immutable;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Crypto;

View File

@@ -1,11 +1,12 @@
using System.Collections.Immutable;
using System.Security.Cryptography;
using System.Text;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Discovery;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Inheritance;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.LockFiles;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Parsing;
using System.Collections.Immutable;
using System.Security.Cryptography;
using System.Text;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal;
@@ -132,7 +133,9 @@ internal sealed class DotNetDeclaredDependencyCollector
foreach (var packageRef in projectMetadata.PackageReferences)
{
var resolvedVersion = ResolveVersion(packageRef, cpmLookup, propsLookup, projectMetadata);
var versionSource = DetermineVersionSource(packageRef, resolvedVersion, projectMetadata.ManagePackageVersionsCentrally);
// CPM is effective when explicitly set in the project or inherited from Directory.Packages.props
var effectiveCpmEnabled = projectMetadata.ManagePackageVersionsCentrally || !cpmLookup.IsEmpty;
var versionSource = DetermineVersionSource(packageRef, resolvedVersion, effectiveCpmEnabled);
var declaration = new DotNetDependencyDeclaration
{
@@ -253,8 +256,8 @@ internal sealed class DotNetDeclaredDependencyCollector
return packageRef.Version;
}
// If version is empty and CPM is enabled, look up in CPM
if (string.IsNullOrEmpty(packageRef.Version) && projectMetadata.ManagePackageVersionsCentrally)
// If version is empty and CPM is enabled (either in csproj or inherited from Directory.Packages.props), look up in CPM
if (string.IsNullOrEmpty(packageRef.Version) && (projectMetadata.ManagePackageVersionsCentrally || !cpmLookup.IsEmpty))
{
if (cpmLookup.TryGetValue(packageRef.PackageId, out var cpmVersion))
{

View File

@@ -1,3 +1,4 @@
using System.Diagnostics.CodeAnalysis;
using System.Text.Json;

View File

@@ -1,8 +1,9 @@
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Bundling;
using System.Reflection.Metadata;
using System.Reflection.PortableExecutable;
using System.Security.Cryptography;
using System.Text.Json;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Bundling;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal;

View File

@@ -1,3 +1,4 @@
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Diagnostics;

View File

@@ -1,3 +1,4 @@
using System.Linq;
using System.Text.Json;

View File

@@ -1,3 +1,4 @@
using System.Text.Json;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal;

View File

@@ -1,6 +1,7 @@
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
using System.Xml.Linq;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Inheritance;

View File

@@ -1,6 +1,7 @@
using System.Collections.Immutable;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Parsing;
using System.Collections.Immutable;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Inheritance;

View File

@@ -1,7 +1,8 @@
using System.Collections.Immutable;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Parsing;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.PropertyResolution;
using System.Collections.Immutable;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Inheritance;

View File

@@ -5,12 +5,13 @@
// Description: Enhanced .NET license detection returning LicenseDetectionResult
// -----------------------------------------------------------------------------
using StellaOps.Scanner.Analyzers.Lang.Core.Licensing;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
using System.Text;
using System.Text.RegularExpressions;
using System.Xml.Linq;
using StellaOps.Scanner.Analyzers.Lang.Core.Licensing;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Licensing;

View File

@@ -1,5 +1,6 @@
using System.Collections.Immutable;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.LockFiles;

View File

@@ -1,6 +1,7 @@
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
using System.Text.Json;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.LockFiles;

View File

@@ -1,6 +1,7 @@
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
using System.Xml.Linq;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Parsing;

View File

@@ -1,6 +1,7 @@
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
using System.Xml.Linq;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.Parsing;

View File

@@ -1,6 +1,7 @@
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
using System.Collections.Immutable;
using System.Text.RegularExpressions;
using StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.BuildMetadata;
namespace StellaOps.Scanner.Analyzers.Lang.DotNet.Internal.PropertyResolution;

View File

@@ -8,3 +8,4 @@ Source of truth: `docs/implplan/SPRINT_20260112_003_BE_csproj_audit_pending_appl
| AUDIT-HOTLIST-SCANNER-LANG-DOTNET-0001 | DONE | Applied hotlist fixes and tests. |
| AUDIT-0644-A | DONE | Audit tracker updated for DotNet analyzer apply. |
| AUDIT-0698-A | DONE | Test project apply completed (warnings, deterministic fixtures). |
| REMED-06 | DONE | SOLID review notes captured for SPRINT_20260130_002. |