backout 01a00ce2b662 (Bug 940381) since its mochitest tweaks may make things less robust instead of more robust
authorDaniel Holbert <dholbert@cs.stanford.edu>
Mon, 02 Dec 2013 09:59:38 -0800
changeset 173975 27c14a1b1d4ca47172337cbd4962834ff3227486
parent 173974 07e357311cf304e2b55d78f4af0fa03a05a3e637
child 173976 e5ca4a98aa68301b5b7b0830d7b5ee0ef9ebcf4b
push id445
push userffxbld
push dateMon, 10 Mar 2014 22:05:19 +0000
treeherdermozilla-release@dc38b741b04e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs940381
milestone28.0a1
backs out01a00ce2b662eaa25c505ed882e9d24419349c97
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
backout 01a00ce2b662 (Bug 940381) since its mochitest tweaks may make things less robust instead of more robust
content/svg/content/test/test_bbox.xhtml
content/svg/content/test/test_bounds.html
content/svg/content/test/test_dataTypes.html
content/svg/content/test/test_dataTypesModEvents.html
content/svg/content/test/test_fragments.html
content/svg/content/test/test_getCTM.html
content/svg/content/test/test_getSubStringLength.xhtml
content/svg/content/test/test_scientific.html
content/svg/content/test/test_selectSubString.xhtml
content/svg/content/test/test_switch.xhtml
content/svg/content/test/test_text.html
content/svg/content/test/test_text_scaled.html
content/svg/content/test/test_text_selection.html
content/svg/content/test/test_viewport.html
content/svg/content/test/test_zoom.xhtml
--- a/content/svg/content/test/test_bbox.xhtml
+++ b/content/svg/content/test/test_bbox.xhtml
@@ -60,14 +60,14 @@ function run()
   compareBBox("b", "tspan");
   checkBBox("v", 95, 45, 10, 155, 0.001);
   checkBBox("h", 195, 45, 105, 55, 0.001);
   checkBBox("e", 95, 95, 10, 10, 0.001);
   
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", run, false);
+window.addEventListener("load", run, false);
 
 //]]></script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_bounds.html
+++ b/content/svg/content/test/test_bounds.html
@@ -151,13 +151,13 @@ function runTest()
   is(gBounds.left, 100, "g2.getBoundingClientRect().left");
   is(gBounds.top, 100, "g2.getBoundingClientRect().top");
   is(gBounds.width, 50, "g2.getBoundingClientRect().width");
   is(gBounds.height, 50, "g2.getBoundingClientRect().height");
 
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", runTest, false);
+window.addEventListener("load", runTest, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_dataTypes.html
+++ b/content/svg/content/test/test_dataTypes.html
@@ -370,13 +370,13 @@ function runTests()
 
   SimpleTest.finish();
 }
 
 function runTestsWithPref() {
   SpecialPowers.pushPrefEnv({ 'set': [['svg.marker-improvements.enabled', true]] }, runTests);
 }
 
-$("svg").addEventListener("load", runTestsWithPref, false);
+window.addEventListener("load", runTestsWithPref, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_dataTypesModEvents.html
+++ b/content/svg/content/test/test_dataTypesModEvents.html
@@ -246,13 +246,13 @@ function runTests()
   marker.viewBox.baseVal.x = 1;
   marker.setAttribute("viewBox", "1 2 3 4");
 
   eventChecker.finish();
 
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", runTests, false);
+window.addEventListener("load", runTests, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_fragments.html
+++ b/content/svg/content/test/test_fragments.html
@@ -79,13 +79,13 @@ function runTests()
 
     is(doc.rootElement.getAttribute("zoomAndPan"),
        test.zoomAndPanString, "unexpected zoomAndPan");
   }
 
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", runTests, false);
+window.addEventListener("load", runTests, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_getCTM.html
+++ b/content/svg/content/test/test_getCTM.html
@@ -98,13 +98,13 @@ function runTest()
   is((function(){try{return fO.getScreenCTM().e}catch(e){return e}})(), 16, "symbolRect.getScreenCTM().e");
   is((function(){try{return fO.getScreenCTM().f}catch(e){return e}})(), 29, "symbolRect.getScreenCTM().f");
   // g5.farthestViewportElement == root
   is((function(){try{return g5.getScreenCTM()}catch(e){return e}})(), null, "g5.getScreenCTM()");
 
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", runTest, false);
+window.addEventListener("load", runTest, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_getSubStringLength.xhtml
+++ b/content/svg/content/test/test_getSubStringLength.xhtml
@@ -95,13 +95,13 @@ function run()
   catch (e)
   {
     ok(false, "threw error: " + e);
   }
 
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", run, false);
+window.addEventListener("load", run, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_scientific.html
+++ b/content/svg/content/test/test_scientific.html
@@ -72,13 +72,13 @@ https://bugzilla.mozilla.org/show_bug.cg
 	is(doc.defaultView.getComputedStyle(rect, '').getPropertyValue("stroke-width"), "1px", "No Mantissa");
 
 	rect.setAttribute("stroke-width", "1 e");
 	is(doc.defaultView.getComputedStyle(rect, '').getPropertyValue("stroke-width"), "1px", "Spaces");
 
 	SimpleTest.finish();
 	}
 
-	$("svg").addEventListener("load", runTests, false);
+	window.addEventListener("load", runTests, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_selectSubString.xhtml
+++ b/content/svg/content/test/test_selectSubString.xhtml
@@ -54,13 +54,13 @@ function runTests()
   expectThrow(2, -1);
   expectThrow(3, -1);
   expectThrow(3, -3);
   expectThrow(-1, -1);
 
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", runTests, false);
+window.addEventListener("load", runTests, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_switch.xhtml
+++ b/content/svg/content/test/test_switch.xhtml
@@ -90,15 +90,15 @@ function run1()
     second.setAttribute("systemLanguage", "en-gb");
     checkWidth(s, 75, 100, 50, 50);
 
   } finally {
     SimpleTest.finish();
   }
 }
 
-$("svg").addEventListener("load", run, false);
+window.addEventListener("load", run, false);
 
 ]]>
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_text.html
+++ b/content/svg/content/test/test_text.html
@@ -176,13 +176,13 @@ function runTests() {
   var doc = $("svg").contentWindow.document;
   doc.getElementById("g").setAttribute("transform", "scale(2) rotate(90 200 200)");
   
   runTest();
 
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", runTests, false);
+window.addEventListener("load", runTests, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_text_scaled.html
+++ b/content/svg/content/test/test_text_scaled.html
@@ -130,13 +130,13 @@ function runTests() {
   var doc = $("svg").contentWindow.document;
   doc.getElementById("g").setAttribute("transform", "rotate(90 200 200)");
   
   runTest();
 
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", runTests, false);
+window.addEventListener("load", runTests, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_text_selection.html
+++ b/content/svg/content/test/test_text_selection.html
@@ -10,17 +10,17 @@ https://bugzilla.mozilla.org/show_bug.cg
   <script type="application/javascript" src="/tests/SimpleTest/EventUtils.js"></script>
   <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
 </head>
 <body>
 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=655877">Mozilla Bug 655877</a>
 <p id="display"></p>
 <div id="content" style="display: none"></div>
 
-<iframe id="svg" src="text-helper-selection.svg" width="400" height="300"></iframe>
+<iframe src="text-helper-selection.svg" width="400" height="300"></iframe>
 
 <pre id="test">
 <script class="testbody" type="application/javascript">
 SimpleTest.waitForExplicitFinish();
 
 var svg, doc, win, text, dragstart, dragend;
 
 function drag(fromX, fromY, toX, toY, show)
@@ -56,18 +56,19 @@ function deselect()
 {
   // Click outside text to deselect.
   click(1, 1);
   selection_is("", "deselecting by clicking outside text");
 }
 
 function testSelection()
 {
-  doc = $("svg").contentDocument;
-  win = $("svg").contentWindow;
+  svg = document.getElementsByTagName("iframe")[0];
+  doc = svg.contentDocument;
+  win = svg.contentWindow;
   dragstart = doc.getElementById("dragstart");
   dragend = doc.getElementById("dragend");
 
   var text = doc.getElementsByTagName("text");
 
   // Drag to select the entire text element.
   drag(101, 50, 99 + text[0].getComputedTextLength(), 50);
   selection_is("hello there", "selecting entire simple text");
@@ -131,14 +132,14 @@ function runTest()
 {
   SimpleTest.executeSoon(testSelection);
 }
 
 if (/Android/.test(navigator.userAgent)) {
   ok(true, "No need to test text selection with the mouse on Android.");
   SimpleTest.finish();
 } else {
-  $("svg").addEventListener("load", runTest, false);
+  window.addEventListener("load", runTest, false);
 }
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_viewport.html
+++ b/content/svg/content/test/test_viewport.html
@@ -66,13 +66,13 @@ function runTest()
   is(outer.farthestViewportElement, null, "outer.farthestViewportElement");
   is(g2.farthestViewportElement, outer, "g2.farthestViewportElement");
   is(g3.farthestViewportElement, null, "g3.farthestViewportElement");
   is(symbolRect.farthestViewportElement, root, "symbolRect.farthestViewportElement");
   
   SimpleTest.finish();
 }
 
-$("svg").addEventListener("load", runTest, false);
+window.addEventListener("load", runTest, false);
 </script>
 </pre>
 </body>
 </html>
--- a/content/svg/content/test/test_zoom.xhtml
+++ b/content/svg/content/test/test_zoom.xhtml
@@ -24,12 +24,12 @@ https://bugzilla.mozilla.org/show_bug.cg
       root.currentScale *= 2;
     }
 
     function zoomHandler(evt) {
       ok(true, "zoom handler should be called on zoom");
       SimpleTest.finish();
     }
 
-    $("svg").addEventListener("load", runTests, false);
+    window.addEventListener("load", runTests, false);
   </script>
 </body>
 </html>