mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2025-12-30 09:47:58 +01:00
Only show Expected/But Was for failing tests in AssertDriverContentsAre
This commit is contained in:
@@ -120,8 +120,11 @@ class TestHelpers {
|
||||
expectedLook = expectedLook.Replace ("\r\n", "\n");
|
||||
actualLook = actualLook.Replace ("\r\n", "\n");
|
||||
|
||||
output?.WriteLine ("Expected:" + Environment.NewLine + expectedLook);
|
||||
output?.WriteLine ("But Was:" + Environment.NewLine + actualLook);
|
||||
// If test is about to fail show user what things looked like
|
||||
if(!string.Equals(expectedLook,actualLook)) {
|
||||
output?.WriteLine ("Expected:" + Environment.NewLine + expectedLook);
|
||||
output?.WriteLine ("But Was:" + Environment.NewLine + actualLook);
|
||||
}
|
||||
|
||||
Assert.Equal (expectedLook, actualLook);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user