]> git.argeo.org Git - gpl/argeo-slc.git/blob - runtime/org.argeo.slc.support.castor/src/test/java/org/argeo/slc/castor/ExecutionModuleDescriptorCastorTest.java
XML format for executions
[gpl/argeo-slc.git] / runtime / org.argeo.slc.support.castor / src / test / java / org / argeo / slc / castor / ExecutionModuleDescriptorCastorTest.java
1 package org.argeo.slc.castor;
2
3 import java.util.ArrayList;
4 import java.util.List;
5
6 import org.argeo.slc.execution.ExecutionFlowDescriptor;
7 import org.argeo.slc.execution.ExecutionModuleDescriptor;
8 import org.argeo.slc.execution.ExecutionSpec;
9 import org.argeo.slc.unit.execution.ExecutionFlowDescriptorTestUtils;
10
11 public class ExecutionModuleDescriptorCastorTest extends AbstractCastorTestCase {
12 public void testMarshUnmarsh() throws Exception {
13 ExecutionModuleDescriptor moduleDescriptor = new ExecutionModuleDescriptor();
14 moduleDescriptor.setName("test.moodule");
15 moduleDescriptor.setVersion("1.0.0");
16
17 ExecutionFlowDescriptor flowDescriptor = ExecutionFlowDescriptorTestUtils
18 .createSimpleExecutionFlowDescriptor();
19
20 List<ExecutionFlowDescriptor> flows = new ArrayList<ExecutionFlowDescriptor>();
21 flows.add(flowDescriptor);
22 moduleDescriptor.setExecutionFlows(flows);
23
24 List<ExecutionSpec> specs = new ArrayList<ExecutionSpec>();
25 specs.add(flowDescriptor.getExecutionSpec());
26 moduleDescriptor.setExecutionSpecs(specs);
27
28 marshUnmarsh(moduleDescriptor, false);
29 }
30 }