audit remarks work
This commit is contained in:
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -548,12 +548,20 @@ public sealed class OsvGhsaParityRegressionTests
|
||||
}
|
||||
|
||||
private static string ResolveFixturePath(string filename)
|
||||
=> Path.Combine(ProjectFixtureDirectory, filename);
|
||||
{
|
||||
if (IsGhsaFixture(filename))
|
||||
{
|
||||
return Path.Combine(GhsaFixtureDirectory, filename);
|
||||
}
|
||||
|
||||
return Path.Combine(ProjectFixtureDirectory, filename);
|
||||
}
|
||||
|
||||
private static string NormalizeRecordedAt(string input)
|
||||
=> RecordedAtRegex.Replace(input, "\"recordedAt\": \"#normalized#\"");
|
||||
|
||||
private static string ProjectFixtureDirectory { get; } = Path.GetFullPath(Path.Combine(AppContext.BaseDirectory, "..", "..", "..", "Fixtures"));
|
||||
private static string GhsaFixtureDirectory { get; } = Path.GetFullPath(Path.Combine(ProjectFixtureDirectory, "..", "..", "StellaOps.Concelier.Connector.Ghsa.Tests", "Fixtures"));
|
||||
|
||||
private static string RebuildSentinelPath => Path.Combine(ProjectFixtureDirectory, ".rebuild");
|
||||
|
||||
@@ -568,6 +576,10 @@ public sealed class OsvGhsaParityRegressionTests
|
||||
private static string? NullIfWhitespace(string? value)
|
||||
=> string.IsNullOrWhiteSpace(value) ? null : value.Trim();
|
||||
|
||||
private static bool IsGhsaFixture(string filename)
|
||||
=> filename.Contains("raw-ghsa", StringComparison.OrdinalIgnoreCase)
|
||||
|| filename.Contains(".ghsa.", StringComparison.OrdinalIgnoreCase);
|
||||
|
||||
private sealed record MeasurementRecord(string Instrument, long Value, IReadOnlyDictionary<string, object?> Tags);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user