@Test
public void testNodeExists() throws Exception {

    Session delegate = mock(Session.class);
    SessionFacade<Session> facade = getFacade(delegate);
    final String path = "/correct/path";
    when(delegate.nodeExists(anyString())).thenReturn(false);
    when(delegate.nodeExists(path)).thenReturn(true);
    assertFalse("not exists at empty path", facade.nodeExists(""));
    assertTrue("exists at correct path", facade.nodeExists(path));
}