@Test
public void testItemExists() throws RepositoryException {

    boolean result = true;
    String path = "path";
    expect(session.itemExists(path)).andReturn(result);
    replay(session);
    replay(sessionFactory);
    assertEquals(jcrTemplate.itemExists(path), result);
}