public void activateTagFiltering() { options.add( Option.SHOW_TAG_FILTER ); activeContextOptionsChangedEvent.fire( new ActiveOptionsChangedEvent() ); }
public void activateTreeViewNavigation() { options.remove( Option.BREADCRUMB_NAVIGATOR ); options.add( Option.TREE_NAVIGATOR ); activeContextOptionsChangedEvent.fire( new ActiveOptionsChangedEvent() ); }
public void activateBusinessView() { options.add( Option.BUSINESS_CONTENT ); options.remove( Option.TECHNICAL_CONTENT ); activeContextOptionsChangedEvent.fire( new ActiveOptionsChangedEvent() ); }
public void activateTechView() { options.remove( Option.BUSINESS_CONTENT ); options.add( Option.TECHNICAL_CONTENT ); activeContextOptionsChangedEvent.fire( new ActiveOptionsChangedEvent() ); }
public void activateBreadCrumbNavigation() { options.add( Option.BREADCRUMB_NAVIGATOR ); options.remove( Option.TREE_NAVIGATOR ); activeContextOptionsChangedEvent.fire( new ActiveOptionsChangedEvent() ); }
private ProjectExplorerContentQuery getContentQuery(final Branch branch, final Module module, final Option content, final Package pkg, final FolderItem item) { final ProjectExplorerContentQuery projectExplorerContentQuery = new ProjectExplorerContentQuery( repository, branch, module, pkg, item ); final ActiveOptions options = new ActiveOptions(); options.add(Option.TREE_NAVIGATOR); options.add(Option.EXCLUDE_HIDDEN_ITEMS); options.add(content); projectExplorerContentQuery.setOptions(options); return projectExplorerContentQuery; }
@Test public void testResolveWithOUWithRepositoryNullQueryTechnicalView() throws Exception { final ProjectExplorerContentQuery query = new ProjectExplorerContentQuery(repository, masterBranch); final ActiveOptions options = new ActiveOptions(); options.add(Option.TREE_NAVIGATOR); options.add(Option.EXCLUDE_HIDDEN_ITEMS); options.add(Option.TECHNICAL_CONTENT); query.setOptions(options); resolver.resolve(query); }
@Test public void testResolveWithOUWithRepositoryNullQueryBusinessView() throws Exception { final ProjectExplorerContentQuery query = new ProjectExplorerContentQuery(repository, masterBranch); final ActiveOptions options = new ActiveOptions(); options.add(Option.TREE_NAVIGATOR); options.add(Option.EXCLUDE_HIDDEN_ITEMS); options.add(Option.BUSINESS_CONTENT); query.setOptions(options); resolver.resolve(query); }
private ProjectExplorerContentQuery getContentQuery(final Repository repository, final String branchName, final Module module) { final Branch branch = new Branch(branchName, mock(Path.class)); final ProjectExplorerContentQuery moduleExplorerContentQuery = new ProjectExplorerContentQuery(repository, branch, module); doReturn(new WorkspaceProject(mock(OrganizationalUnit.class), repository, branch, module)).when(projectService).resolveProject(repository.getSpace(), branch); final ActiveOptions options = new ActiveOptions(); options.add(Option.TREE_NAVIGATOR); options.add(Option.EXCLUDE_HIDDEN_ITEMS); options.add(Option.BUSINESS_CONTENT); moduleExplorerContentQuery.setOptions(options); return moduleExplorerContentQuery; }
@Test public void testChangeModuleOnTechnicalViewWhenThereIsAFolderItemButNoActiveModuleOrganizationalUnitOrRepository() { resolver.resolve(getContentQuery(masterBranch, createModule("master", masterBranch, "module 1"), Option.TECHNICAL_CONTENT)); helperWrapper.reset(); ProjectExplorerContentQuery projectExplorerContentQuery = new ProjectExplorerContentQuery( null, null, null, null, getFileItem() ); ActiveOptions options = new ActiveOptions(); options.add(Option.TECHNICAL_CONTENT); projectExplorerContentQuery.setOptions(options); helperWrapper.excludePackage(); Content content = resolver.setupSelectedItems(projectExplorerContentQuery); helperWrapper.reset(); assertEquals("master", content.getSelectedProject().getBranch().getName()); assertEquals("master@module 1", content.getSelectedModule().getRootPath().toURI()); assertNotNull(content.getSelectedItem()); assertNull(content.getSelectedPackage()); }