Revised: $Date: 2001/07/21 01:32:44 $(UTC)
1. IntroductionThis document details identified areas of the XSLT and XPath Recommendations that describe or allow optionality in the behavior of an XSLT processor. The majority of the identified optional or discretionary behavior concerns detection or recovery from error conditions, but other areas have been identified as well. This document is also the foundation for a questionnaire for developers of XSLT processors; it asks questions that a test lab would need answered in order to administer the test suite to that devloper's processor.
Each area of discretionary behavior is shown as an entry comprising at least five items:
Answers to the "testable" questions are expressed as keywords so that the cataloging information about the test cases will be readable without reference to this document, at least after one has attained familiarity with the discretionary areas. The complete set of keywords, as of this writing, is: add-space, choose-last, ignore, moot, no, pass-through, raise-error, return-empty, yes.
Where longer answers are required depending on the brief answer, the "ELABORATE" flag is shown.
The questions are not all independent. The "INTERLOCK" flag appears when answers to two or more questions should be reviewed for consistency.
The following items represent statements in the XSLT and XPath Recommendations that identify discretionary behavior that are controlling test selection in the current version of the test suite.
The xsl:number element is used to insert a formatted number into the result tree. The number to be inserted may be specified by an expression. The value attribute contains an expression. The expression is evaluated and the resulting object is converted to a number as if by a call to the number function. It is an error if the number is NaN, infinite or less than 0.5; an XSLT processor may signal the error; if it does not signal the error, it must recover by converting the number to a string as if by a call to the string function and inserting the resulting string into the result tree.
Question:
1. (Filter) What happens when xsl:number is given NaN, Infinity, or a non-positive number?
Valid choices: pass-through, raise-error
Specification citations (manual):
Specification citations (machine):
The following items represent statements in the XSLT and XPath Recommendations that identify discretionary behavior that are proposed for testing in the next deliverable version of the test suite.
It is an error if this leaves more than one match. An XSLT processor may signal the error; if it does not signal the error, it must recover by choosing, from amongst the matches that are left, the one that occurs last in the stylesheet.
Question:
1. (Filter) What happens when there is an unresolved conflict between matches to xsl:strip-space and xsl:preserve-space elements?
Valid choices: choose-last, raise-error
Specification citations (manual):
Specification citations (machine):
It is an error if this leaves more than one matching template rule. An XSLT processor may signal the error; if it does not signal the error, it must recover by choosing, from amongst the matching template rules that are left, the one that occurs last in the stylesheet.
Question:
1. (Filter) What happens when there is an unresolved conflict between matches to xsl:template elements?
Valid choices: choose-last, raise-error
Specification citations (manual):
Specification citations (machine):
A stylesheet can use the xsl:namespace-alias element to declare that one namespace URI is an alias for another namespace URI. When a literal namespace URI has been declared to be an alias for another namespace URI, then the namespace URI in the result tree will be the namespace URI that the literal namespace URI is an alias for, instead of the literal namespace URI itself. The xsl:namespace-alias element declares that the namespace URI bound to the prefix specified by the stylesheet-prefix attribute is an alias for the namespace URI bound to the prefix specified by the result-prefix attribute. Thus, the stylesheet-prefix attribute specifies the namespace URI that will appear in the stylesheet, and the result-prefix attribute specifies the corresponding namespace URI that will appear in the result tree. The default namespace (as declared by xmlns) may be specified by using #default instead of a prefix. If a namespace URI is declared to be an alias for multiple different namespace URIs, then the declaration with the highest import precedence is used. It is an error if there is more than one such declaration. An XSLT processor may signal the error; if it does not signal the error, it must recover by choosing, from amongst the declarations with the highest import precedence, the one that occurs last in the stylesheet.
Question:
1. (Filter) What happens when a namespace URI is declared to be an alias for multiple different namespace URIs and the declarations share the highest import precedence?
Valid choices: choose-last, raise-error
Specification citations (manual):
Specification citations (machine):
The name attribute is interpreted as an attribute value template. It is an error if the string that results from instantiating the attribute value template is not a QName. An XSLT processor may signal the error; if it does not signal the error, then it must recover by making the the result of instantiating the xsl:element element be the sequence of nodes created by instantiating the content of the xsl:element element, excluding any initial attribute nodes. If the namespace attribute is not present then the QName is expanded into an expanded-name using the namespace declarations in effect for the xsl:element element, including any default namespace declaration.
Question:
1. (Filter) What happens when the result of instantiating the name attribute of the xsl:element element is not a QName?
Valid choices: pass-through, raise-error
Specification citations (manual):
Specification citations (machine):
The name attribute is interpreted as an attribute value template. It is an error if the string that results from instantiating the attribute value template is not a QName or is the string xmlns. An XSLT processor may signal the error; if it does not signal the error, it must recover by not adding the attribute to the result tree. If the namespace attribute is not present, then the QName is expanded into an expanded-name using the namespace declarations in effect for the xsl:attribute element, not including any default namespace declaration.
Question:
1. (Filter) What happens when the result of instantiating the name attribute of the xsl:attribute element is not a QName?
Valid choices: ignore, raise-error
Specification citations (manual):
Specification citations (machine):
Adding an attribute to an element after children have been added to it; implementations may either signal the error or ignore the attribute.
Question:
1. (Filter) What happens when an attribute is added to an element after children have been added to it?
Valid choices: ignore, raise-error
Specification citations (manual):
Specification citations (machine):
Adding an attribute to a node that is not an element; implementations may either signal the error or ignore the attribute.
Question:
1. (Filter) What happens when an attribute is added to a node that is not an element?
Valid choices: ignore, raise-error
Interlock: If the answer to 'add-attribute-to-non-element' doesn't match the answers to 'attribute-non-text-content', 'PI-non-text-content', or 'comment-non-text-content', please review the behavior. If the inconsistency was intentional, ELABORATE on what happens when an attempt is made to add an attribute as content to attributes, processing instructions, and comments.
Specification citations (manual):
Specification citations (machine):
Creating nodes other than text nodes during the instantiation of the content of the xsl:attribute element; implementations may either signal the error or ignore the offending nodes.
Question:
1. (Filter) What happens when nodes other than text nodes are created when instantiating the content of the xsl:attribute element?
Valid choices: ignore, raise-error
Interlock: If the answer to 'add-attribute-to-non-element' doesn't match the answers to 'attribute-non-text-content', 'PI-non-text-content', or 'comment-non-text-content', please review the behavior. If the inconsistency was intentional, ELABORATE on what happens when an attempt is made to add an attribute as content to attributes, processing instructions, and comments.
Specification citations (manual):
Specification citations (machine):
Multiple definitions of an attribute set with the same expanded-name are merged. An attribute from a definition that has higher import precedence takes precedence over an attribute from a definition that has lower import precedence. It is an error if there are two attribute sets that have the same expanded-name and equal import precedence and that both contain the same attribute, unless there is a definition of the attribute set with higher import precedence that also contains the attribute. An XSLT processor may signal the error; if it does not signal the error, it must recover by choosing from amongst the definitions that specify the attribute that have the highest import precedence the one that was specified last in the stylesheet. Where the attributes in an attribute set were specified is relevant only in merging the attributes into the attribute set; it makes no difference when the attribute set is used.
Question:
1. (Filter) What happens when two attribute sets that have the same expanded name and share the highest import precedence both contain the same attribute?
Valid choices: choose-last, raise-error
Specification citations (manual):
Specification citations (machine):
It is an error if the string that results from instantiating the name attribute is not both an NCName and a PITarget. An XSLT processor may signal the error; if it does not signal the error, it must recover by not adding the processing instruction to the result tree.
Question:
1. (Filter) What happens when the result of instantiating the name attribute of the xsl:processing-instruction element is not an NCName and a PITarget?
Valid choices: ignore, raise-error
Specification citations (manual):
Specification citations (machine):
It is an error if instantiating the content of xsl:processing-instruction creates nodes other than text nodes. An XSLT processor may signal the error; if it does not signal the error, it must recover by ignoring the offending nodes together with their content.
Question:
1. (Filter) What happens when nodes other than text nodes are created when instantiating the content of the xsl:processing-instruction element?
Valid choices: ignore, raise-error
Interlock: If the answer to 'add-attribute-to-non-element' doesn't match the answers to 'attribute-non-text-content', 'PI-non-text-content', or 'comment-non-text-content', please review the behavior. If the inconsistency was intentional, ELABORATE on what happens when an attempt is made to add an attribute as content to attributes, processing instructions, and comments.
Specification citations (manual):
Specification citations (machine):
It is an error if the result of instantiating the content of the xsl:processing-instruction contains the string ?>. An XSLT processor may signal the error; if it does not signal the error, it must recover by inserting a space after any occurrence of ? that is followed by a >.
Question:
1. (Filter) What happens when the result of instantiating the content of the xsl:processing-instruction element contains the string ?>?
Valid choices: add-space, raise-error
Specification citations (manual):
Specification citations (machine):
It is an error if instantiating the content of xsl:comment creates nodes other than text nodes. An XSLT processor may signal the error; if it does not signal the error, it must recover by ignoring the offending nodes together with their content.
Question:
1. (Filter) What happens when nodes other than text nodes are created when instantiating the content of the xsl:comment element?
Valid choices: ignore, raise-error
Interlock: If the answer to 'add-attribute-to-non-element' doesn't match the answers to 'attribute-non-text-content', 'PI-non-text-content', or 'comment-non-text-content', please review the behavior. If the inconsistency was intentional, ELABORATE on what happens when an attempt is made to add an attribute as content to attributes, processing instructions, and comments.
Specification citations (manual):
Specification citations (machine):
It is an error if the result of instantiating the content of the xsl:comment contains the string -- or ends with -. An XSLT processor may signal the error; if it does not signal the error, it must recover by inserting a space after any occurrence of - that is followed by another - or that ends the comment.
Question:
1. (Filter) What happens when the result of instantiating the content of the xsl:comment element contains the string -- or ends with -?
Valid choices: add-space, raise-error
Specification citations (manual):
Specification citations (machine):
It is an error if a member of the sequence of nodes created by instantiating the template is an attribute node or a namespace node, since a root node cannot have an attribute node or a namespace node as a child. An XSLT processor may signal the error; if it does not signal the error, it must recover by not adding the attribute node or namespace node.
Question:
1. (Filter) What happens when instantiating a variable-binding element adds an attribute node or namespace node as a child of the root of the result tree fragment?
Valid choices: ignore, raise-error
Specification citations (manual):
Specification citations (machine):
When the current node is a namespace node, then copying it adds a namespace node to the containing node in the result tree. It is an error if this containing node is not an element; implementations may either signal the error or ignore the namespace node. It is an error to add a namespace node to an element after children have been added to it or after attributes have been added to it; implementations may either signal an error or ignore the namespace node. It is an error to add a namespace node to an element if the element already has a namespace node with the same name, unless both namespace nodes have the same string-value, in which case the duplicate is ignored. It is an error to add a namespace node to an element if the namespace node has a null name and the element has a null namespace URI.
Question:
1. (Filter) What happens when a namespace is copied to a node that is not an element?
Valid choices: ignore, raise-error
Specification citations (manual):
Specification citations (machine):
When the current node is a namespace node, then copying it adds a namespace node to the containing node in the result tree. It is an error if this containing node is not an element; implementations may either signal the error or ignore the namespace node. It is an error to add a namespace node to an element after children have been added to it or after attributes have been added to it; implementations may either signal an error or ignore the namespace node. It is an error to add a namespace node to an element if the element already has a namespace node with the same name, unless both namespace nodes have the same string-value, in which case the duplicate is ignored. It is an error to add a namespace node to an element if the namespace node has a null name and the element has a null namespace URI.
Question:
1. (Filter) What happens when a namespace is copied to an element after children have been added to it?
Valid choices: ignore, raise-error
Specification citations (manual):
Specification citations (machine):
When the first argument to the document function is not a node-set, the first argument is converted to a string as if by a call to the string function. This string is treated as a URI reference; the resource identified by the URI is retrieved. The data resulting from the retrieval action is parsed as an XML document and a tree is constructed in accordance with the data model (see 3 Data Model). If there is an error retrieving the resource, then the XSLT processor may signal an error; if it does not signal an error, it must recover by returning an empty node-set. One possible kind of retrieval error is that the XSLT processor does not support the URI scheme used by the URI. An XSLT processor is not required to support any particular URI schemes. The documentation for an XSLT processor should specify which URI schemes the XSLT processor supports.
Question:
1. (Filter) What happens when there is an error retreiving the resouce identified by a URI in an argument to the document function?
Valid choices: return-empty, raise-error
Specification citations (manual):
Specification citations (machine):
If the URI reference does not contain a fragment identifier, then a node-set containing just the root node of the document is returned. If the URI reference does contain a fragment identifier, the function returns a node-set containing the nodes in the tree identified by the fragment identifier of the URI reference. The semantics of the fragment identifier is dependent on the media type of the result of retrieving the URI. If there is an error in processing the fragment identifier, the XSLT processor may signal the error; if it does not signal the error, it must recover by returning an empty node-set. Possible errors include:
Question:
1. (Filter) What-happens when there is an error processing the fragment identifier in a URI in an argument to the document function?
Valid choices: return-empty, raise-error
Specification citations (manual):
Specification citations (machine):
The URI reference may be relative. The base URI (see [3.2 Base URI]) of the node in the second argument node-set that is first in document order is used as the base URI for resolving the relative URI into an absolute URI. It is an error if the second argument node-set is empty and the URI reference is relative; the XSLT processor may signal the error; if it does not signal an error, it must recover by returning an empty node-set.
Question:
1. (Filter) What happens when the two arguments to the document() function do not enable resolution of a relative URI reference?
Valid choices: return-empty, raise-error
Specification citations (manual):
Specification citations (machine):
A stylesheet may contain multiple xsl:output elements and may include or import stylesheets that also contain xsl:output elements. All the xsl:output elements occurring in a stylesheet are merged into a single effective xsl:output element. For the cdata-section-elements attribute, the effective value is the union of the specified values. For other attributes, the effective value is the specified value with the highest import precedence. It is an error if there is more than one such value for an attribute. An XSLT processor may signal the error; if it does not signal the error, if should recover by using the value that occurs last in the stylesheet. The values of attributes are defaulted after the xsl:output elements have been merged; different output methods may have different default values for an attribute.
Question:
1. (Filter) What happens when there is more than one instantiation of the same attribute on multiple xsl:output elements that share the highest import precedence?
Valid choices: choose-last, raise-error
Specification citations (manual):
Specification citations (machine):
The encoding attribute specifies the preferred encoding to use for outputting the result tree. XSLT processors are required to respect values of UTF-8 and UTF-16. For other values, if the XSLT processor does not support the specified encoding it may signal an error; if it does not signal an error it should use UTF-8 or UTF-16 instead . The XSLT processor must not use an encoding whose name does not match the EncName production of the XML Recommendation . If no encoding attribute is specified, then the XSLT processor should use either UTF-8 or UTF-16. It is possible that the result tree will contain a character that cannot be represented in the encoding that the XSLT processor is using for output. In this case, if the character occurs in a context where XML recognizes character references (i.e. in the value of an attribute node or text node), then the character should be output as a character reference; otherwise (for example if the character occurs in the name of an element) the XSLT processor should signal an error.
Question:
1. (Filter) Is an error raised when the encoding attribute of the xsl:output element specifies an unsupported encoding?
Valid choices: yes, no
Interlock: Cannot answer "yes" to more than one of 'unsupported-encoding-error', 'unsupported-encoding-UTF-8', 'unsupported-encoding-UTF-16'. Answering, "no" to all is allowed, in which case please ELABORATE on what encoding is used.
Specification citations (manual):
Specification citations (machine):
The encoding attribute specifies the preferred encoding to use for outputting the result tree. XSLT processors are required to respect values of UTF-8 and UTF-16. For other values, if the XSLT processor does not support the specified encoding it may signal an error; if it does not signal an error it should use UTF-8 or UTF-16 instead . The XSLT processor must not use an encoding whose name does not match the EncName production of the XML Recommendation . If no encoding attribute is specified, then the XSLT processor should use either UTF-8 or UTF-16. It is possible that the result tree will contain a character that cannot be represented in the encoding that the XSLT processor is using for output. In this case, if the character occurs in a context where XML recognizes character references (i.e. in the value of an attribute node or text node), then the character should be output as a character reference; otherwise (for example if the character occurs in the name of an element) the XSLT processor should signal an error.
Question:
1. (Filter) Is UTF-8 encoding always used when the encoding attribute of the xsl:output element specifies an unsupported encoding?
Valid choices: yes, no
Interlock: Cannot answer "yes" to more than one of 'unsupported-encoding-error', 'unsupported-encoding-UTF-8', 'unsupported-encoding-UTF-16'. Answering, "no" to all is allowed, in which case please ELABORATE on what encoding is used.
Specification citations (manual):
Specification citations (machine):
The encoding attribute specifies the preferred encoding to use for outputting the result tree. XSLT processors are required to respect values of UTF-8 and UTF-16. For other values, if the XSLT processor does not support the specified encoding it may signal an error; if it does not signal an error it should use UTF-8 or UTF-16 instead . The XSLT processor must not use an encoding whose name does not match the EncName production of the XML Recommendation . If no encoding attribute is specified, then the XSLT processor should use either UTF-8 or UTF-16. It is possible that the result tree will contain a character that cannot be represented in the encoding that the XSLT processor is using for output. In this case, if the character occurs in a context where XML recognizes character references (i.e. in the value of an attribute node or text node), then the character should be output as a character reference; otherwise (for example if the character occurs in the name of an element) the XSLT processor should signal an error.
Question:
1. (Filter) Is UTF-16 encoding always used when the encoding attribute of the xsl:output element specifies an unsupported encoding?
Valid choices: yes, no
Interlock: Cannot answer "yes" to more than one of 'unsupported-encoding-error', 'unsupported-encoding-UTF-8', 'unsupported-encoding-UTF-16'. Answering, "no" to all is allowed, in which case please ELABORATE on what encoding is used.
Specification citations (manual):
Specification citations (machine):
The encoding attribute specifies the preferred encoding to use for outputting the result tree. XSLT processors are required to respect values of UTF-8 and UTF-16. For other values, if the XSLT processor does not support the specified encoding it may signal an error; if it does not signal an error it should use UTF-8 or UTF-16 instead. The XSLT processor must not use an encoding whose name does not match the EncName production of the XML Recommendation . If no encoding attribute is specified, then the XSLT processor should use either UTF-8 or UTF-16 . It is possible that the result tree will contain a character that cannot be represented in the encoding that the XSLT processor is using for output. In this case, if the character occurs in a context where XML recognizes character references (i.e. in the value of an attribute node or text node), then the character should be output as a character reference; otherwise (for example if the character occurs in the name of an element) the XSLT processor should signal an error.
Question:
1. (Filter) Is UTF-8 encoding used by default?
Valid choices: yes, no
Interlock: Cannot answer "yes" to both 'default-encoding-UTF-8'and 'default-encoding-UTF-16'. Answering "no" to both is allowed, in which case please ELABORATE on what encoding is used.
Specification citations (manual):
Specification citations (machine):
The encoding attribute specifies the preferred encoding to use for outputting the result tree. XSLT processors are required to respect values of UTF-8 and UTF-16. For other values, if the XSLT processor does not support the specified encoding it may signal an error; if it does not signal an error it should use UTF-8 or UTF-16 instead. The XSLT processor must not use an encoding whose name does not match the EncName production of the XML Recommendation . If no encoding attribute is specified, then the XSLT processor should use either UTF-8 or UTF-16 . It is possible that the result tree will contain a character that cannot be represented in the encoding that the XSLT processor is using for output. In this case, if the character occurs in a context where XML recognizes character references (i.e. in the value of an attribute node or text node), then the character should be output as a character reference; otherwise (for example if the character occurs in the name of an element) the XSLT processor should signal an error.
Question:
1. (Filter) Is UTF-16 encoding used by default?
Valid choices: yes, no
Interlock: Cannot answer "yes" to both 'default-encoding-UTF-8'and 'default-encoding-UTF-16'. Answering "no" to both is allowed, in which case please ELABORATE on what encoding is used.
Specification citations (manual):
Specification citations (machine):
An XSLT processor will only be able to disable output escaping if it controls how the result tree is output. This may not always be the case. For example, the result tree may be used as the source tree for another XSLT transformation instead of being output. An XSLT processor is not required to support disabling output escaping. If an xsl:value-of or xsl:text specifies that output escaping should be disabled and the XSLT processor does not support this, the XSLT processor may signal an error; if it does not signal an error, it must recover by not disabling output escaping.
Question:
1. (Filter) Does the processor support disabling output escaping?
Valid choices: yes, no
Interlock: Answering "yes" to 'support-disable-output-escaping' renders 'unsupported-disabled-output-escaping' moot.
Interlock: Answering "no" to 'support-disable-output-escaping' renders 'non-text-disabled-output-escaping' and 'unrepresented-character-disabled-output-escaping' moot.
Specification citations (manual):
Specification citations (machine):
An XSLT processor will only be able to disable output escaping if it controls how the result tree is output. This may not always be the case. For example, the result tree may be used as the source tree for another XSLT transformation instead of being output. An XSLT processor is not required to support disabling output escaping. If an xsl:value-of or xsl:text specifies that output escaping should be disabled and the XSLT processor does not support this, the XSLT processor may signal an error; if it does not signal an error, it must recover by not disabling output escaping.
Question:
1. (Filter) What happens when disabling output escaping of an xsl:value-of or xsl:text element is specified but disabling of output escaping is unsupported?
Valid choices: ignore, raise-error, moot
Interlock: Answering "yes" to 'support-disable-output-escaping' renders 'unsupported-disabled-output-escaping' moot.
Specification citations (manual):
Specification citations (machine):
It is an error for output escaping to be disabled for a text node that is used for something other than a text node in the result tree. Thus, it is an error to disable output escaping for an xsl:value-of or xsl:text element that is used to generate the string-value of a comment, processing instruction or attribute node; it is also an error to convert a result tree fragment to a number or a string if the result tree fragment contains a text node for which escaping was disabled. In both cases, an XSLT processor may signal the error; if it does not signal the error, it must recover by ignoring the disable-output-escaping attribute .
Question:
1. (Filter) What happens when output escaping is disabled for a text node that is used for something other than a text node in the result tree?
Valid choices: ignore, raise-error, moot
Interlock: Answering "no" to 'support-disable-output-escaping' renders 'non-text-disabled-output-escaping' and 'unrepresented-character-disabled-output-escaping' moot.
Interlock: Compare to 'converted-RTF-disabled-output-escaping' to 'non-text-disabled-output-escaping'. Separate option?
Specification citations (manual):
Specification citations (machine):
If output escaping is disabled for a character that is not representable in the encoding that the XSLT processor is using for output, then the XSLT processor may signal an error; if it does not signal an error, it must recover by not disabling output escaping.
Question:
1. (Filter) What happens when output escaping is disabled for a character that is not representable in the encoding used for output?
Valid choices: ignore, raise-error, moot
Interlock: Answering "no" to 'support-disable-output-escaping' renders 'non-text-disabled-output-escaping' and 'unrepresented-character-disabled-output-escaping' moot.
Specification citations (manual):
Specification citations (machine):
The root node has a mapping that gives the URI for each unparsed entity declared in the document's DTD. The URI is generated from the system identifier and public identifier specified in the entity declaration. The XSLT processor may use the public identifier to generate a URI for the entity instead of the URI specified in the system identifier. If the XSLT processor does not use the public identifier to generate the URI, it must use the system identifier; if the system identifier is a relative URI, it must be resolved into an absolute URI using the URI of the resource containing the entity declaration as the base URI .
Question:
1. (Filter) Is the public identifier of an unparsed entity, when present, used to generate the URI for the entity instead of the URI specified in the system identifier?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
The following items represent statements in the XSLT and XPath Recommendations that identify discretionary behavior that is proposed to postpone, usually until a "core" test suite is shipped. Language-concerned items will be added as soon as we have language-specific tests submitted. Each item should be reviewed and voted by committee.
Expandable: convert-number-[language]
It is possible for two conforming XSLT processors not to convert a number to exactly the same string. Some XSLT processors may not support some languages. Furthermore, there may be variations possible in the way conversions are performed for any particular language that are not specifiable by the attributes on xsl:number. Future versions of XSLT may provide additional attributes to provide control over these variations. Implementations may also use implementation-specific namespaced attributes on xsl:number for this.
Questions:
1. (Filter) Is the English language supported for xsl:number?
2. (Prototype) For each language in test suite: Is _____ language supported for xsl:number?
3. (Prototype) For some specific languages: ELABORATE: which number conversion basis is chosen?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
Expandable: sort-[language]
It is possible for two conforming XSLT processors not to sort exactly the same. Some XSLT processors may not support some languages. Furthermore, there may be variations possible in the sorting of any particular language that are not specified by the attributes on xsl:sort, for example, whether Hiragana or Katakana is sorted first in Japanese. Future versions of XSLT may provide additional attributes to provide control over these variations. Implementations may also use implementation-specific namespaced attributes on xsl:sort for this.
Questions:
1. (Filter) Is the English language supported for xsl:sort?
2. (Prototype) For each language in test suite: Is _____ language supported for xsl:sort?
3. (Prototype) For some specific languages: ELABORATE: which sorting algorithm is chosen?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
Both xsl:variable and xsl:param are allowed as top-level elements. A top-level variable-binding element declares a global variable that is visible everywhere. A top-level xsl:param element declares a parameter to the stylesheet; XSLT does not define the mechanism by which parameters are passed to the stylesheet. It is an error if a stylesheet contains more than one binding of a top-level variable with the same name and same import precedence. At the top-level, the expression or template specifying the variable value is evaluated with the same context as that used to process the root node of the source document: the current node is the root node of the source document and the current node list is a list containing just the root node of the source document. If the template or expression specifying the value of a global variable x references a global variable y, then the value for y must be computed before the value of x. It is an error if it is impossible to do this for all global variable definitions; in other words, it is an error if the definitions are circular.
Question:
1. (Filter) Is it possible to pass parameters to the stylesheet?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
An XSLT processor may output the result tree as a sequence of bytes, although it is not required to be able to do so (see 17 Conformance ). The xsl:output element allows stylesheet authors to specify how they wish the result tree to be output. If an XSLT processor outputs the result tree, it should do so as specified by the xsl:output element; however, it is not required to do so.
Question:
1. (Filter) Is the result tree able to be output as a sequence of bytes?
Valid choices: yes, no
Interlock: Some xsl:output directives will be moot if 'result-tree-as-bytes' is "no" and the answer to 'obey-xsl-output' should be limited accordingly.
Specification citations (manual):
Specification citations (machine):
An XSLT processor may output the result tree as a sequence of bytes, although it is not required to be able to do so (see 17 Conformance). The xsl:output element allows stylesheet authors to specify how they wish the result tree to be output. If an XSLT processor outputs the result tree, it should do so as specified by the xsl:output element; however, it is not required to do so.
Question:
1. (Configuration) Is the result tree always output as specified by the xsl:output element?
Valid choices: yes, no, moot
Interlock: Some xsl:output directives will be moot if 'result-tree-as-bytes' is "no" and the answer to 'obey-xsl-output' should be limited accordingly.
Specification citations (manual):
Specification citations (machine):
It is an error for output escaping to be disabled for a text node that is used for something other than a text node in the result tree. Thus, it is an error to disable output escaping for an xsl:value-of or xsl:text element that is used to generate the string-value of a comment, processing instruction or attribute node; it is also an error to convert a result tree fragment to a number or a string if the result tree fragment contains a text node for which escaping was disabled. In both cases, an XSLT processor may signal the error; if it does not signal the error, it must recover by ignoring the disable-output-escaping attribute .
Question:
1. (Filter) What happens when output escaping is disabled for a text node that is placed into a result tree fragment (RTF), and the RTF is later converted to a number or string?
Valid choices: ignore, raise-error, moot
Interlock: Compare to 'converted-RTF-disabled-output-escaping' to 'non-text-disabled-output-escaping'. Separate option?
Specification citations (manual):
Specification citations (machine):
The following items represent statements in the XSLT and XPath Recommendations that identify discretionary behaviors that are acknowledged as discretionary but considered as not testable for conformance purposes. However, asking the questions is still reasonable, as it will help test labs configure and use the suite. Any test marked with any of these discretionary items should be excluded from the "conformance" suite, but may be useful to distribute. Each item should be reviewed and voted by the committee.
Implementations may be able to detect such loops in some cases, but the possibility exists that a stylesheet may enter a non-terminating loop that an implementation is unable to detect. This may present a denial of service security risk.
Question:
1. (Configuration) Are there any non-terminating loops that can be detected?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
XSLT processors may make use of the prefix of the QName specified in the name attribute when selecting the prefix used for outputting the created element as XML; however, they are not required to do so.
Question:
1. (Configuration) Is the prefix of the QName specified in the name attribute of xsl:element used as the prefix of the created element, when no conflicting use is in scope?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
XSLT processors may make use of the prefix of the QName specified in the name attribute when selecting the prefix used for outputting the created attribute as XML; however, they are not required to do so and, if the prefix is xmlns, they must not do so. Thus, although it is not an error to do:
Question:
1. (Configuration) Is the prefix of the QName specified in the name attribute of xsl:attribute used as the prefix of the created attribute, when no conflicting use is in scope?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
The document function gives rise to the possibility that a node-set may contain nodes from more than one document. With such a node-set, the relative document order of two nodes in the same document is the normal document order defined by XPath . The relative document order of two nodes in different documents is determined by an implementation-dependent ordering of the documents containing the two nodes. There are no constraints on how the implementation orders documents other than that it must do so consistently: an implementation must always use the same order for the same set of documents.
Question:
1. (Configuration) Is the relative document order of two nodes in different documents formed by taking all elements in the first document before any in the second, and so on?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
The generate-id function returns a string that uniquely identifies the node in the argument node-set that is first in document order. The unique identifier must consist of ASCII alphanumeric characters and must start with an alphabetic character. Thus, the string is syntactically an XML name. An implementation is free to generate an identifier in any convenient way provided that it always generates the same identifier for the same node and that different identifiers are always generated from different nodes. An implementation is under no obligation to generate the same identifiers each time a document is transformed. There is no guarantee that a generated unique identifier will be distinct from any unique IDs specified in the source document. If the argument node-set is empty, the empty string is returned. If the argument is omitted, it defaults to the context node.
Question:
1. (Configuration) Is there a reproducible pattern for the string generated by the generate-id function?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
The new tree may contain namespace nodes that were not present in the result tree.
Question:
1. (Configuration) Does the XML output ever contain namespace nodes that were not present in the result tree?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
The html output method may output a character using a character entity reference, if one is defined for it in the version of HTML that the output method is using.
Question:
1. (Configuration) Does the html output method output a character using a character entity reference, if one is defined for it in the version of HTML that the output method is using?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
A conforming XSLT processor must signal any errors except for those that this document specifically allows an XSLT processor not to signal. A conforming XSLT processor may but need not recover from any errors that it signals.
Question:
1. ELABORATE: What form of error recovery is performed after any errors are signaled?
No choices available.
Specification citations (manual):
Specification citations (machine):
A conforming XSLT processor may impose limits on the processing resources consumed by the processing of a stylesheet.
Question:
1. (Configuration) Are limits imposed on processing resources consumed by the processing of a stylesheet?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
a QName with a prefix is expanded into an expanded-name as described in 2.4 Qualified Names; the expanded-name identifies the data-type; the behavior in this case is not specified by this document
Question:
1. (Configuration) Does the XSLT processor support any extra data-type for sort?
Valid choices: yes, no
Specification citations (manual):
Specification citations (machine):
The following items represent statements in the XSLT and XPath Recommendations that identify discretionary behavior that is out of scope for XSLT/XPath conformance testing. Items are present here so that the catalog recognizes all possible discretionary behavior.
Since the specification explicitly says that the elements/attributes must not affect the behavior of the XSLT components, the discretionary alternatives (ignore the foreign components or take some XSLT-transparent action directed by the foreign components) do not serve to control exclusion of test cases.
The verbiage about setting attribute values specified externally as default is mainly a warning to stylesheet writers (if you depend on default values being inserted by validation, your stylesheet may not work in some scenarios) rather than a grant of discretion to the developer. More precisely, a developer of a monolithic parser/styler has discretion to not validate, but that applies to the parsing phase rather than the transformation phase.
An element from the XSLT namespace may have any attribute not from the XSLT namespace, provided that the expanded-name of the attribute has a non-null namespace URI. The presence of such attributes must not change the behavior of XSLT elements and functions defined in this document. Thus, an XSLT processor is always free to ignore such attributes, and must ignore such attributes without giving an error if it does not recognize the namespace URI . Such attributes can provide, for example, unique identifiers, optimization hints, or documentation.
No choices available.
Specification citations (manual):
Specification citations (machine):
In addition, the xsl:stylesheet element may contain any element not from the XSLT namespace, provided that the expanded-name of the element has a non-null namespace URI. The presence of such top-level elements must not change the behavior of XSLT elements and functions defined in this document; for example, it would not be permitted for such a top-level element to specify that xsl:apply-templates was to use different rules to resolve conflicts. Thus, an XSLT processor is always free to ignore such top-level elements, and must ignore a top-level element without giving an error if it does not recognize the namespace URI . Such elements can provide, for example,
No choices available.
Specification citations (manual):
Specification citations (machine):
It is possible for default attributes to be declared in an external DTD or an external parameter entity. The XML Recommendation does not require an XML processor to read an external DTD or an external parameter unless it is validating. A stylesheet or other facility that assumes that the XPath tree contains default attribute values declared in an external DTD or parameter entity may not work with some non-validating XML processors.
No choices available.
Specification citations (manual):
Specification citations (machine):
2000-07-06:
Initial revision.
2000-08-08:
Added discretionary non-error aspects identified by David Marston. Removed emphasis on only reporting discretionary error handling. Other cosmetic fixes.
2001-01-08:
Created and populated "Untestable or Out of Scope Discretionary Behavior" section. Added change history. Split "disc-result-tree-as-bytes" to create "disc-obey-xsl-output".
2001-01-26:
Splitted all discretionary items into 4 categories: "testable", "not testable", "postponed" and "out of scope". Split "disc-sort" and "disc-convert-number" into language specific questions .
2001-01-29:
Adjusted some verbiage. Added disc-default-encoding, distinct from discretion surrounding requested encoding that is unsupported. Split the UTF-8 and UTF-16 encoding cases. Fixed a couple references and anchors. Clarified that language-specific questions are shown in template form only.
2001-03-29:
Changed item names, per subcommittee decision. Expressed questions in keyword-answer style, which makes catalog more readable. Added union list of keywords for answers. Added INTERLOCK flags. Added EXPANDABLE flags and patterns. Added ELABORATE flags.
Clarified questions regarding disable-output-escaping. Further clarified UTF-8/UTF-16 encoding items. Clarified questions regarding QNames in created elements and attributes. Instantiated English versions of xsl:number and xsl:sort language questions. Added questions from 12/12/2000 errata.
Moved xpath-default-attribute to out-of-scope, per subcommittee decision.
2001-04-13:
Added converted-RTF-disabled-output-escaping as a potential split-off from non-text-disabled-output-escaping. Added yes/no and ELABORATE verbiage where context required it.
2001-05-09 14:00:
Recast document in XML from HTML
2001-07-09 13:00:
Flattened out item space so all are children of <items> and status is an attribute. Added structure: spec-citations and readable-cites, mootable flag, elaborators for items, scope of questions.
2001-07-21 01:30:
Revamped citations to consistent model across all documents. Abbreviated XPointer values to nearest ancestral id (when available). Changed readable citations to spec citations of type 'Section'.