|
@ -23,6 +23,17 @@ public class ChatGUITest { |
|
|
chatGUI.actionPerformed(new TestActionEvent(chatGUI.blue)); |
|
|
chatGUI.actionPerformed(new TestActionEvent(chatGUI.blue)); |
|
|
assertEquals(Color.BLUE, chatGUI.outputTextArea.getForeground()); |
|
|
assertEquals(Color.BLUE, chatGUI.outputTextArea.getForeground()); |
|
|
} |
|
|
} |
|
|
|
|
|
@Test |
|
|
|
|
|
public void testSetOutputTextColorBlack() { |
|
|
|
|
|
chatGUI.actionPerformed(new TestActionEvent(chatGUI.black)); |
|
|
|
|
|
assertEquals(Color.BLACK, chatGUI.outputTextArea.getForeground()); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Test |
|
|
|
|
|
public void testSetOutputTextColorGreen() { |
|
|
|
|
|
chatGUI.actionPerformed(new TestActionEvent(chatGUI.green)); |
|
|
|
|
|
assertEquals(Color.GREEN, chatGUI.outputTextArea.getForeground()); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|