I have tried to validate with xml against xsd using node module libxmljs(https://github.com/libxmljs/libxmljs/wiki#validating-against-xsd-schema) .So if element is mandatory in xsd but in xml element does not have any value ,it is empty then I should get error saying that Missing Element ,For example,
XSD:
<xsd:complexType name="ContractSummaryComplexType">
xsd:sequence
<xsd:element name="SvcAgreementID" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
XML:
<SvcAgreementID></SvcAgreementID>
Please help me to do this.
Thanks