W3C home > Mailing lists > Public > public-xml-testsuite@w3.org > February 2004

xml:base attributes in XML test suite driver documents

From: Elliotte Harold <elharo@metalab.unc.edu>
Date: Thu, 12 Feb 2004 20:23:24 -0500
Message-ID: <402C270C.9050700@metalab.unc.edu>
To: public-xml-testsuite@w3.org

I believe there are some bugs in some of the entities that make up 
xmltest.xml (the master list of all the test cases in the XML test 
suite. These are related to unnecessary xml:base attributes. Not all of 
the documents have this problem but some do. One of them (I'll send 
others as I find them) is xmlconf/xmltest/xmltest.xml. This document begins:

<?xml version="1.0" encoding="UTF-8"?>
    @(#)xmltest.xml    1.12 99/02/12
    Copyright 1998-1999 by Sun Microsystems, Inc.
    All Rights Reserved.

<TESTCASES PROFILE="James Clark XMLTEST cases, 18-Nov-1998" 

The problem is the xml:base attribute. This means that this element and 
its descendants have the base URI xmlconf/xmltest/xmltest/ (or 
file:///home/whatever/xmlconf/xmltest/xmltest/ after the relative URL is 
resolved with repsect ot the local file system). That's one too many 
xmltest. Since the document is already in the xmltest directory, no 
xml:base attribute is needed.

The effect is that the relaive URLs found in the various URI attributes 
of TEST elements cannot be resolved relative to the base URI of their 
element, only with repsect to the base URI of the containing entity. 
This is not in keeping with the XML Base specification. This might not 
be noticed if the driver were written using SAX2 or DOM2 or some other 
API that does not take account of xml:base attributtes. It does become 
important when using XOM, JDOM, possibly DOM3, or other more recent APIs 
that do conider xml:base attributes when calculating the base URI.

I suggest that any such xml:base attributes be removed from the test 
suite documents.

Elliotte Rusty Harold
Received on Thursday, 12 February 2004 20:23:31 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 19:44:22 UTC