|
|
@ -53,6 +53,14 @@ public class ChatGUITest { |
|
|
|
Font expectedFont = chatGUI.outputTextArea.getFont().deriveFont(Font.PLAIN, 20); |
|
|
|
assertEquals(expectedFont, chatGUI.outputTextArea.getFont()); |
|
|
|
} |
|
|
|
@Test |
|
|
|
public void testSendButtonActionPerformed() { |
|
|
|
chatGUI.inputTextField.setText("Testnachricht"); |
|
|
|
chatGUI.sendButton.doClick(); |
|
|
|
|
|
|
|
String expectedOutput = "Testnachricht\n"; |
|
|
|
assertEquals(expectedOutput, chatGUI.outputTextArea.getText()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|