use of ca.corefacility.bioinformatics.irida.model.workflow.description.IridaWorkflowDescription in project irida by phac-nml.
the class TestDataFactory method getIridaWorkflow.
public static IridaWorkflow getIridaWorkflow(UUID id) {
IridaWorkflowInput input = new IridaWorkflowInput();
List<IridaWorkflowOutput> outputs = ImmutableList.of(new IridaWorkflowOutput());
List<IridaWorkflowToolRepository> tools = ImmutableList.of();
List<IridaWorkflowParameter> parameters = ImmutableList.of();
IridaWorkflowDescription description = new IridaWorkflowDescription(id, "My Workflow", "V1", AnalysisType.DEFAULT, input, outputs, tools, parameters);
IridaWorkflowStructure structure = new IridaWorkflowStructure(null);
return new IridaWorkflow(description, structure);
}
use of ca.corefacility.bioinformatics.irida.model.workflow.description.IridaWorkflowDescription in project irida by phac-nml.
the class IridaWorkflowLoaderServiceIT method testLoadWorkflowDescriptionRequiresSingleSampleUnset.
/**
* Tests loading up the workflow description file that has no requires single sample parameter set.
*
* @throws IOException
* @throws IridaWorkflowLoadException
*/
@Test
public void testLoadWorkflowDescriptionRequiresSingleSampleUnset() throws IOException, IridaWorkflowLoadException {
IridaWorkflowDescription iridaWorkflowDescription = buildTestDescriptionRequiresSingleSampleUnset();
IridaWorkflowDescription iridaWorkflowFromFile = workflowLoaderService.loadWorkflowDescription(workflowRequiresSingleSampleUnsetXmlPath);
assertEquals("irida workflow description is invalid", iridaWorkflowFromFile, iridaWorkflowDescription);
}
use of ca.corefacility.bioinformatics.irida.model.workflow.description.IridaWorkflowDescription in project irida by phac-nml.
the class IridaWorkflowLoaderServiceIT method buildTestDescription.
private IridaWorkflowDescription buildTestDescription(UUID id, String name, String version, String sequenceReadsSingle, String sequenceReadsPaired, boolean requiresSingleSample) throws MalformedURLException {
List<IridaWorkflowOutput> outputs = new LinkedList<>();
outputs.add(new IridaWorkflowOutput("output1", "output1.txt"));
outputs.add(new IridaWorkflowOutput("output2", "output2.txt"));
List<IridaWorkflowToolRepository> tools = new LinkedList<>();
IridaWorkflowToolRepository workflowTool = new IridaWorkflowToolRepository("sam_to_bam", "devteam", new URL("http://toolshed.g2.bx.psu.edu/"), "8176b2575aa1");
tools.add(workflowTool);
List<IridaWorkflowParameter> parameters = new LinkedList<>();
IridaToolParameter tool1 = new IridaToolParameter("irida.corefacility.ca/galaxy-shed/repos/irida/test-tool/0.1", "a");
IridaToolParameter tool2 = new IridaToolParameter("irida.corefacility.ca/galaxy-shed/repos/irida/test-tool/0.1", "b");
IridaWorkflowParameter parameter1 = new IridaWorkflowParameter("test-parameter", "1", Lists.newArrayList(tool1, tool2));
parameters.add(parameter1);
IridaWorkflowDescription iridaWorkflow = new IridaWorkflowDescription(id, name, version, AnalysisType.DEFAULT, new IridaWorkflowInput(sequenceReadsSingle, sequenceReadsPaired, "reference", requiresSingleSample), outputs, tools, parameters);
return iridaWorkflow;
}
use of ca.corefacility.bioinformatics.irida.model.workflow.description.IridaWorkflowDescription in project irida by phac-nml.
the class IridaWorkflowLoaderServiceIT method testLoadWorkflowDescriptionNotRequiresSingleSample.
/**
* Tests loading up the workflow description file that does not require a single sample.
*
* @throws IOException
* @throws IridaWorkflowLoadException
*/
@Test
public void testLoadWorkflowDescriptionNotRequiresSingleSample() throws IOException, IridaWorkflowLoadException {
IridaWorkflowDescription iridaWorkflowDescription = buildTestDescriptionNotRequiresSingleSample();
IridaWorkflowDescription iridaWorkflowFromFile = workflowLoaderService.loadWorkflowDescription(workflowNotRequiresSingleSampleXmlPath);
assertEquals("irida workflow description is invalid", iridaWorkflowFromFile, iridaWorkflowDescription);
}
use of ca.corefacility.bioinformatics.irida.model.workflow.description.IridaWorkflowDescription in project irida by phac-nml.
the class IridaWorkflowLoaderServiceIT method testLoadWorkflowDescriptionSingle.
/**
* Tests loading up the workflow description file (single end data).
*
* @throws IOException
* @throws IridaWorkflowLoadException
*/
@Test
public void testLoadWorkflowDescriptionSingle() throws IOException, IridaWorkflowLoadException {
IridaWorkflowDescription iridaWorkflowDescription = buildTestDescriptionSingle();
IridaWorkflowDescription iridaWorkflowFromFile = workflowLoaderService.loadWorkflowDescription(workflowSingleXmlPath);
assertEquals("irida workflow description is invalid", iridaWorkflowFromFile, iridaWorkflowDescription);
}
Aggregations