The test on-empty-115b constructs a namespace node whose string value (the namespace URI) consists of a single space character.
I can't find an explicit rule against it, but the QT specs do assume that a namespace name will be an xs:anyURI (see for example the return type of functions such as namespace-url()), and XSD 1.1 part 2 does say, for xs:anyURI
Note: Spaces are, in principle, allowed in the ·lexical space· of anyURI, however, their use is highly discouraged (unless they are encoded by '%20').
It also says that xs:anyURI has whitespace=collapse, which under normal circumstances would mean that the values "" (zero-length string) and " " (single space) are considered equivalent. But I think it's unlikely that XML parsers will treat xmlns=" " as equivalent to xmlns="".
If a single space as a namespace URI is expected to work, then this puts considerable stress on the whole system. In the absence of a WG to adjudicate how this should be handled, I think it's best for the test to dodge this question.
I've changed the test to accept a wider range of possible results (not, at present, including the possibility of raising an error, which could possibly be justified).
The test on-empty-115b constructs a namespace node whose string value (the namespace URI) consists of a single space character.
I can't find an explicit rule against it, but the QT specs do assume that a namespace name will be an xs:anyURI (see for example the return type of functions such as namespace-url()), and XSD 1.1 part 2 does say, for xs:anyURI
It also says that xs:anyURI has whitespace=collapse, which under normal circumstances would mean that the values "" (zero-length string) and " " (single space) are considered equivalent. But I think it's unlikely that XML parsers will treat
xmlns=" "
as equivalent toxmlns=""
.If a single space as a namespace URI is expected to work, then this puts considerable stress on the whole system. In the absence of a WG to adjudicate how this should be handled, I think it's best for the test to dodge this question.