Privilege[] write = privilegesFromNames(JCR_WRITE);
acl.addAccessControlEntry(testPrincipal, read);
acl.addAccessControlEntry(EveryonePrincipal.getInstance(), write);
AccessControlEntry invalid = new ACE(testPrincipal, write, false, Collections.<Restriction>emptySet(), namePathMapper);
try {
acl.orderBefore(invalid, acl.getEntries().get(0));
fail("src entry not contained in list -> reorder should fail.");
} catch (AccessControlException e) {
// success