Bug 1163745 - Remove erroneous subtest from browser_sessionHistory.js r=Yoric
authorTim Taubert <ttaubert@mozilla.com>
Wed, 10 Jun 2015 14:45:37 +0200
changeset 250176 f109e82854fea3801d2e8728be55f17a9ebfafa7
parent 250175 dc22e118ec7eef395c1e8abe5c0a59174917a1e0
child 250177 5e6f90f35f9bde7cedf3a003773faeba644440ac
push id61471
push usercbook@mozilla.com
push dateThu, 25 Jun 2015 09:33:34 +0000
treeherdermozilla-inbound@5b38df79819f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersYoric
bugs1163745
milestone41.0a1
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
Bug 1163745 - Remove erroneous subtest from browser_sessionHistory.js r=Yoric
browser/components/sessionstore/test/browser_sessionHistory.js
browser/components/sessionstore/test/content.js
--- a/browser/components/sessionstore/test/browser_sessionHistory.js
+++ b/browser/components/sessionstore/test/browser_sessionHistory.js
@@ -27,46 +27,16 @@ add_task(function test_load_start() {
   // Check that the correct URL was restored.
   is(browser.currentURI.spec, "about:mozilla", "url is correct");
 
   // Cleanup.
   gBrowser.removeTab(tab);
 });
 
 /**
- * Ensure that purging shistory invalidates.
- */
-add_task(function test_purge() {
-  // Create a new tab.
-  let tab = gBrowser.addTab("about:mozilla");
-  let browser = tab.linkedBrowser;
-  yield promiseBrowserLoaded(browser);
-
-  // Create a second shistory entry.
-  browser.loadURI("about:robots");
-  yield promiseBrowserLoaded(browser);
-
-  // Check that we now have two shistory entries.
-  yield TabStateFlusher.flush(browser);
-  let {entries} = JSON.parse(ss.getTabState(tab));
-  is(entries.length, 2, "there are two shistory entries");
-
-  // Purge session history.
-  yield sendMessage(browser, "ss-test:purgeSessionHistory");
-
-  // Check that we are left with a single shistory entry.
-  yield TabStateFlusher.flush(browser);
-  ({entries} = JSON.parse(ss.getTabState(tab)));
-  is(entries.length, 1, "there is one shistory entry");
-
-  // Cleanup.
-  gBrowser.removeTab(tab);
-});
-
-/**
  * Ensure that anchor navigation invalidates shistory.
  */
 add_task(function test_hashchange() {
   const URL = "data:text/html;charset=utf-8,<a id=a href=%23>clickme</a>";
 
   // Create a new tab.
   let tab = gBrowser.addTab(URL);
   let browser = tab.linkedBrowser;
--- a/browser/components/sessionstore/test/content.js
+++ b/browser/components/sessionstore/test/content.js
@@ -79,21 +79,16 @@ addEventListener("hashchange", function 
   sendAsyncMessage("ss-test:hashchange");
 });
 
 addMessageListener("ss-test:purgeDomainData", function ({data: domain}) {
   Services.obs.notifyObservers(null, "browser:purge-domain-data", domain);
   content.setTimeout(() => sendAsyncMessage("ss-test:purgeDomainData"));
 });
 
-addMessageListener("ss-test:purgeSessionHistory", function () {
-  Services.obs.notifyObservers(null, "browser:purge-session-history", "");
-  content.setTimeout(() => sendAsyncMessage("ss-test:purgeSessionHistory"));
-});
-
 addMessageListener("ss-test:getStyleSheets", function (msg) {
   let sheets = content.document.styleSheets;
   let titles = Array.map(sheets, ss => [ss.title, ss.disabled]);
   sendSyncMessage("ss-test:getStyleSheets", titles);
 });
 
 addMessageListener("ss-test:enableStyleSheetsForSet", function (msg) {
   let sheets = content.document.styleSheets;