This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 239 - hasFeature("Core", "1.0") and isSupported("Core", "1.0")
Summary: hasFeature("Core", "1.0") and isSupported("Core", "1.0")
Status: RESOLVED FIXED
Alias: None
Product: DOM TS
Classification: Unclassified
Component: DOM Level 2 (show other bugs)
Version: unspecified
Hardware: Other other
: P2 normal
Target Milestone: ---
Assignee: Curt Arnold
QA Contact:
URL: http://lists.w3.org/Archives/Public/w...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-06-26 01:48 UTC by Curt Arnold
Modified: 2003-12-15 17:50 UTC (History)
0 users

See Also:


Attachments
Remove isSupported03, isSupported08 and modified isSupported12 (26.07 KB, patch)
2003-11-26 17:46 UTC, Curt Arnold
Details
Removes assertion of hasFeature("Core", "1.0") == true (1.05 KB, patch)
2003-12-09 11:57 UTC, Curt Arnold
Details
Removed isSupported("Core", "1.0") from nodeissupported01, 02 (3.35 KB, patch)
2003-12-09 12:45 UTC, Curt Arnold
Details
Fix for level3/core/domimplementationgetfeature01 (1.39 KB, patch)
2003-12-12 14:16 UTC, Andrew Clover
Details
Fix for level3/core/domimplementationgetfeature02 (696 bytes, patch)
2003-12-12 14:19 UTC, Andrew Clover
Details
Fixes for L3 Core domimplementationgetfeature01 and 02 (323.35 KB, patch)
2003-12-15 12:47 UTC, Curt Arnold
Details

Description Curt Arnold 2003-06-26 01:48:09 UTC
Tantek Çelik wrote:

>>Message-ID: <3A92DD77.7C9676BC@w3.org>
>>Date: Tue, 20 Feb 2001 16:11:19 -0500
>>From: Philippe Le Hegaret <plh@w3.org>
>>To: Martijn Pieters <mj@digicool.com>
>>Cc: www-dom@w3.org
>>Subject: Re: DOMImplementation.hasFeature and 'Core', 'XML' and '1.0'.
>>
>>Martijn Pieters wrote:
>>
>>>So, should a DOM level 2 implementation return true on hasFeature('Core',
>>>'1.0) or hasFeature('XML', '1.0')? I *think* it should, but would like to
>>>hear confirmation.
>>
>>The definition of version '1.0' is driven by the DOM Level 1 specification.
>>The DOM Level 2 specification doesn't say anything about
>>hasFeature('Core', '1.0') and I don't think it has to, given that you can't
>>expect a DOM Level 1 implementation to return true.
>>hasFeature('XML', '1.0') must definitively return true for a DOM Level 2
>>implementation since DOM Level 2 is build on top of DOM Level 1.
>>
>>Philippe
>
>
>Redirecting a reply to www-dom-ts since I am raising a DOM 2 Core Test Suite
>issue (in response to a message over two years old!).
>
>I tried searching the archives, and this is the most recent relevant
>reference I could find to the question of whether it is correct for the test
>suite to test hasFeature("Core","1.0").
>
>I don't think the DOM 2 Core Test Suite should be performing that check,
>since no DOM 1 Core implementation could be required to return true for that
>since "Core" wasn't added as a feature flag until DOM 2.
>
>The following tests in the DOM 2 Core Test Suite appear to make that
>assumption however, and thus should be fixed to not expect
>hasFeature("Core","1.0") to return a meaningful value.
>
> isSupported03.html
> isSupported08.html
> isSupported12.html
>
>Thanks,
>
>Tantek
>
>---------------------------------------------------------------------------
>Tantek Çelik                                         tantek@cs.stanford.edu
>Tasman Development Lead, Microsoft Corporation        tantekc@microsoft.com
>Representative to W3C CSS and HTML working groups
>---------------------------------------------------------------------------
>
>
>

http://www.w3.org/TR/DOM-Level-2-Core/Core.html#ID-5CED94D7 has:

version of type DOMString
    This is the version number of the feature to test. In Level 2, the string
can be either "2.0" or "1.0". If the version is not specified, supporting any
version of the feature causes the method to return true.

    This was apparently interpreted by NIST and the Xerces-J team (maybe in
response to a NIST test) that "2.0" and "1.0" should be equivalent.  I do not
know of any definitive WG statement on this issue.
Comment 1 Curt Arnold 2003-11-26 17:46:42 UTC
Created attachment 68 [details]
Remove isSupported03, isSupported08 and modified isSupported12
Comment 2 Curt Arnold 2003-11-26 17:49:16 UTC
Per DOM WG teleconference 26 Nov 2003, tests that assert the return value for
isSupported("Core", "1.0") have been removed.
Comment 3 Andrew Clover 2003-12-09 07:41:22 UTC
domimplementationhasfeature01_Core_2 also makes the same assumption, about
hasFeature rather than isSupported.
Comment 4 Curt Arnold 2003-12-09 11:57:20 UTC
Created attachment 80 [details]
Removes assertion of hasFeature("Core", "1.0") == true
Comment 5 Andrew Clover 2003-12-09 11:58:09 UTC
Oops... and nodeissupported01, nodeissupported02 too!
Comment 6 Curt Arnold 2003-12-09 12:45:38 UTC
Created attachment 82 [details]
Removed isSupported("Core", "1.0") from nodeissupported01, 02
Comment 7 Andrew Clover 2003-12-12 14:16:40 UTC
Created attachment 89 [details]
Fix for level3/core/domimplementationgetfeature01

Another one for you in the new L3 Core tests, domimplementationgetfeature01.
Comment 8 Andrew Clover 2003-12-12 14:19:13 UTC
Created attachment 90 [details]
Fix for level3/core/domimplementationgetfeature02

Also the L3 test domimplementationgetfeature02: this wants (according to the
description text) to check for Core empty-string, but actually passes good old
"1.0" in again.
Comment 9 Curt Arnold 2003-12-15 12:47:53 UTC
Created attachment 102 [details]
Fixes for L3 Core domimplementationgetfeature01 and 02