Bug 1143995 - Remove unnecessary layout flushes from test_font_loading_api.html. r=jdaggett, a=test-only
authorCameron McCormack <cam@mcc.id.au>
Tue, 17 Mar 2015 18:15:42 +1100
changeset 250439 e84f65c3a6aa
parent 250438 37be317efc7a
child 250440 9fc579f7bf3a
push id4589
push userryanvm@gmail.com
push date2015-03-19 02:20 +0000
treeherdermozilla-beta@d76c709556bb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjdaggett, test-only
bugs1143995
milestone37.0
Bug 1143995 - Remove unnecessary layout flushes from test_font_loading_api.html. r=jdaggett, a=test-only
layout/style/test/test_font_loading_api.html
--- a/layout/style/test/test_font_loading_api.html
+++ b/layout/style/test/test_font_loading_api.html
@@ -786,17 +786,16 @@ function runTest() {
     var style = document.querySelector("style");
     var ruleText = "@font-face { font-family: something; src: url(x); ";
     Object.keys(nonDefaultValues).forEach(function(aDesc) {
       ruleText += descriptorNames[aDesc] + ": " + nonDefaultValues[aDesc][0] + "; ";
     });
     ruleText += "}";
 
     style.textContent = ruleText;
-    document.body.offsetTop;
 
     var rule = style.sheet.cssRules[0];
 
     var all = Array.from(document.fonts);
     is(all.length, 1, "document.fonts should contain one FontFace (TEST 34)");
 
     var face = all[0];
     is(face.family, "\"something\"", "FontFace should have correct family value (TEST 34)");
@@ -813,17 +812,16 @@ function runTest() {
       document.fonts.delete(face);
     } catch (ex) {
       exceptionName = ex.name;
     }
     ok(exceptionName == "InvalidModificationError", "attempting to remove CSS-connected FontFace from document.fonts should throw an InvalidModificationError (TEST 34)");
     ok(document.fonts.has(face), "CSS-connected FontFace should not be removed from document.fonts when delete is called (TEST 34)");
 
     style.textContent = "";
-    document.body.offsetTop;
 
     ok(!document.fonts.has(face), "CSS-connected FontFace should be removed from document.fonts once the rule has been removed (TEST 34)");
 
     document.fonts.add(face);
     ok(document.fonts.has(face), "previously CSS-connected FontFace should be able to be added to document.fonts (TEST 34)");
 
     document.fonts.delete(face);
     ok(!document.fonts.has(face), "previously CSS-connected FontFace should be able to be removed from document.fonts (TEST 34)");