/** Test tool configuration. */ @Test public void testToolConfiguration() { assertNotNull(defaultGroup); final ToolConfiguration docToolConfig = defaultGroup.getToolConfiguration(TOOL_NAME); assertNotNull(docToolConfig); assertTrue(docToolConfig.isEnabled()); // final ToolConfiguration chatToolConfig = // defaultGroup.getToolConfiguration(ChatConstants.NAME); // assertNotNull(chatToolConfig); // assertTrue(chatToolConfig.isEnabled()); final List<String> enabledTools = groupManager.findEnabledTools(defaultGroup.getId()); assertNotNull(enabledTools); assertTrue(enabledTools.size() > 0); assertNotNull(containerManager.getTrashFolder(defaultGroup).getId()); }
/** * Gets the container. * * @param userHash the user hash * @param stateToken the state token * @return the container * @throws ContentNotFoundException the content not found exception */ @Authenticated(mandatory = false) @Authorizated(accessRolRequired = AccessRol.Viewer, actionLevel = ActionLevel.container) private Container getContainer(final String userHash, final StateToken stateToken) throws ContentNotFoundException { return containerManager.find(ContentUtils.parseId(stateToken.getFolder())); }