HttpSessionEventLoggingListener implements HttpSessionListener,
                                             HttpSessionAttributeListener,
                                             HttpSessionActivationListener { @Override public void attributeReplaced(HttpSessionBindingEvent se) { if (logger.isTraceEnabled()) { HttpSession session = se.getSession(); logger.trace("SESSIONID#{} attributeReplaced : {}={}", session .getId(), se.getName(), se.getValue()); } }  @Override void sessionWillPassivate(HttpSessionEvent se); @Override void sessionDidActivate(HttpSessionEvent se); @Override void attributeAdded(HttpSessionBindingEvent se); @Override void attributeRemoved(HttpSessionBindingEvent se); @Override void attributeReplaced(HttpSessionBindingEvent se); @Override void sessionCreated(HttpSessionEvent se); @Override void sessionDestroyed(HttpSessionEvent se);  }
@Test public void testAttributeReplaced() { String attributeRemovedStr = "SESSIONID#" + mockHttpSession.getId() + " attributeReplaced : terasoluna=AA"; listener.attributeReplaced(sessionBindingEvent); verifyLogging(attributeRemovedStr, Level.TRACE); }
@Test public void testAttributeReplacedisTraceEnabledFalse() throws Exception { LogLevelChangeUtil.setLogLevel(LogLevelChangeUtil.LogLevel.INFO); listener.attributeReplaced(sessionBindingEvent); assertThat(logger.isDebugEnabled(), is(false)); }