SecurityRoleFunctionServiceImpl implements SecurityRoleFunctionService { @Override public SecurityRoleFunctionKeys getSecurityRoleFunctions() { SecurityRoleFunctionKeys securityRoleFunctionKeys = new SecurityRoleFunctionKeys(); securityRoleFunctionKeys.getSecurityRoleFunctionKeys().addAll(securityRoleFunctionDao.getSecurityRoleFunctionKeys()); return securityRoleFunctionKeys; }  @Override SecurityRoleFunction createSecurityRoleFunction(SecurityRoleFunctionCreateRequest securityRoleFunctionCreateRequest); @Override SecurityRoleFunction deleteSecurityRoleFunction(SecurityRoleFunctionKey securityRoleFunctionKey); @Override SecurityRoleFunction getSecurityRoleFunction(SecurityRoleFunctionKey securityRoleFunctionKey); @Override SecurityRoleFunctionKeys getSecurityRoleFunctions(); @Override SecurityRoleFunctionKeys getSecurityRoleFunctionsBySecurityFunction(SecurityFunctionKey securityFunctionKey); @Override SecurityRoleFunctionKeys getSecurityRoleFunctionsBySecurityRole(SecurityRoleKey securityRoleKey);  }
@Test public void testGetSecurityRoleFunctions() { List<SecurityRoleFunctionKey> securityRoleFunctionKeys = Collections.singletonList(new SecurityRoleFunctionKey(SECURITY_ROLE, SECURITY_FUNCTION)); when(securityRoleFunctionDao.getSecurityRoleFunctionKeys()).thenReturn(securityRoleFunctionKeys); SecurityRoleFunctionKeys result = securityRoleFunctionService.getSecurityRoleFunctions(); assertEquals(new SecurityRoleFunctionKeys(securityRoleFunctionKeys), result); verify(securityRoleFunctionDao).getSecurityRoleFunctionKeys(); verifyNoMoreInteractionsHelper(); }