Bug 789315, fix the ordering of expected MutationRecords, r=jdm
authorOlli Pettay <Olli.Pettay@helsinki.fi>
Thu, 26 Nov 2015 22:37:00 +0200
changeset 311674 d5be1774b0badd1a6def3a5c8a2e0c6c99128a6e
parent 311673 2fa7dd926187b890c08f8737de58c5b22e219da6
child 311675 ff34a06cb439e6988e91cc78f3999e8012b7f835
push id7905
push userrocallahan@mozilla.com
push dateFri, 27 Nov 2015 08:10:53 +0000
reviewersjdm
bugs789315
milestone45.0a1
Bug 789315, fix the ordering of expected MutationRecords, r=jdm
testing/web-platform/tests/dom/nodes/MutationObserver-document.html
--- a/testing/web-platform/tests/dom/nodes/MutationObserver-document.html
+++ b/testing/web-platform/tests/dom/nodes/MutationObserver-document.html
@@ -44,29 +44,29 @@
                          }}]);
         });
     } else if (testCounter == 2) {
       insertionTest2.step(
         function () {
           checkRecords(document, sequence,
                        [{type: "childList",
                          addedNodes: function () {
+                           return [ document.getElementById("inserted_script") ];
+                         },
+                         target: function () {
+                          return document.getElementById("n00");
+                         }},
+                        {type: "childList",
+                         addedNodes: function () {
                            return [ document.getElementById("inserted_element") ];
                          },
                          previousSibling: function () {
                            return document.getElementById("s002");
                          },
-                         target: document.body},
-                        {type: "childList",
-                         addedNodes: function () {
-                           return [ document.getElementById("inserted_script") ];
-                         },
-                         target: function () {
-                          return document.getElementById("n00");
-                         }}
+                         target: document.body}
                         ]);
         });
     }
   }
   var document_observer;
   var newElement;
   setupTest.step(function() {
     document_observer = new MutationObserver(masterMO);