Skip to content

Commit

Permalink
Removed stack trace comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
iNinja committed Nov 15, 2024
1 parent 3b5a830 commit 84c4384
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions test/Microsoft.IdentityModel.TestUtils/IdentityComparer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1473,17 +1473,6 @@ internal static bool AreValidationErrorsEqual(ValidationError validationError1,
{
localContext.Diffs.Add($"exception1.StackTrace is null. Exception type: {exception1.GetType().Name}");
}
else
{
// If the stack trace is present, ensure it contains the expected amount of frames.
var stackTraceFrames = exception1.StackTrace.Trim('\n').Split('\n').Where(s => !s.IsNullOrEmpty());
if (stackTraceFrames.Count() != validationError2.StackFrames.Count)
{
localContext.Diffs.Add($"(exception1.StackTrace.Trim('\\n\').Split('\\n').Count() != validationError2.StackFrames.Count: " +
$"{stackTraceFrames.Count()}, {validationError2.StackFrames.Count})");
localContext.Diffs.Add($"exception1.StackTrace: {exception1.StackTrace}");
}
}

return context.Merge(localContext);
}
Expand Down

0 comments on commit 84c4384

Please sign in to comment.