18 lines
569 B
C#
18 lines
569 B
C#
using StellaOps.Canonicalization.Verification;
|
|
using StellaOps.Replay.Models;
|
|
|
|
namespace StellaOps.Replay.Engine;
|
|
|
|
public sealed partial class ReplayEngine
|
|
{
|
|
private static IReadOnlyList<JsonDifference> FindJsonDifferences(string? a, string? b)
|
|
{
|
|
if (a is null || b is null)
|
|
return [new JsonDifference("$", "One or both values are null")];
|
|
|
|
var verifier = new DeterminismVerifier();
|
|
var result = verifier.Compare(a, b);
|
|
return result.Differences.Select(d => new JsonDifference(d, "Value mismatch")).ToList();
|
|
}
|
|
}
|