This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
Test-cases "Serialization-026,Serialization-027,Serialization-028,Serialization-029,Serialization-030" from "prod-OptionDecl.serialization" test-set assume an XQuery implementation MUST support serialization parameters specified in the query prolog. According to the http://www.w3.org/TR/xquery-30/#id-serialization spec: "If an XQuery implementation provides a serialization interface, it may support (and may expose to users) any of the serialization parameters listed (with default values) in C.1 Static Context Components. If an implementation does not support one of these parameters, it must ignore it without raising an error." [...] "Processors may also allow external mechanisms for specifying serialization parameters, which may or may not override serialization parameters specified in the query prolog." The test cases should be updated to reflect the latest version of the spec.
Probably the approach to take is to have two variants of the test case: *one where where we add the dependency expecting the support of serialization parameters, i.e. satisfied=true. * The other where were the dependency on the serialization parameters is not available, i.e. satisfied=false If you agree, I will make the change.
(In reply to comment #1) > Probably the approach to take is to have two variants of the test case: > > *one where where we add the dependency expecting the support of > serialization parameters, i.e. satisfied=true. > > * The other where were the dependency on the serialization parameters is not > available, i.e. satisfied=false > > If you agree, I will make the change. Agree but first I think one has to create a new dependency in FOTS for the serialization parameters specified in prolog, right?
Please note that same reported problem applies to 23 of the new test-cases added in the test-set "misc-Serialization" that were created by Henry Zongaro: Here are the 23 test-case names: "Serialization-html-1", "Serialization-html-2", "Serialization-html-3", "Serialization-html-4", "Serialization-html-18", "Serialization-html-19a", "Serialization-html-19b", "Serialization-html-19c", "Serialization-html-22", "Serialization-html-25", "Serialization-html-26", "Serialization-html-27, "Serialization-html-28", "Serialization-html-29", "Serialization-html-30", "Serialization-html-33", "Serialization-html-34", "Serialization-html-35", "Serialization-html-36", "Serialization-html-37", "Serialization-html-38", "Serialization-html-39", "Serialization-html-40"
Bug now fixed according to comment #1 and committed to cvs. Just to confirm I have added a new feature dependency (see below) for all the serialization tests specified: <dependency type="feature" value="serialization" satisfied="true"/> This means that vendors will need to add this new dependency feature in their respective test drivers. I have added test variants for Serialization-026,Serialization-027, ideally for implementers who cannot support serialization; here the serialization feature is set satisfied="false". I have Given them the name Serialization-026a,Serialization-027a, respectively. Please check that the assertions are ok?
The following test-cases from "prod-OptionDecl.serialization" test-set need to be added the <dependency type="feature" value="serialization" satisfied="true"/>: - "Serialization-004", "Serialization-005", "Serialization-031", "Serialization-032"
(In reply to comment #5) > - "Serialization-004", "Serialization-005", "Serialization-031", > "Serialization-032" Dependency added to the tests as suggested
Test Serialization-026a assumes that the serialization feature is not supported. declare namespace output = "http://www.w3.org/2010/xslt-xquery-serialization"; declare option output:method "xml"; declare option output:standalone "yes"; (<a/>,<b/>) It expects "<a/> <b/>". I believe that "<a/><b/>" is the value that should be expected.
(In reply to comment #7) > It expects "<a/> <b/>". I believe that "<a/><b/>" is the value that should > be expected. Thanks Andrew. Fixed applied.
I'm looking more closely at Serialization-026a: <result> <assert-string-value><![CDATA[<a/><b/>]]></assert-string-value> </result> assert-string-value applies this expression to the result: string-join(for $r in $result return string($r), " ") This generates a result of " " for the query (<a/>,<b/>).
I am not sure how best to resolve this one. We cannot use <assert/> or <assert-xml/> because the output is not a valid XML document. Any suggestions?
AS discussed in the WG telecon. My suggestion was agreed with to add a enclosing element in the query. This means that we can now use assert-xml for the expected output. The new test-case is as follows: <test-case name="Serialization-026a"> ... <dependency type="feature" value="serialization" satisfied="false"/> <test><![CDATA[ declare namespace output = "http://www.w3.org/2010/xslt-xquery-serialization"; declare option output:method "xml"; declare option output:standalone "yes"; <out>{(<a/>,<b/>)}</out> ]]></test> <result> <assert-xml><![CDATA[<out><a/><b/></out>]]></assert-xml> </result> </test-case>