### Question:
HibernateSessionDAO extends HibernatePersistentObjectDAO<Session> implements SessionDAO { @Override public List<Session> findByNode(String node) { try { if (StringUtils.isEmpty(node)) return findByWhere(" 1=1 ", null, "order by _entity.creation desc", null); else return findByWhere("_entity.node = ?1", new Object[] { node }, "order by _entity.creation desc", null); } catch (PersistenceException e) { log.error(e.getMessage(), e); return new ArrayList<Session>(); } } protected  HibernateSessionDAO(); @Override void deleteCurrentNodeSessions(); @Override int countSessions(Long tenantId, Integer status); @Override Session findBySid(String sid); @Override void initialize(Session session); @Override List<Session> findByNode(String node); @Override void cleanOldSessions(int ttl);  }### Answer:
@Test public void testFindByNode() { List<Session> sessions = dao.findByNode("saert536yy"); Assert.assertEquals(1, sessions.size()); sessions = dao.findByNode(null); Assert.assertEquals(1, sessions.size()); sessions = dao.findByNode("xxxx"); Assert.assertEquals(0, sessions.size()); }