bwrrp / xspattern.js

XML Schema pattern (regular expression) engine
MIT License
10 stars 2 forks source link

Run regex tests from XML Schema test suite #1

Closed bwrrp closed 5 years ago

bwrrp commented 5 years ago

The W3C XML Schema 1.1 test suite contains a large number of regex tests at https://github.com/w3c/xsdtests/tree/master/msData/regex

Most of these follow a very similar structure in where the input to be validated is located in the input XML document. We should see if we can write some minimal logic to extract the patterns and input values from the XML / XSD files and feed them to the engine. The file https://github.com/w3c/xsdtests/blob/master/msMeta/Regex_w3c.xml seems to contain info on which tests are supposed to pass and which should fail.