/** Test default document content. */ @Test public void testDefaultDocumentContent() { final Content content = defaultGroup.getDefaultContent(); assertEquals(TYPE_DOCUMENT, content.getTypeId()); final Container rootDocFolder = content.getContainer(); assertEquals(true, rootDocFolder.isRoot()); }
/* * (non-Javadoc) * * @see * cc.kune.core.server.manager.GroupManager#setToolEnabled(cc.kune.domain. * User, java.lang.String, java.lang.String, boolean) */ @Override public void setToolEnabled( final User userLogged, final String groupShortName, final String tool, final boolean enabled) throws ToolIsDefaultException { final Group group = findByShortName(groupShortName); if (group.getDefaultContent().getStateToken().getTool().equals(tool) && !enabled) { throw new ToolIsDefaultException(); } ToolConfiguration toolConfiguration = group.getToolConfiguration(tool); if (toolConfiguration == null) { toolConfiguration = serverToolRegistry.get(tool).initGroup(userLogged, group).getToolConfiguration(tool); } toolConfiguration.setEnabled(enabled); }
/** Test default content and licenses. */ @Test public void testDefaultContentAndLicenses() { assertNotNull(defaultGroup.getDefaultContent()); assertTrue(licenseManager.getAll().size() > 0); assertNotNull(defaultGroup.getDefaultLicense()); }