mbeckerle opened a new pull request #560: URL: https://github.com/apache/daffodil/pull/560
Ready for review. Tests that show this error detection for each of * DFDL schemas * included DFDL schemas * imported DFDL schemas * TDML files * XML Infoset files used in TDML tests * Config files used in TDML tests * External variable binding files Eliminating use of DOCTYPE also eliminates any possibility of XML General or Paremter Entities. Consolidated loader/validators of XML and XSD. Everything that loads XML, XSD, TDML, config, external vars, or ".dfdl.xsd", now uses DaffodilXMLLoader to do it. Specific validators that were for Config files or External Variable Binding files are now gone. DaffodilXMLLoader was simplified and made more uniform. Single purpose mixin traits and adapters were eliminated. The validation in DaffodilXMLLoader uses two methods. First it uses the XercesValidator (used by the validation feature). Second it does a validating load with Xerces. This seems to catch/report different validation problems. (Instrumentation to prove this may be worth it, so that we can get rid of redundant work if possible) DFDL schemas are validated by constructing an XML Schema object from them, as well as by loading them and validating against the XML Schema for DFDL schemas. The DaffodilXMLLoader validates (if requested) using a supplied XML Schema. But then always loads using the DaffodilConstructingParser which uses the underlying ConstructingParser - this is needed because in many cases we are dependent on properly handling CDATA regions (e.g., TDML files, test infoset XML files, etc) which Xerces doesn't do properly. I attempted to implement DAFFODIL-288 to validate the infoset XML (before unparsing) also but was unsuccessful so far, but a TODO DAFFODIL-288 marks the place where that fix goes. New validation is more uniform, and thorough. This caught a number of small issues like missing "tdml:" prefixes on numerous files' testSuite elements. There were various adjustments to accomodate the more strict validation. Fixes to SAX due to simple types now being series of Text, Atom, and EntityRef. Various other small fixes to TDML runner to insure no diagnostic errors are being hidden. DAFFODIL-1422, DAFFODIL-1659 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
