<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>16747</bug_id>
          
          <creation_ts>2008-01-05 14:08:25 -0800</creation_ts>
          <short_desc>Acid3 expects NodeWalker.currentNode to equal start node after creation</short_desc>
          <delta_ts>2019-02-06 09:02:39 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>DOM</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.4</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>17064</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Eric Seidel (no email)">eric</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>cdumez</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>66300</commentid>
    <comment_count>0</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2008-01-05 14:08:25 -0800</bug_when>
    <thetext>Acid3 expects NodeWalker.currentNode to equal start node after creation

Our NodeWalker implementation might just be totally broken.

    function () {
      // test 9: ignoring whitespace text nodes with tree walkers
      var count = 0;
      var expect = function(node1, node2) {
        count += 1;
        assert(node1 == node2, &quot;expectation &quot; + count + &quot; failed&quot;);
      };
      var allButWS = function (node) {
        if (node.nodeType == 3 &amp;&amp; node.data.match(/^\s*$/))
          return false;
        return true;
      };
      var w = document.createTreeWalker(document.body, 0x01 | 0x04 | 0x08 | 0x10 | 0x20, allButWS, true);
      expect(w.currentNode, document.body);
      expect(w.parentNode(), null);
      expect(w.currentNode, document.body);
      expect(w.firstChild(), document.getElementsByTagName(&apos;h1&apos;)[0]);
      expect(w.firstChild().nodeType, 3);
      expect(w.parentNode(), document.getElementsByTagName(&apos;h1&apos;)[0]);
      expect(w.nextSibling().previousSibling.nodeType, 3);
      expect(w.nextSibling(), document.getElementsByTagName(&apos;p&apos;)[6]);
      expect(w.nextSibling(), document.getElementsByTagName(&apos;map&apos;)[0]);
      expect(w.lastChild(), document.getElementsByTagName(&apos;table&apos;)[0]);
      expect(w.lastChild(), document.getElementsByTagName(&apos;tbody&apos;)[0]);
      expect(w.nextNode(), document.getElementsByTagName(&apos;tr&apos;)[0]);
      expect(w.nextNode(), document.getElementsByTagName(&apos;td&apos;)[0]);
      expect(w.nextNode(), document.getElementsByTagName(&apos;p&apos;)[7]);
      expect(w.nextNode(), document.getElementsByTagName(&apos;p&apos;)[8]);
      expect(w.previousSibling(), document.getElementsByTagName(&apos;map&apos;)[0]);
      expect(w.previousNode(), document.getElementsByTagName(&apos;p&apos;)[6]);
      expect(w.parentNode(), document.body);
      expect(w.lastChild().id, &quot;instructions&quot;);
      expect(w.lastChild().data.substr(0,1), &quot;.&quot;);
      expect(w.previousNode(), document.links[0].firstChild);
      return 1;
    },</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66322</commentid>
    <comment_count>1</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2008-01-05 15:59:23 -0800</bug_when>
    <thetext>See also: bug 3492.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1502817</commentid>
    <comment_count>2</comment_count>
    <who name="Lucas Forschler">lforschler</who>
    <bug_when>2019-02-06 09:02:39 -0800</bug_when>
    <thetext>Mass moving XML DOM bugs to the &quot;DOM&quot; Component.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>