You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Stringexpected = "<b>An error occurred.<br />220 ----------------- There was a problem<br />No username specified.<br />Server not configured properly.</b> <br /><br />Parameter not set.<br />Exception handling not configured.<br />Eat oranges they are great.<br /><br />";
22
+
Stringexpected = "<b>An error occurred.<br />220 ----------------- There was a problem<br />No username specified.<br />Server not configured properly.</b> <br /><br />Parameter not set.<br />Exception handling not configured.<br />Eat oranges they are great.<br /><br /><br />";
23
23
assertThat("Message formatted for error display", Dialogs.getFormattedErrorMessageForDisplay(message, t), is(expected));
24
24
25
25
}
@@ -49,16 +49,20 @@ public void GetFormattedErrorMessageForDisplay_NewLinesReplaced(){
StringplainText = "An error occurred.\r\n220 ----------------- There was a problem\r\nNo username specified.\r\nServer not configured properly.\r\nParameter not set.\r\nException handling not configured.\r\nEat oranges they are great.\r\n\r\n[XXX.yyy(BBB:99)]";
57
+
StringplainText = "An error occurred.\r\n220 ----------------- There was a problem\r\nNo username specified.\r\nServer not configured properly.\r\n\r\n\r\nParameter not set.\r\nException handling not configured.\r\nEat oranges they are great.\r\n\r\njava.lang.Throwable: Parameter not set.\r\nException handling not configured.\r\nEat oranges they are great.\r\n\n\tat XXX.yyy(BBB:99)\n";
58
58
assertThat("Message formatted for emailing copying", Dialogs.getFormattedErrorMessageForPlainText(message, t), is(plainText));
59
+
}
59
60
60
-
plainText = "An error occurred.\r\n220 ----------------- There was a problem\r\nNo username specified.\r\nServer not configured properly.\r\nThis is a detailed message\r\n";
Stringmessage = "An error occurred.\r\n220 ----------------- There was a problem\r\nNo username specified.\r\nServer not configured properly.";
64
+
StringplainText = "An error occurred.\r\n220 ----------------- There was a problem\r\nNo username specified.\r\nServer not configured properly.\r\n\r\n\r\nThis is a detailed message\r\n";
65
+
Throwablet = newThrowable("This is a detailed message");
62
66
t.setStackTrace(newStackTraceElement[0]);
63
67
assertThat("Message formatted without stacktrace fully present", Dialogs.getFormattedErrorMessageForPlainText(message, t), is(plainText));
0 commit comments