[webkit-changes] cvs commit: WebCore/layout-tests/fast/dom no-elements-expected.txt no-elements.html

David harrison at opensource.apple.com
Fri Aug 19 16:58:29 PDT 2005


harrison    05/08/19 16:58:29

  Modified:    .        ChangeLog
               khtml/html html_elementimpl.cpp htmlparser.cpp
               layout-tests/dom/html/level2/html
                        HTMLElement113-expected.txt
                        HTMLElement114-expected.txt
                        HTMLElement142-expected.txt
                        HTMLElement143-expected.txt
                        HTMLElement26-expected.txt
                        HTMLElement27-expected.txt
                        HTMLElement55-expected.txt
                        HTMLElement56-expected.txt
                        HTMLElement84-expected.txt
                        HTMLElement85-expected.txt
  Added:       layout-tests/fast/dom no-elements-expected.txt
                        no-elements.html
  Log:
          Reviewed by Darin.
          Landed by David Harrison.
  
          - fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=4475
            <noscript>, <noframes>, <nolayer> and <noembed> elements should be in the DOM
  
          Test cases added:
          * layout-tests/fast/dom/no-elements-expected.txt: Added.
          * layout-tests/fast/dom/no-elements.html: Added.
  
          * khtml/html/html_elementimpl.cpp:
          (blockTagList):
          Add noembed and nolayer to the list of block tags.
  
          * khtml/html/htmlparser.cpp:
          (HTMLParser::noembedCreateErrorCheck):
          (HTMLParser::noframesCreateErrorCheck):
          (HTMLParser::noscriptCreateErrorCheck):
          (HTMLParser::nolayerCreateErrorCheck):
          Make sure these elements are created, but that they won't have any children.
          (Except for <noscript> when JavaScript is turned off).
  
          * layout-tests/dom/html/level2/html/HTMLElement113-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement114-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement142-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement143-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement26-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement27-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement55-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement56-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement84-expected.txt:
          * layout-tests/dom/html/level2/html/HTMLElement85-expected.txt:
          These tests pass now.
  
  Revision  Changes    Path
  1.4608    +38 -1     WebCore/ChangeLog
  
  Index: ChangeLog
  ===================================================================
  RCS file: /cvs/root/WebCore/ChangeLog,v
  retrieving revision 1.4607
  retrieving revision 1.4608
  diff -u -r1.4607 -r1.4608
  --- ChangeLog	19 Aug 2005 23:38:33 -0000	1.4607
  +++ ChangeLog	19 Aug 2005 23:58:22 -0000	1.4608
  @@ -1,10 +1,47 @@
  +2005-08-19  Anders Carlsson  <andersca at mac.com>
  +
  +        Reviewed by Darin.
  +        Landed by David Harrison.
  +
  +        - fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=4475
  +          <noscript>, <noframes>, <nolayer> and <noembed> elements should be in the DOM
  +
  +        Test cases added:
  +        * layout-tests/fast/dom/no-elements-expected.txt: Added.
  +        * layout-tests/fast/dom/no-elements.html: Added.
  +
  +        * khtml/html/html_elementimpl.cpp:
  +        (blockTagList):
  +        Add noembed and nolayer to the list of block tags.
  +        
  +        * khtml/html/htmlparser.cpp:
  +        (HTMLParser::noembedCreateErrorCheck):
  +        (HTMLParser::noframesCreateErrorCheck):
  +        (HTMLParser::noscriptCreateErrorCheck):
  +        (HTMLParser::nolayerCreateErrorCheck):
  +        Make sure these elements are created, but that they won't have any children.
  +        (Except for <noscript> when JavaScript is turned off).
  +        
  +        * layout-tests/dom/html/level2/html/HTMLElement113-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement114-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement142-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement143-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement26-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement27-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement55-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement56-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement84-expected.txt:
  +        * layout-tests/dom/html/level2/html/HTMLElement85-expected.txt:
  +        These tests pass now.
  +
   2005-08-19  Darin Adler  <darin at apple.com>
   
           Reviewed by Maciej.
           Landed by David Harrison.
           
  -        Test cases added: Manual test because Darin saw no way to exercise the hit testing code from JavaScript.
  +        Test cases added:
   	manual-tests/onclick_in_noncontent.html: Added.
  +        (a manual test because Darin saw no way to exercise the hit testing code from JavaScript)
   
           - fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=3662
             onClick event for TD element doesn't fire unless its contents are clicked
  
  
  
  1.96      +2 -0      WebCore/khtml/html/html_elementimpl.cpp
  
  Index: html_elementimpl.cpp
  ===================================================================
  RCS file: /cvs/root/WebCore/khtml/html/html_elementimpl.cpp,v
  retrieving revision 1.95
  retrieving revision 1.96
  diff -u -r1.95 -r1.96
  --- html_elementimpl.cpp	19 Aug 2005 16:27:00 -0000	1.95
  +++ html_elementimpl.cpp	19 Aug 2005 23:58:26 -0000	1.96
  @@ -884,6 +884,8 @@
           tagList.insert(centerTag.localName().implementation());
           tagList.insert(noscriptTag.localName().implementation());
           tagList.insert(noframesTag.localName().implementation());
  +        tagList.insert(noembedTag.localName().implementation());
  +        tagList.insert(nolayerTag.localName().implementation());
           tagList.insert(blockquoteTag.localName().implementation());
           tagList.insert(formTag.localName().implementation());
           tagList.insert(isindexTag.localName().implementation());
  
  
  
  1.103     +5 -4      WebCore/khtml/html/htmlparser.cpp
  
  Index: htmlparser.cpp
  ===================================================================
  RCS file: /cvs/root/WebCore/khtml/html/htmlparser.cpp,v
  retrieving revision 1.102
  retrieving revision 1.103
  diff -u -r1.102 -r1.103
  --- htmlparser.cpp	5 Aug 2005 20:47:35 -0000	1.102
  +++ htmlparser.cpp	19 Aug 2005 23:58:27 -0000	1.103
  @@ -742,25 +742,26 @@
   bool HTMLParser::noembedCreateErrorCheck(Token* t, NodeImpl*& result)
   {
       setSkipMode(noembedTag);
  -    return false;
  +    return true;
   }
   
   bool HTMLParser::noframesCreateErrorCheck(Token* t, NodeImpl*& result)
   {
       setSkipMode(noframesTag);
  -    return false;
  +    return true;
   }
   
   bool HTMLParser::noscriptCreateErrorCheck(Token* t, NodeImpl*& result)
   {
       if (HTMLWidget && HTMLWidget->part()->jScriptEnabled())
           setSkipMode(noscriptTag);
  -    return false;
  +    return true;
   }
   
   bool HTMLParser::nolayerCreateErrorCheck(Token* t, NodeImpl*& result)
   {
  -    return false;
  +    setSkipMode(nolayerTag);
  +    return true;
   }
   
   NodeImpl *HTMLParser::getNode(Token* t)
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement113-expected.txt
  
  Index: HTMLElement113-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement113-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement113-expected.txt	26 Jul 2005 08:35:29 -0000	1.1
  +++ HTMLElement113-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement113	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement113
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement114-expected.txt
  
  Index: HTMLElement114-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement114-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement114-expected.txt	26 Jul 2005 08:35:29 -0000	1.1
  +++ HTMLElement114-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement114	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement114
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement142-expected.txt
  
  Index: HTMLElement142-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement142-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement142-expected.txt	26 Jul 2005 08:35:31 -0000	1.1
  +++ HTMLElement142-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement142	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement142
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement143-expected.txt
  
  Index: HTMLElement143-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement143-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement143-expected.txt	26 Jul 2005 08:35:31 -0000	1.1
  +++ HTMLElement143-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement143	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement143
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement26-expected.txt
  
  Index: HTMLElement26-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement26-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement26-expected.txt	26 Jul 2005 08:35:32 -0000	1.1
  +++ HTMLElement26-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement26	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement26
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement27-expected.txt
  
  Index: HTMLElement27-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement27-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement27-expected.txt	26 Jul 2005 08:35:32 -0000	1.1
  +++ HTMLElement27-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement27	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement27
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement55-expected.txt
  
  Index: HTMLElement55-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement55-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement55-expected.txt	26 Jul 2005 08:35:34 -0000	1.1
  +++ HTMLElement55-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement55	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement55
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement56-expected.txt
  
  Index: HTMLElement56-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement56-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement56-expected.txt	26 Jul 2005 08:35:34 -0000	1.1
  +++ HTMLElement56-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement56	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement56
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement84-expected.txt
  
  Index: HTMLElement84-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement84-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement84-expected.txt	26 Jul 2005 08:35:35 -0000	1.1
  +++ HTMLElement84-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement84	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement84
  +Status:	Success
  
  
  
  1.2       +2 -3      WebCore/layout-tests/dom/html/level2/html/HTMLElement85-expected.txt
  
  Index: HTMLElement85-expected.txt
  ===================================================================
  RCS file: /cvs/root/WebCore/layout-tests/dom/html/level2/html/HTMLElement85-expected.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HTMLElement85-expected.txt	26 Jul 2005 08:35:35 -0000	1.1
  +++ HTMLElement85-expected.txt	19 Aug 2005 23:58:27 -0000	1.2
  @@ -1,3 +1,2 @@
  -Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement85	
  -Status:	failure
  -Detail:	Asize: assertEquals failed, actual 0, expected 1.
  +Test:	http://www.w3.org/2001/DOM-Test-Suite/level2/html/HTMLElement85
  +Status:	Success
  
  
  
  1.1                  WebCore/layout-tests/fast/dom/no-elements-expected.txt
  
  Index: no-elements-expected.txt
  ===================================================================
  This tests that the elements noframes, nolayer, noscript and noembed are created as elements and put in the DOM tree. The elements should not contain any children. If the test is successful, the text "Success" will be seen below.
  Success
  
  
  
  
  1.1                  WebCore/layout-tests/fast/dom/no-elements.html
  
  Index: no-elements.html
  ===================================================================
  <html>
  <head>
  <style>
  </style>
  <script>
  function debug(str) {
  	li = document.createElement('li');
  	li.appendChild(document.createTextNode(str));
  	document.getElementById('console').appendChild(li);
  }
  
  function checkElement(id) {
  	t = document.getElementById(id);
  	
  	if (t == null)
  		return false;
  		
  	if (t.firstChild != null)
  		return false;
  		
  	return true;
  }
  
  function runTests() {
  	if (window.layoutTestController)
  		layoutTestController.dumpAsText();
  		
  	if (!checkElement('noframes') ||
  		!checkElement('nolayer') ||
  		!checkElement('noscript') ||
  		!checkElement('noembed')) 
  		debug("Failure");
  	else
  		debug("Success");
  }
  
  </script>
  </head>
  <body onload="runTests()">
  This tests that the elements noframes, nolayer, noscript and noembed are created as elements and put in the DOM tree. The elements should not contain any children. If the test is successful, the text "Success" will be seen below.
  <noframes id="noframes">This is noframes</noframes>
  <nolayer id="nolayer">This is nolayer</nolayer>
  <noscript id="noscript">This is noscript</noscript>
  <noembed id="noembed">This is noembed</noembed>
  <ul id="console">
  </ul>
  </body>
  </html>
  
  
  



More information about the webkit-changes mailing list