Package org.openengsb.core.api

Examples of org.openengsb.core.api.OpenEngSBService


        assertThat(accessControl.checkAccess("admin", invocation), Matchers.is(Access.GRANTED));
    }

    @Test
    public void checkServiceAccess_shouldGrant() throws Exception {
        OpenEngSBService service = mock(OpenEngSBService.class);
        when(service.getInstanceId()).thenReturn("fooService");
        MethodInvocation invocation = mock(MethodInvocation.class);
        when(invocation.getThis()).thenReturn(service);
        when(servicePermissionAccessConnector.checkAccess("testuser", invocation)).thenReturn(Access.GRANTED);
        assertThat(accessControl.checkAccess("testuser", invocation), Matchers.is(Access.GRANTED));
    }
View Full Code Here

TOP

Related Classes of org.openengsb.core.api.OpenEngSBService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.