PackagedWorkflowRepository implements WorkflowRepository { @Override public Workflow getWorkflowById(String workflowId) throws RepositoryException { return workflows.get(workflowId); } PackagedWorkflowRepository(List<File> files); @Override Workflow getWorkflowByName(String workflowName); @Override Workflow getWorkflowById(String workflowId); @Override List getWorkflows(); @Override List getTasksByWorkflowId(String workflowId); @Override List getTasksByWorkflowName(String workflowName); @Override List getWorkflowsForEvent(String eventName); @Override List getConditionsByTaskName(String taskName); @Override List getConditionsByTaskId(String taskId); @Override WorkflowTaskConfiguration getConfigurationByTaskId(String taskId); @Override WorkflowTask getWorkflowTaskById(String taskId); @Override WorkflowCondition getWorkflowConditionById(String conditionId); @Override List getRegisteredEvents(); @Override String addTask(WorkflowTask task); @Override String addWorkflow(Workflow workflow); @Override List<WorkflowCondition> getConditionsByWorkflowId(String workflowId); @Override WorkflowTask getTaskById(String taskId);  }
@Test public void testWorkflowConditions(){ Workflow w = null; try{ w = this.repo.getWorkflowById("urn:npp:GranuleMaps"); } catch(Exception e){ fail(e.getMessage()); } assertNotNull(w); assertNotNull(w.getConditions()); System.out.println("NUM CONDITIONS: "+w.getConditions().size()); assertTrue(w.getConditions().size() > 0); assertEquals(w.getConditions().size(), 3); }