Summary
Let's take the following error diff:
Assert.AreEqual failed. Expected string length 199 but was 139. 'expected' expression: 'Normalize(expected)', 'actual' expression: 'Normalize(actual)'.
Expected: "...n 1; }␊ #endregion␊␊ #region ..."
But was: "...n 1; }␊ #endregion␊ #endregion␊}"
This is nice for spotting the exact difference but it's sometimes interesting to have access to the full context.
For examples:
-
When you are in a scenario where you are changing the output, it's useful to be able to copy the new expected content to replace current expected.
-
When there are more than one issue, you would need to run the assert multiple times when having the full actual/expected might allow you to do an extra check upfront.