Bug 30715 - Fails on DOM-Level 3 test attrisid01
Summary: Fails on DOM-Level 3 test attrisid01
Status: RESOLVED DUPLICATE of bug 5578
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P3 Enhancement
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-10-23 08:55 PDT by Chang Shu
Modified: 2019-02-06 09:04 PST (History)
3 users (show)

See Also:


Attachments
fix patch (4.27 KB, patch)
2009-10-23 09:04 PDT, Chang Shu
eric: review-
Details | Formatted Diff | Diff
using existing test cases (4.93 KB, patch)
2009-10-23 12:59 PDT, Chang Shu
ap: review-
ap: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chang Shu 2009-10-23 08:55:44 PDT
Steps to Reproduce:
1. Launch WebKit browser.

2. Open the url
"http://www.w3.org/2004/04/ecmascript/level3/core/alltests.html"

3. Select the test "attrisid01" from the test drop-down list.

4. Click on "LoadJSUNIT" button to run the test

Expected Outcome:
-----------------
The test should pass(i,e Progress bar should displayed in Green color)

Actual Outcome:
---------------
Test fails and progress bar displayed in Red color
Comment 1 Chang Shu 2009-10-23 09:04:28 PDT
Created attachment 41727 [details]
fix patch
Comment 2 Eric Seidel (no email) 2009-10-23 11:22:26 PDT
Comment on attachment 41727 [details]
fix patch

LayoutTests/dom/xhtml/level3/core/attrisid01.xhtml

already exists.  Did you run the layout tests?  I don't think this needs an additional test.  Certainly the results for that test should be updated.
Comment 3 Chang Shu 2009-10-23 11:55:28 PDT
(In reply to comment #2)
> (From update of attachment 41727 [details])
> LayoutTests/dom/xhtml/level3/core/attrisid01.xhtml
> 
> already exists.  Did you run the layout tests?  I don't think this needs an
> additional test.  Certainly the results for that test should be updated.

I didn't notice the test case exists already. I will remove my test case from the patch. However, running on Qt-linux, the existing attrisid test cases must have something wrong. They all passed successfully even without my implementation. To make sure I was doing the right thing, I changed the "assertFalse" to "assertTrue" in attrisid01.js, but the test results are both success. If I ran dumprendertree instead of run-webkit-tests, I could see the isid return value was "undefined", which is right. I guess I need additional effort to make the test case work.
Comment 4 Chang Shu 2009-10-23 12:59:29 PDT
Created attachment 41743 [details]
using existing test cases
Comment 5 Chang Shu 2009-10-23 13:03:34 PDT
(In reply to comment #3)
> (In reply to comment #2)
> > (From update of attachment 41727 [details] [details])
> > LayoutTests/dom/xhtml/level3/core/attrisid01.xhtml
> > 
> > already exists.  Did you run the layout tests?  I don't think this needs an
> > additional test.  Certainly the results for that test should be updated.

I enabled attrisid04 and attrisid05 so all attrisid cases will pass with my patch. However, I still think there is flaw in the test cases based on the fact that attrisid01 etc. cannot tell 'undefined' from 'false'. But these test cases seem to be written by w3c. When I ran these test cases manually on the website, I saw similar problem.
Comment 6 Alexey Proskuryakov 2009-10-23 13:17:52 PDT
(In reply to comment #3)
> However, running on Qt-linux, the existing attrisid test cases must
> have something wrong. They all passed successfully even without my
> implementation.

That may be caused by a different version of framework used for converting generic XML-based DOM tests into a browser-friendly form (looks like assertFalse() is now more strict, and no longer accepts undefined values).

I do not think that we should add a naive isId implementation that just checks for attribute name. Which attribute name is to be an ID is actually defined by DTD, see bug 12971. We also have bug 5578 about adding support for isId() and setIdAttribute().

I think that bug 5578 is the closest thing, so I'll mark this as a duplicate of that bug.

*** This bug has been marked as a duplicate of bug 5578 ***
Comment 7 Lucas Forschler 2019-02-06 09:04:16 PST
Mass moving XML DOM bugs to the "DOM" Component.