Skip to content

Commit

Permalink
Bug 995688 Always show scrollbars in test to avoid fade effect evicti…
Browse files Browse the repository at this point in the history
…ng document from BF cache. r=smaug
  • Loading branch information
wanderview committed Aug 6, 2014
1 parent 4b9d5a3 commit 7554857
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion dom/workers/test/test_multi_sharedWorker_lifetimes.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"use strict";

const swPref = "dom.workers.sharedWorkers.enabled";
const scrollbarPref = "layout.testing.overlay-scrollbars.always-visible";
const bfCacheEnabledPref = "browser.sessionhistory.cache_subframes";
const bfCacheDepthPref = "browser.sessionhistory.max_total_viewers";
const bfCacheDepth = 10;
Expand All @@ -26,7 +27,13 @@
ok(!("SharedWorker" in window), "No SharedWorker without pref set");
}

SpecialPowers.pushPrefEnv({ set: [[swPref, true]] }, sendToGenerator);
// Enable SharedWorkers and force scrollbar to always be shown. The
// scrollbar setting is necessary to avoid the fade-in/fade-out from
// evicting our document from the BF cache below. If bug 1049277
// is fixed, then we can stop setting the scrollbar pref here.
SpecialPowers.pushPrefEnv({ set: [[swPref, true],
[scrollbarPref, true]] },
sendToGenerator);
yield undefined;

window.addEventListener("message", function(event) {
Expand Down

0 comments on commit 7554857

Please sign in to comment.