@Test
  public void parseCausedBy() {
    CausedBy causedBy = lineParser.parseCausedBy(CAUSED_BY, currentLogStatement);

    assertEquals(
        new Clazz("javax.ejb.EJBTransactionRolledbackException"), causedBy.getExceptionClazz());
  }
  @Test
  public void parseLogStatement_ERROR() {
    LogStatement log = lineParser.parseLogStatement(ERROR_LOG);

    assertNotNull(log);
    assertEquals(Level.ERROR, log.getLevel());
    // TODO finish testSimpleInfoWithException
  }
  @Test
  public void testCausedByOnlyClass() {
    CausedBy causedBy = lineParser.parseCausedBy(CAUSED_BY_ONLY_CLASS, currentLogStatement);

    assertEquals(
        "javax.servlet.ServletException", causedBy.getExceptionClazz().getFullyQualifiedName());
    assertEquals("", causedBy.getMessage());
  }
  @Test
  public void parseLogStatement_INFO() {
    LogStatement log = lineParser.parseLogStatement(INFO_LOG);

    assertEquals(LocalTime.of(1, 55, 16), log.getTime());
    assertEquals(Level.INFO, log.getLevel());
    assertEquals(new Clazz("com.web.seam.action.AuthenticatorImpl"), log.getClazz());
    assertEquals("Login successfull for user: [email protected]", log.getMessage());
  }
  @Test
  public void parseCausedByWithException() {
    CausedBy causedBy = lineParser.parseCausedBy(CAUSED_BY_LONG, currentLogStatement);

    assertEquals(new Clazz("javax.faces.FacesException"), causedBy.getExceptionClazz());
    assertEquals(
        "#{facilityChooserAction.facilitySelected}: javax.ejb.EJBTransactionRolledbackException",
        causedBy.getMessage());
  }
  @Test
  public void parseAtLine() {
    AtLine atLine = lineParser.parseAtLine(AT_LINE);

    assertNotNull(atLine);
    assertEquals(new Clazz("org.apache.catalina.core.ApplicationFilterChain"), atLine.getClazz());
    assertEquals("doFilter", atLine.getMethod());
    assertEquals("ApplicationFilterChain.java:206", atLine.getSource());
  }
  @Test
  public void testLongLineWithDoubleRegexPattern() {
    CausedBy causedBy =
        lineParser.parseCausedBy(CAUSED_BY_WITH_DOUBLE_PATTERN, currentLogStatement);

    assertEquals("javax.el.ELException", causedBy.getExceptionClazz().getFullyQualifiedName());
    assertEquals(
        "/incl/mainmenu.xhtml @10,260 rendered=\"#{identity.loggedIn and identity.hasRole(applicationService.showRoleId('ADMIN')) eq false}\": org.jboss.seam.RequiredException: @In attribute requires non-null value: applicationService.entityManager",
        causedBy.getMessage());
  }
 @Test
 public void testMathesMore() {
   assertTrue(lineParser.matchesMore(MORE_LINE));
 }