GuvnorStructureContext { public String getCurrentBranch(final String alias) { return aliasBranch.get(alias); } GuvnorStructureContext(); @Inject  GuvnorStructureContext(final Caller<RepositoryService> repositoryService, final WorkspaceProjectContext context); void getRepositories(final Callback<Collection<Repository>> callback); GuvnorStructureContextChangeHandler.HandlerRegistration addGuvnorStructureContextChangeHandler(final GuvnorStructureContextChangeHandler handler); GuvnorStructureContextBranchChangeHandler.HandlerRegistration addGuvnorStructureContextBranchChangeHandler(final GuvnorStructureContextBranchChangeHandler handler); void changeBranch(final String alias,
                             final String branch); void onNewRepository(final @Observes NewRepositoryEvent event); void onNewBranch(final @Observes NewBranchEvent event); void onRepositoryRemoved(final @Observes RepositoryRemovedEvent event); void removeHandler(final GuvnorStructureContextChangeHandler.HandlerRegistration handlerRegistration); void removeHandler(final GuvnorStructureContextBranchChangeHandler.HandlerRegistration handlerRegistration); String getCurrentBranch(final String alias);  }
@Test public void testLoadDefaultBranches() throws Exception { for (Repository repository : result) { assertEquals("master", context.getCurrentBranch(repository.getAlias())); } }