import org.argeo.slc.msg.process.SlcExecutionStepsRequest;\r
import org.argeo.slc.unit.AbstractSpringTestCase;\r
import org.argeo.slc.unit.UnitXmlUtils;\r
+import org.argeo.slc.unit.process.SlcExecutionTestUtils;\r
\r
import org.springframework.oxm.Marshaller;\r
import org.springframework.oxm.Unmarshaller;\r
import org.springframework.xml.transform.StringResult;\r
import org.springframework.xml.transform.StringSource;\r
+import org.springframework.xml.validation.XmlValidator;\r
import org.springframework.xml.xsd.XsdSchema;\r
\r
public class SlcExecutionCastorTest extends AbstractSpringTestCase {\r
\r
@Override\r
public void setUp() {\r
- marshaller = getBean("marshaller");\r
- unmarshaller = getBean("marshaller");\r
+ marshaller = getBean(Marshaller.class);\r
+ unmarshaller = getBean(Unmarshaller.class);\r
}\r
\r
public void testMarshalling() throws Exception {\r
marshaller.marshal(obj, xml);\r
log.info("Marshalled object: " + xml);\r
\r
- XsdSchema schema = getBean("schema");\r
- UnitXmlUtils.assertXsdSchemaValidation(schema, new StringSource(xml\r
- .toString()));\r
+ UnitXmlUtils.assertXmlValidation(getBean(XmlValidator.class),\r
+ new StringSource(xml.toString()));\r
\r
return xml.toString();\r
}\r