protected boolean isAssumeIdentity(ConnectionReference conn) {
        return isAnonymousAccessAllowed() ||
                (isSystemConnection(conn) && !isVmConnectionAuthenticationRequired());
    }
@Test
    public void testIsAssumeIdentity() {
        policy.setAnonymousAccessAllowed(true);
        assertTrue(policy.isAssumeIdentity(null));
    }