@Test
public void testOperationalSchema() throws Exception {

    InputStream inputStream = ConnectorUtilTest.class.getResourceAsStream("/config/SystemSchemaConfiguration.json");
    Assert.assertNotNull(inputStream);
    ObjectMapper mapper = new ObjectMapper();
    JsonValue configuration = new JsonValue(mapper.readValue(inputStream, Map.class));
    Map<String, Map<Class<? extends APIOperation>, OperationOptionInfoHelper>> operationOptionHelpers = ConnectorUtil.getOperationOptionConfiguration(configuration);
    ObjectClassInfoHelper objectClassInfoHelper = org.mockito.Mockito.mock(ObjectClassInfoHelper.class);
    org.mockito.Mockito.when(objectClassInfoHelper.getObjectClass()).thenReturn(new ObjectClass("__ACCOUNT__"));
    OperationHelper helper = new OperationHelperImpl(new Id("system/TEST/account"), objectClassInfoHelper, operationOptionHelpers.get("__ACCOUNT__"), null);
    Assert.assertTrue(helper.isOperationPermitted(CreateApiOp.class), "Create - ALLOWED");
    Assert.assertFalse(helper.isOperationPermitted(SyncApiOp.class), "Sync - DENIED");
    boolean authenticated = true;
    try {
        helper.isOperationPermitted(AuthenticationApiOp.class);
    } catch (JsonResourceException e) {
        authenticated = false;
    }
    Assert.assertFalse(authenticated, "Authentication - DENIED(Exception)");
    boolean operationSupported = true;
    try {
        helper.isOperationPermitted(ScriptOnResourceApiOp.class);
    } catch (JsonResourceException e) {
        operationSupported = false;
    }
    Assert.assertFalse(operationSupported, "ScriptOnResource - NotSupported(Exception)");
    Assert.assertFalse(helper.isOperationPermitted(ScriptOnConnectorApiOp.class), "ScriptOnConnector - DENIED");
    Assert.assertFalse(helper.isOperationPermitted(SearchApiOp.class), "Search - DENIED");
}