TerminalEmulator add tests to ensure update() is called from dataReceived() and keyPressed()