@Test
public void processNewLineHandlesException() {

  myReceiver.processNewLine("[ 1534643988.771 11698:11811 E/AndroidRuntime ]");
  myReceiver.processNewLine("FATAL EXCEPTION: Timer-0");
  myReceiver.processNewLine("Process: com.android.chattylogger, PID: 11698");
  myReceiver.processNewLine("java.lang.RuntimeException: Bad response");
  myReceiver.processNewLine("       at com.android.chattylogger.MainActivity$1.run(MainActivity.java:64)");
  myReceiver.processNewLine("       at java.util.Timer$TimerImpl.run(Timer.java:284)");
  String expected = "2018-08-18 18:59:48.771 11698-11811/com.android.chattylogger E/AndroidRuntime: FATAL EXCEPTION: Timer-0\n" +
                    "+ Process: com.android.chattylogger, PID: 11698\n" +
                    "+ java.lang.RuntimeException: Bad response\n" +
                    "+     at com.android.chattylogger.MainActivity$1.run(MainActivity.java:64)\n" +
                    "+     at java.util.Timer$TimerImpl.run(Timer.java:284)\n";
  assertThat(myLogcatListener.toString()).isEqualTo(expected);
}