@Test
public void testDoPrivilegedWhenNoPermissionsRestrictedActionThrows()
{

    Class<? extends Exception> expectedExceptionType = null;
    if (SecurityManagerHelper.isSecurityManagerEnabled())
    {
        expectedExceptionType = AccessControlException.class;
    }
    testDoPrivileged(expectedExceptionType, new PrivilegedAction<Void>()
    {
        @Override
        public Void run()
        {
            System.getProperty("test");
            return null;
        }
    });
}