feat: support 4.0 in tests for XSLT and XQuery #1883
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR adds one compiler change and some simple tests for use of
I ran the v4.0 tests interactively with Saxon-EE 12 from Oxygen, after modifying the "Run XSpec Test" transformation scenario to set
saxon.custom.options
to--allowSyntaxExtensions:on
.On the command line, I also ran a similar v4.0 XQuery test with BaseX 10.7, though I substituted the following for the last verification in the test. I'm having trouble finding an XPath 4.0 construct that is already implemented in both Saxon XQuery and BaseX.
After running
external_xslt4.xspec
from Oxygen, I checked that the compiled stylesheet specifies<xsl:map-entry key="'xslt-version'">4.0</xsl:map-entry>
in the map of transform options.Does #1729 require more than what's in this PR?
Puzzles (non-blocking)
transform()
needs to specify the optionxslt-version="4.0"
to enable 4.0 support in the transformation being called, I was able to runexternal_xslt4.xspec
in Oxygen even without the change intransform-options.xsl
.Presumed instructions for users
Tests for XSLT or Schematron
xslt-version="4.0"
on<x:description>
ALLOW_SYNTAX_EXTENSIONS
(equivalently, use--allowSyntaxExtensions:on
on the command line, orglobal/@allowSyntaxExtensions="true"
in the configuration file). This step is copied from https://www.saxonica.com/documentation12/index.html#!v4extensions.In Oxygen "Run XSpec Test" transformation scenario, you can accomplish step 2 by including
--allowSyntaxExtensions:on
in thesaxon.custom.options
parameter.Tests for XQuery
Set
xquery-version="4.0"
on<x:description>