Bug 1682030 - Remove NPAPI from tests outside of dom/plugins. r=Gijs,cmartin
authorDavid Parks <daparks@mozilla.com>
Tue, 06 Apr 2021 19:28:09 +0000
changeset 574587 1c07317c6dbf6dc6635c20a76190c2c52bde0070
parent 574586 7bc3d3b1490988d17d2c5b70c7d3b8c8da46dba6
child 574588 080aa7b074c3962432415d0ea195ca9ca3135988
push id38351
push userbtara@mozilla.com
push dateWed, 07 Apr 2021 03:19:44 +0000
treeherdermozilla-central@e06c2941cdfc [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersGijs, cmartin
bugs1682030
milestone89.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 1682030 - Remove NPAPI from tests outside of dom/plugins. r=Gijs,cmartin Removes NPAPI plugin features from tests outside of dom/plugins. Some tests are updated to avoid NPAPI behavior and others are deleted if they no longer offer anthing useful. Differential Revision: https://phabricator.services.mozilla.com/D107134
browser/base/content/test/general/browser_tab_dragdrop.js
browser/base/content/test/general/head.js
browser/base/content/test/plugins/BlocklistTestProxy.jsm
browser/base/content/test/plugins/head.js
browser/modules/test/browser/browser_ProcessHangNotifications.js
caps/tests/mochitest/test_bug292789.html
dom/base/test/browser.ini
dom/base/test/mochitest.ini
dom/base/test/plugin.js
dom/base/test/test_bug429157.html
dom/html/test/mochitest.ini
layout/base/tests/mochitest.ini
layout/generic/test/mochitest.ini
layout/reftests/reftest.list
layout/tools/reftest/reftest.jsm
testing/specialpowers/content/SpecialPowersChild.jsm
testing/specialpowers/content/SpecialPowersParent.jsm
toolkit/components/crashes/tests/xpcshell/test_crash_manager.js
toolkit/components/crashes/tests/xpcshell/test_crash_store.js
toolkit/components/telemetry/tests/unit/TelemetryEnvironmentTesting.jsm
toolkit/components/telemetry/tests/unit/test_TelemetryEnvironment.js
toolkit/components/telemetry/tests/unit/test_TelemetryEnvironment_search.js
toolkit/content/tests/browser/head.js
toolkit/mozapps/extensions/internal/AddonTestUtils.jsm
toolkit/mozapps/extensions/test/browser/browser.ini
toolkit/mozapps/extensions/test/browser/browser_bug523784.js
toolkit/mozapps/extensions/test/browser/browser_gmpProvider.js
toolkit/mozapps/extensions/test/browser/browser_html_warning_messages.js
toolkit/mozapps/extensions/test/browser/head.js
toolkit/mozapps/extensions/test/xpcshell/data/test_pluginBlocklistCtp.xml
toolkit/mozapps/extensions/test/xpcshell/data/test_pluginBlocklistCtpUndo.xml
toolkit/mozapps/extensions/test/xpcshell/head_addons.js
toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_clients.js
toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_targetapp_filter.js
toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_telemetry.js
toolkit/mozapps/extensions/test/xpcshell/test_duplicateplugins.js
toolkit/mozapps/extensions/test/xpcshell/test_general.js
toolkit/mozapps/extensions/test/xpcshell/test_gmpProvider.js
toolkit/mozapps/extensions/test/xpcshell/test_pluginchange.js
toolkit/mozapps/extensions/test/xpcshell/test_temporary.js
toolkit/mozapps/extensions/test/xpcshell/xpcshell.ini
widget/tests/chrome.ini
widget/tests/mochitest.ini
widget/tests/test_imestate.html
widget/tests/test_plugin_scroll_consistency.html
widget/tests/utils.js
--- a/browser/base/content/test/general/browser_tab_dragdrop.js
+++ b/browser/base/content/test/general/browser_tab_dragdrop.js
@@ -108,18 +108,16 @@ async function checkObjectValue(browser)
     ok(false, "checkObjectValue threw an exception: " + data.exception);
     throw new Error(data.exception);
   } else {
     return data.result;
   }
 }
 
 add_task(async function() {
-  setTestPluginEnabledState(Ci.nsIPluginTag.STATE_ENABLED);
-
   // create a few tabs
   let tabs = [
     gBrowser.tabs[0],
     BrowserTestUtils.addTab(gBrowser, "about:blank", { skipAnimation: true }),
     BrowserTestUtils.addTab(gBrowser, "about:blank", { skipAnimation: true }),
     BrowserTestUtils.addTab(gBrowser, "about:blank", { skipAnimation: true }),
     BrowserTestUtils.addTab(gBrowser, "about:blank", { skipAnimation: true }),
   ];
--- a/browser/base/content/test/general/head.js
+++ b/browser/base/content/test/general/head.js
@@ -165,43 +165,16 @@ function promiseWaitForEvent(
  * @rejects Never.
  */
 function promiseWaitForFocus(aWindow) {
   return new Promise(resolve => {
     waitForFocus(resolve, aWindow);
   });
 }
 
-function getTestPlugin(aName) {
-  var pluginName = aName || "Test Plug-in";
-  var ph = Cc["@mozilla.org/plugin/host;1"].getService(Ci.nsIPluginHost);
-  var tags = ph.getPluginTags();
-
-  // Find the test plugin
-  for (var i = 0; i < tags.length; i++) {
-    if (tags[i].name == pluginName) {
-      return tags[i];
-    }
-  }
-  ok(false, "Unable to find plugin");
-  return null;
-}
-
-// call this to set the test plugin(s) initially expected enabled state.
-// it will automatically be reset to it's previous value after the test
-// ends
-function setTestPluginEnabledState(newEnabledState, pluginName) {
-  var plugin = getTestPlugin(pluginName);
-  var oldEnabledState = plugin.enabledState;
-  plugin.enabledState = newEnabledState;
-  SimpleTest.registerCleanupFunction(function() {
-    getTestPlugin(pluginName).enabledState = oldEnabledState;
-  });
-}
-
 function pushPrefs(...aPrefs) {
   return SpecialPowers.pushPrefEnv({ set: aPrefs });
 }
 
 function popPrefs() {
   return SpecialPowers.popPrefEnv();
 }
 
--- a/browser/base/content/test/plugins/BlocklistTestProxy.jsm
+++ b/browser/base/content/test/plugins/BlocklistTestProxy.jsm
@@ -57,26 +57,16 @@ var BlocklistProxy = {
   },
 
   notify(aTimer) {},
 
   async getAddonBlocklistState(aAddon, aAppVersion, aToolkitVersion) {
     await new Promise(r => setTimeout(r, 150));
     return 0; // STATE_NOT_BLOCKED
   },
-
-  async getPluginBlocklistState(aPluginTag, aAppVersion, aToolkitVersion) {
-    await new Promise(r => setTimeout(r, 150));
-    return 0; // STATE_NOT_BLOCKED
-  },
-
-  async getPluginBlockURL(aPluginTag) {
-    await new Promise(r => setTimeout(r, 150));
-    return "";
-  },
 };
 
 class BlocklistTestProxyChild extends JSProcessActorChild {
   constructor() {
     super();
     BlocklistProxy.init();
   }
 
--- a/browser/base/content/test/plugins/head.js
+++ b/browser/base/content/test/plugins/head.js
@@ -109,48 +109,16 @@ function promiseForCondition(aConditionF
       resolve,
       aMessage || "Condition didn't pass.",
       aTries,
       aWait
     );
   });
 }
 
-// Returns the chrome side nsIPluginTag for this plugin
-function getTestPlugin(aName) {
-  let pluginName = aName || "Test Plug-in";
-  let ph = Cc["@mozilla.org/plugin/host;1"].getService(Ci.nsIPluginHost);
-  let tags = ph.getPluginTags();
-
-  // Find the test plugin
-  for (let i = 0; i < tags.length; i++) {
-    if (tags[i].name == pluginName) {
-      return tags[i];
-    }
-  }
-  ok(false, "Unable to find plugin");
-  return null;
-}
-
-// Set the 'enabledState' on the nsIPluginTag stored in the main or chrome
-// process.
-function setTestPluginEnabledState(newEnabledState, pluginName) {
-  let name = pluginName || "Test Plug-in";
-  let plugin = getTestPlugin(name);
-  plugin.enabledState = newEnabledState;
-}
-
-// Get the 'enabledState' on the nsIPluginTag stored in the main or chrome
-// process.
-function getTestPluginEnabledState(pluginName) {
-  let name = pluginName || "Test Plug-in";
-  let plugin = getTestPlugin(name);
-  return plugin.enabledState;
-}
-
 // Returns a promise for nsIObjectLoadingContent props data.
 function promiseForPluginInfo(aId, aBrowser) {
   let browser = aBrowser || gTestBrowser;
   return SpecialPowers.spawn(browser, [aId], async function(contentId) {
     let plugin = content.document.getElementById(contentId);
     if (!(plugin instanceof Ci.nsIObjectLoadingContent)) {
       throw new Error("no plugin found");
     }
@@ -158,193 +126,16 @@ function promiseForPluginInfo(aId, aBrow
       pluginFallbackType: plugin.pluginFallbackType,
       activated: plugin.activated,
       hasRunningPlugin: plugin.hasRunningPlugin,
       displayedType: plugin.displayedType,
     };
   });
 }
 
-// Return a promise and call the plugin's playPlugin() method.
-function promisePlayObject(aId, aBrowser) {
-  let browser = aBrowser || gTestBrowser;
-  return SpecialPowers.spawn(browser, [aId], async function(contentId) {
-    content.document.getElementById(contentId).playPlugin();
-  });
-}
-
-function promiseCrashObject(aId, aBrowser) {
-  let browser = aBrowser || gTestBrowser;
-  return SpecialPowers.spawn(browser, [aId], async function(contentId) {
-    let plugin = content.document.getElementById(contentId);
-    Cu.waiveXrays(plugin).crash();
-  });
-}
-
-// Return a promise and call the plugin's getObjectValue() method.
-function promiseObjectValueResult(aId, aBrowser) {
-  let browser = aBrowser || gTestBrowser;
-  return SpecialPowers.spawn(browser, [aId], async function(contentId) {
-    let plugin = content.document.getElementById(contentId);
-    return Cu.waiveXrays(plugin).getObjectValue();
-  });
-}
-
-// Return a promise and reload the target plugin in the page
-function promiseReloadPlugin(aId, aBrowser) {
-  let browser = aBrowser || gTestBrowser;
-  return SpecialPowers.spawn(browser, [aId], async function(contentId) {
-    let plugin = content.document.getElementById(contentId);
-    // eslint-disable-next-line no-self-assign
-    plugin.src = plugin.src;
-  });
-}
-
-// after a test is done using the plugin doorhanger, we should just clear
-// any permissions that may have crept in
-function clearAllPluginPermissions() {
-  for (let perm of Services.perms.all) {
-    if (perm.type.startsWith("plugin")) {
-      info(
-        "removing permission:" + perm.principal.origin + " " + perm.type + "\n"
-      );
-      Services.perms.removePermission(perm);
-    }
-  }
-}
-
-// Ported from AddonTestUtils.jsm
-let JSONBlocklistWrapper = {
-  /**
-   * Load the data from the specified files into the *real* blocklist providers.
-   * Loads using loadBlocklistRawData, which will treat this as an update.
-   *
-   * @param {nsIFile} dir
-   *        The directory in which the files live.
-   * @param {string} prefix
-   *        a prefix for the files which ought to be loaded.
-   *        This method will suffix -extensions.json and -plugins.json
-   *        to the prefix it is given, and attempt to load both.
-   *        Insofar as either exists, their data will be dumped into
-   *        the respective store, and the respective update handlers
-   *        will be called.
-   */
-  async loadBlocklistData(url) {
-    const fullURL = `${url}-plugins.json`;
-    let jsonObj;
-    try {
-      jsonObj = await (await fetch(fullURL)).json();
-    } catch (ex) {
-      ok(false, ex);
-    }
-    info(`Loaded ${fullURL}`);
-
-    return this.loadBlocklistRawData({ plugins: jsonObj });
-  },
-
-  /**
-   * Load the following data into the *real* blocklist providers.
-   * While `overrideBlocklist` replaces the blocklist entirely with a mock
-   * that returns dummy data, this method instead loads data into the actual
-   * blocklist, fires update methods as would happen if this data came from
-   * an actual blocklist update, etc.
-   *
-   * @param {object} data
-   *        An object that can optionally have `extensions` and/or `plugins`
-   *        properties, each being an array of blocklist items.
-   *        This code only uses plugin blocks, that can look something like:
-   *
-   * {
-   *   "matchFilename": "libnptest\\.so|nptest\\.dll|Test\\.plugin",
-   *   "versionRange": [
-   *     {
-   *       "severity": "0",
-   *       "vulnerabilityStatus": "1"
-   *     }
-   *   ],
-   *   "blockID": "p9999"
-   * }
-   *
-   */
-  async loadBlocklistRawData(data) {
-    const bsPass = ChromeUtils.import(
-      "resource://gre/modules/Blocklist.jsm",
-      null
-    );
-    const blocklistMapping = {
-      extensions: bsPass.ExtensionBlocklistRS,
-      plugins: bsPass.PluginBlocklistRS,
-    };
-
-    for (const [dataProp, blocklistObj] of Object.entries(blocklistMapping)) {
-      let newData = data[dataProp];
-      if (!newData) {
-        continue;
-      }
-      if (!Array.isArray(newData)) {
-        throw new Error(
-          "Expected an array of new items to put in the " +
-            dataProp +
-            " blocklist!"
-        );
-      }
-      for (let item of newData) {
-        if (!item.id) {
-          item.id = uuidGen.generateUUID().number.slice(1, -1);
-        }
-        if (!item.last_modified) {
-          item.last_modified = Date.now();
-        }
-      }
-      await blocklistObj.ensureInitialized();
-      let db = await blocklistObj._client.db;
-      await db.importChanges({}, 42, newData, { clear: true });
-      // We manually call _onUpdate... which is evil, but at the moment kinto doesn't have
-      // a better abstraction unless you want to mock your own http server to do the update.
-      await blocklistObj._onUpdate();
-    }
-  },
-};
-
-// An async helper that insures a new blocklist is loaded (in both
-// processes if applicable).
-async function asyncSetAndUpdateBlocklist(aURL, aBrowser) {
-  let doTestRemote = aBrowser ? aBrowser.isRemoteBrowser : false;
-  let localPromise = TestUtils.topicObserved("plugin-blocklist-updated");
-  info("*** loading blocklist: " + aURL);
-  await JSONBlocklistWrapper.loadBlocklistData(aURL);
-  info("*** waiting on local load");
-  await localPromise;
-  if (doTestRemote) {
-    info("*** waiting on remote load");
-    // Ensure content has been updated with the blocklist
-    await SpecialPowers.spawn(aBrowser, [], () => {});
-  }
-  info("*** blocklist loaded.");
-}
-
-// Insure there's a popup notification present. This test does not indicate
-// open state. aBrowser can be undefined.
-function promisePopupNotification(aName, aBrowser) {
-  return new Promise(resolve => {
-    waitForCondition(
-      () => PopupNotifications.getNotification(aName, aBrowser),
-      () => {
-        ok(
-          !!PopupNotifications.getNotification(aName, aBrowser),
-          aName + " notification appeared"
-        );
-
-        resolve();
-      },
-      "timeout waiting for popup notification " + aName
-    );
-  });
-}
-
 /**
  * Allows setting focus on a window, and waiting for that window to achieve
  * focus.
  *
  * @param aWindow
  *        The window to focus and wait for.
  *
  * @return {Promise}
@@ -423,30 +214,8 @@ function waitForNotificationShown(notifi
   notification.reshow();
 }
 
 function promiseForNotificationShown(notification) {
   return new Promise(resolve => {
     waitForNotificationShown(notification, resolve);
   });
 }
-
-/**
- * Due to layout being async, "PluginBindAttached" may trigger later. This
- * returns a Promise that resolves once we've forced a layout flush, which
- * triggers the PluginBindAttached event to fire. This trick only works if
- * there is some sort of plugin in the page.
- * @param browser
- *        The browser to force plugin bindings in.
- * @return Promise
- */
-function promiseUpdatePluginBindings(browser) {
-  return SpecialPowers.spawn(browser, [], async function() {
-    let doc = content.document;
-    let elems = doc.getElementsByTagName("embed");
-    if (!elems || elems.length < 1) {
-      elems = doc.getElementsByTagName("object");
-    }
-    if (elems && elems.length) {
-      elems[0].clientTop;
-    }
-  });
-}
--- a/browser/modules/test/browser/browser_ProcessHangNotifications.js
+++ b/browser/modules/test/browser/browser_ProcessHangNotifications.js
@@ -32,28 +32,27 @@ function pushPrefs(...aPrefs) {
 
 function popPrefs() {
   return SpecialPowers.popPrefEnv();
 }
 
 const TEST_ACTION_UNKNOWN = 0;
 const TEST_ACTION_CANCELLED = 1;
 const TEST_ACTION_TERMSCRIPT = 2;
-const TEST_ACTION_TERMPLUGIN = 3;
+const TEST_ACTION_TERMGLOBAL = 3;
 const SLOW_SCRIPT = 1;
-const PLUGIN_HANG = 2;
 const ADDON_HANG = 3;
 const ADDON_ID = "fake-addon";
 
 /**
  * A mock nsIHangReport that we can pass through nsIObserverService
  * to trigger notifications.
  *
  * @param hangType
- *        One of SLOW_SCRIPT, PLUGIN_HANG, ADDON_HANG.
+ *        One of SLOW_SCRIPT, ADDON_HANG.
  * @param browser (optional)
  *        The <xul:browser> that this hang should be associated with.
  *        If not supplied, the hang will be associated with every browser,
  *        but the nsIHangReport.scriptBrowser attribute will return the
  *        currently selected browser in this window's gBrowser.
  */
 let TestHangReport = function(
   hangType = SLOW_SCRIPT,
@@ -72,17 +71,16 @@ let TestHangReport = function(
     this._hangType = hangType;
   }
 
   this._browser = browser;
 };
 
 TestHangReport.prototype = {
   SLOW_SCRIPT,
-  PLUGIN_HANG,
 
   get addonId() {
     return this._addonId;
   },
 
   get hangType() {
     return this._hangType;
   },
@@ -92,20 +90,16 @@ TestHangReport.prototype = {
   userCanceled() {
     this._resolver(TEST_ACTION_CANCELLED);
   },
 
   terminateScript() {
     this._resolver(TEST_ACTION_TERMSCRIPT);
   },
 
-  terminatePlugin() {
-    this._resolver(TEST_ACTION_TERMPLUGIN);
-  },
-
   isReportForBrowserOrChildren(aFrameLoader) {
     if (this._browser) {
       return this._browser.frameLoader === aFrameLoader;
     }
 
     return true;
   },
 
@@ -240,120 +234,79 @@ add_task(async function hangGoesAwayTest
   Services.obs.notifyObservers(hangReport, "clear-hang-report");
   let action = await hangReport.promise;
   is(action, TEST_ACTION_CANCELLED, "Hang report should have been cancelled.");
 
   await popPrefs();
 });
 
 /**
- * Tests if hang reports receive a terminate plugin callback when the user selects
- * stop in response to a plugin hang.
- */
-add_task(async function terminatePluginTest() {
-  let hangReport = new TestHangReport(PLUGIN_HANG);
-  let promise = promiseNotificationShown(window, "process-hang");
-  Services.obs.notifyObservers(hangReport, "process-hang-report");
-  let notification = await promise;
-
-  let buttons = notification.currentNotification.buttonContainer.getElementsByTagName(
-    "button"
-  );
-  // Plugin hangs only ever show 1 button in the notification - even in
-  // DevEdition.
-  is(buttons.length, 1, "proper number of buttons");
-
-  // Click the "Stop" button, we should get a terminate script callback
-  buttons[0].click();
-  let action = await hangReport.promise;
-  is(
-    action,
-    TEST_ACTION_TERMPLUGIN,
-    "Expected the 'Stop' button to terminate the plug-in"
-  );
-});
-
-/**
  * Tests that if we're shutting down, any pre-existing hang reports will
  * be terminated appropriately.
  */
 add_task(async function terminateAtShutdown() {
   let pausedHang = new TestHangReport(SLOW_SCRIPT);
   Services.obs.notifyObservers(pausedHang, "process-hang-report");
   ProcessHangMonitor.waitLonger(window);
   ok(
     ProcessHangMonitor.findPausedReport(gBrowser.selectedBrowser),
     "There should be a paused report for the selected browser."
   );
 
-  let pluginHang = new TestHangReport(PLUGIN_HANG);
   let scriptHang = new TestHangReport(SLOW_SCRIPT);
   let addonHang = new TestHangReport(ADDON_HANG);
 
-  [pluginHang, scriptHang, addonHang].forEach(hangReport => {
+  [scriptHang, addonHang].forEach(hangReport => {
     Services.obs.notifyObservers(hangReport, "process-hang-report");
   });
 
   // Simulate the browser being told to shutdown. This should cause
-  // hangs to terminate scripts / plugins.
+  // hangs to terminate scripts.
   ProcessHangMonitor.onQuitApplicationGranted();
 
   // In case this test happens to throw before it can finish, make
   // sure to reset the shutting-down state.
   registerCleanupFunction(() => {
     ProcessHangMonitor._shuttingDown = false;
   });
 
   let pausedAction = await pausedHang.promise;
-  let pluginAction = await pluginHang.promise;
   let scriptAction = await scriptHang.promise;
   let addonAction = await addonHang.promise;
 
   is(
     pausedAction,
     TEST_ACTION_TERMSCRIPT,
     "On shutdown, should have terminated script for paused script hang."
   );
   is(
-    pluginAction,
-    TEST_ACTION_TERMPLUGIN,
-    "On shutdown, should have terminated plugin for plugin hang."
-  );
-  is(
     scriptAction,
     TEST_ACTION_TERMSCRIPT,
     "On shutdown, should have terminated script for script hang."
   );
   is(
     addonAction,
     TEST_ACTION_TERMSCRIPT,
     "On shutdown, should have terminated script for add-on hang."
   );
 
   // ProcessHangMonitor should now be in the "shutting down" state,
   // meaning that any further hangs should be handled immediately
   // without user interaction.
-  let pluginHang2 = new TestHangReport(PLUGIN_HANG);
   let scriptHang2 = new TestHangReport(SLOW_SCRIPT);
   let addonHang2 = new TestHangReport(ADDON_HANG);
 
-  [pluginHang2, scriptHang2, addonHang2].forEach(hangReport => {
+  [scriptHang2, addonHang2].forEach(hangReport => {
     Services.obs.notifyObservers(hangReport, "process-hang-report");
   });
 
-  let pluginAction2 = await pluginHang.promise;
   let scriptAction2 = await scriptHang.promise;
   let addonAction2 = await addonHang.promise;
 
   is(
-    pluginAction2,
-    TEST_ACTION_TERMPLUGIN,
-    "On shutdown, should have terminated plugin for plugin hang."
-  );
-  is(
     scriptAction2,
     TEST_ACTION_TERMSCRIPT,
     "On shutdown, should have terminated script for script hang."
   );
   is(
     addonAction2,
     TEST_ACTION_TERMSCRIPT,
     "On shutdown, should have terminated script for add-on hang."
@@ -376,21 +329,20 @@ add_task(async function terminateNoWindo
   );
   Services.obs.notifyObservers(pausedHang, "process-hang-report");
   ProcessHangMonitor.waitLonger(testWin);
   ok(
     ProcessHangMonitor.findPausedReport(testWin.gBrowser.selectedBrowser),
     "There should be a paused report for the selected browser."
   );
 
-  let pluginHang = new TestHangReport(PLUGIN_HANG);
   let scriptHang = new TestHangReport(SLOW_SCRIPT);
   let addonHang = new TestHangReport(ADDON_HANG);
 
-  [pluginHang, scriptHang, addonHang].forEach(hangReport => {
+  [scriptHang, addonHang].forEach(hangReport => {
     Services.obs.notifyObservers(hangReport, "process-hang-report");
   });
 
   // Quick and dirty hack to trick the window mediator into thinking there
   // are no browser windows without actually closing all browser windows.
   document.documentElement.setAttribute(
     "windowtype",
     "navigator:browsertestdummy"
@@ -400,62 +352,49 @@ add_task(async function terminateNoWindo
   // sure to reset this.
   registerCleanupFunction(() => {
     document.documentElement.setAttribute("windowtype", "navigator:browser");
   });
 
   await BrowserTestUtils.closeWindow(testWin);
 
   let pausedAction = await pausedHang.promise;
-  let pluginAction = await pluginHang.promise;
   let scriptAction = await scriptHang.promise;
   let addonAction = await addonHang.promise;
 
   is(
     pausedAction,
     TEST_ACTION_TERMSCRIPT,
     "With no open windows, should have terminated script for paused script hang."
   );
   is(
-    pluginAction,
-    TEST_ACTION_TERMPLUGIN,
-    "With no open windows, should have terminated plugin for plugin hang."
-  );
-  is(
     scriptAction,
     TEST_ACTION_TERMSCRIPT,
     "With no open windows, should have terminated script for script hang."
   );
   is(
     addonAction,
     TEST_ACTION_TERMSCRIPT,
     "With no open windows, should have terminated script for add-on hang."
   );
 
   // ProcessHangMonitor should notice we're in the "no windows" state,
   // so any further hangs should be handled immediately without user
   // interaction.
-  let pluginHang2 = new TestHangReport(PLUGIN_HANG);
   let scriptHang2 = new TestHangReport(SLOW_SCRIPT);
   let addonHang2 = new TestHangReport(ADDON_HANG);
 
-  [pluginHang2, scriptHang2, addonHang2].forEach(hangReport => {
+  [scriptHang2, addonHang2].forEach(hangReport => {
     Services.obs.notifyObservers(hangReport, "process-hang-report");
   });
 
-  let pluginAction2 = await pluginHang.promise;
   let scriptAction2 = await scriptHang.promise;
   let addonAction2 = await addonHang.promise;
 
   is(
-    pluginAction2,
-    TEST_ACTION_TERMPLUGIN,
-    "With no open windows, should have terminated plugin for plugin hang."
-  );
-  is(
     scriptAction2,
     TEST_ACTION_TERMSCRIPT,
     "With no open windows, should have terminated script for script hang."
   );
   is(
     addonAction2,
     TEST_ACTION_TERMSCRIPT,
     "With no open windows, should have terminated script for add-on hang."
@@ -478,42 +417,35 @@ add_task(async function terminateClosedW
   let pausedHang = new TestHangReport(SLOW_SCRIPT, testBrowser);
   Services.obs.notifyObservers(pausedHang, "process-hang-report");
   ProcessHangMonitor.waitLonger(testWin);
   ok(
     ProcessHangMonitor.findPausedReport(testWin.gBrowser.selectedBrowser),
     "There should be a paused report for the selected browser."
   );
 
-  let pluginHang = new TestHangReport(PLUGIN_HANG, testBrowser);
   let scriptHang = new TestHangReport(SLOW_SCRIPT, testBrowser);
   let addonHang = new TestHangReport(ADDON_HANG, testBrowser);
 
-  [pluginHang, scriptHang, addonHang].forEach(hangReport => {
+  [scriptHang, addonHang].forEach(hangReport => {
     Services.obs.notifyObservers(hangReport, "process-hang-report");
   });
 
   await BrowserTestUtils.closeWindow(testWin);
 
   let pausedAction = await pausedHang.promise;
-  let pluginAction = await pluginHang.promise;
   let scriptAction = await scriptHang.promise;
   let addonAction = await addonHang.promise;
 
   is(
     pausedAction,
     TEST_ACTION_TERMSCRIPT,
     "When closing window, should have terminated script for a paused script hang."
   );
   is(
-    pluginAction,
-    TEST_ACTION_TERMPLUGIN,
-    "When closing window, should have terminated hung plug-in."
-  );
-  is(
     scriptAction,
     TEST_ACTION_TERMSCRIPT,
     "When closing window, should have terminated script for script hang."
   );
   is(
     addonAction,
     TEST_ACTION_TERMSCRIPT,
     "When closing window, should have terminated script for add-on hang."
--- a/caps/tests/mochitest/test_bug292789.html
+++ b/caps/tests/mochitest/test_bug292789.html
@@ -8,54 +8,59 @@ https://bugzilla.mozilla.org/show_bug.cg
   <script src="/tests/SimpleTest/SimpleTest.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=292789">Mozilla Bug 292789</a>
 <p id="display"></p>
 <div id="content" style="display: none">
   <script src="chrome://global/content/treeUtils.js"></script>
-  <script type="application/javascript" src="chrome://mozapps/content/extensions/blocklist.js"></script>
+  <script type="application/javascript" src="chrome://mozapps/content/update/history.js"></script>
   <script id="resjs" type="application/javascript"></script>
 </div>
 <pre id="test">
 <script class="testbody" type="text/javascript">
 
 /** Test for Bug 292789
  **
  ** Selectively allow access to allowlisted chrome packages
  ** even for ALLOW_CHROME mechanisms (<script>, <img> etc)
  **/
 
 /* import-globals-from ../../../toolkit/content/treeUtils.js */
+/* import-globals-from ../../../toolkit/mozapps/update/content/history.js */
 
 SimpleTest.waitForExplicitFinish();
 
 let ChromeUtils = {
   import() { return {}; },
 };
 
 /** <script src=""> test **/
 function testScriptSrc(aCallback) {
     is(typeof gTreeUtils.sort, "function",
        "content can still load <script> from chrome://global");
-    is(typeof Startup, "undefined",
+
+    /** Try to find an export from history.js.  We will find it if it is
+     ** improperly not blocked, otherwise it will be "undefined".
+     **/
+    is(typeof gUpdateHistory, "undefined",
        "content should not be able to load <script> from chrome://mozapps");
 
     /** make sure the last one didn't pass because someone
-     ** moved the resource
+     ** moved history.js
      **/
     var resjs = document.getElementById("resjs");
     resjs.onload = scriptOnload;
-    resjs.src = "resource://gre/chrome/toolkit/content/mozapps/extensions/blocklist.js";
+    resjs.src = "resource://gre/chrome/toolkit/content/mozapps/update/history.js";
     document.getElementById("content").appendChild(resjs);
 
     function scriptOnload() {
-      is(typeof init, "function",
-         "blocklist.js has not moved unexpectedly");
+      is(typeof gUpdateHistory.onLoad, "function",
+         "history.js has not moved unexpectedly");
 
       // trigger the callback
       if (aCallback)
         aCallback();
     }
 }
 
 /** <img src=""> tests **/
--- a/dom/base/test/browser.ini
+++ b/dom/base/test/browser.ini
@@ -29,17 +29,16 @@ support-files =
   file_use_counter_style.html
   file_use_counter_svg_getElementById.svg
   file_use_counter_svg_currentScale.svg
   file_use_counter_svg_fill_pattern_definition.svg
   file_use_counter_svg_fill_pattern.svg
   file_use_counter_svg_fill_pattern_internal.svg
   file_use_counter_svg_fill_pattern_data.svg
   file_webaudio_startstop.html
-  plugin.js
   !/image/test/mochitest/shaver.png
 
 [browser_blocking_image.js]
 [browser_bug593387.js]
 support-files =
   file_x-frame-options_main.html
   file_x-frame-options_page.sjs
 [browser_bug902350.js]
--- a/dom/base/test/mochitest.ini
+++ b/dom/base/test/mochitest.ini
@@ -182,17 +182,16 @@ support-files =
   file_xhtmlserializer_2_entw3c.xhtml
   file_xhtmlserializer_2_latin1.xhtml
   file_youtube_flash_embed.html
   forRemoval.resource
   forRemoval.resource^headers^
   formReset.html
   invalid_accesscontrol.resource
   invalid_accesscontrol.resource^headers^
-  plugin.js
   script-1_bug597345.sjs
   script-2_bug597345.js
   script_bug602838.sjs
   send_gzip_content.sjs
   somedatas.resource
   somedatas.resource^headers^
   variable_style_sheet.sjs
   viewport_helpers.js
@@ -375,17 +374,16 @@ support-files = test_bug402150.html^head
 [test_bug422403-2.xhtml]
 [test_bug422537.html]
 [test_bug424212.html]
 [test_bug424359-1.html]
 [test_bug424359-2.html]
 [test_bug426308.html]
 [test_bug426646.html]
 [test_bug428847.html]
-[test_bug429157.html]
 [test_bug431082.html]
 [test_bug431701.html]
 [test_bug431833.html]
 [test_bug433533.html]
 [test_bug433662.html]
 [test_bug435425.html]
 [test_bug444322.html]
 [test_bug444546.html]
deleted file mode 100644
--- a/dom/base/test/plugin.js
+++ /dev/null
@@ -1,39 +0,0 @@
-// Copied from /dom/plugins/test/mochitest/utils.js
-function getTestPlugin(pluginName) {
-  var ph = SpecialPowers.Cc["@mozilla.org/plugin/host;1"].getService(
-    SpecialPowers.Ci.nsIPluginHost
-  );
-  var tags = ph.getPluginTags();
-  var name = pluginName || "Test Plug-in";
-  for (var tag of tags) {
-    if (tag.name == name) {
-      return tag;
-    }
-  }
-
-  ok(false, "Could not find plugin tag with plugin name '" + name + "'");
-  return null;
-}
-// Copied from /dom/plugins/test/mochitest/utils.js
-async function setTestPluginEnabledState(newEnabledState, pluginName) {
-  var oldEnabledState = await SpecialPowers.setTestPluginEnabledState(
-    newEnabledState,
-    pluginName
-  );
-  if (!oldEnabledState) {
-    return;
-  }
-  var plugin = getTestPlugin(pluginName);
-  // Run a nested event loop to wait for the preference change to
-  // propagate to the child. Yuck!
-  SpecialPowers.Services.tm.spinEventLoopUntil(
-    "Test(plugin.js->setTestPluginEnabledState)",
-    () => {
-      return plugin.enabledState == newEnabledState;
-    }
-  );
-  SimpleTest.registerCleanupFunction(function() {
-    return SpecialPowers.setTestPluginEnabledState(oldEnabledState, pluginName);
-  });
-}
-setTestPluginEnabledState(SpecialPowers.Ci.nsIPluginTag.STATE_ENABLED);
deleted file mode 100644
--- a/dom/base/test/test_bug429157.html
+++ /dev/null
@@ -1,54 +0,0 @@
-<!DOCTYPE HTML>
-<html>
-<!--
-https://bugzilla.mozilla.org/show_bug.cgi?id=429157
--->
-<head>
-  <title>Test for Bug 429157</title>
-  <script src="/tests/SimpleTest/SimpleTest.js"></script>
-  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-</head>
-<body onload="runtests();">
-
-<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=429157">Mozilla Bug 429157</a>
-<br>
-
-<script>
-var missingPlugins = new Array();
-const OBJLC = SpecialPowers.Ci.nsIObjectLoadingContent;
-
-function pluginBindingAttached(event)
-{
-  var plugin = event.target;
-  plugin instanceof OBJLC;
-  if (SpecialPowers.wrap(plugin).pluginFallbackType == OBJLC.PLUGIN_UNSUPPORTED)
-    missingPlugins.push(plugin);
-}
-
-document.addEventListener("PluginBindingAttached", pluginBindingAttached, true);
-</script>
-
-<object id="obj1" type="image/png"    >ALT image/png</object><br>
-<object id="obj2" type="image/svg+xml">ALT image/svg+xml</object><br>
-<object id="obj3" type="text/html"    >ALT text/html</object><br>
-<object id="obj4" type="text/plain"   >ALT text/plain</object><br>
-
-<script class="testbody" type="text/javascript">
-function runtests()
-{
-  for (var obj of document.querySelectorAll("object")) {
-    obj.clientTop;
-  }
-
-  SimpleTest.executeSoon(function () {
-    is(missingPlugins.length, 0, "There should be no missing plugins for this page");
-
-    SimpleTest.finish();
-  });
-}
-
-SimpleTest.waitForExplicitFinish();
-</script>
-</pre>
-</body>
-</html>
--- a/dom/html/test/mochitest.ini
+++ b/dom/html/test/mochitest.ini
@@ -39,17 +39,16 @@ support-files =
   bug514856_iframe.html
   bug1260704_iframe.html
   bug1260704_iframe_empty.html
   bug1292522_iframe.html
   bug1292522_page.html
   bug1315146-iframe.html
   bug1315146-main.html
   dummy_page.html
-  ../../plugins/test/mochitest/plugin-utils.js
   test_non-ascii-cookie.html^headers^
   file_bug209275_1.html
   file_bug209275_2.html
   file_bug209275_3.html
   file_bug297761.html
   file_bug417760.png
   file_bug893537.html
   file_bug1260704.png
--- a/layout/base/tests/mochitest.ini
+++ b/layout/base/tests/mochitest.ini
@@ -1,17 +1,16 @@
 [DEFAULT]
 prefs =
   formhelper.autozoom.force-disable.test-only=true
 support-files =
   Ahem.ttf
   file_bug842853.html
   file_bug842853.sjs
   selection-utils.js
-  ../../../dom/plugins/test/mochitest/plugin-utils.js
   !/gfx/layers/apz/test/mochitest/apz_test_utils.js
 
 [test_after_paint_pref.html]
 skip-if = (os == 'win' && asan) # Bug 1459682
 [test_border_radius_hit_testing.html]
 support-files = border_radius_hit_testing_iframe.html
 [test_bug66619.html]
 [test_bug93077-1.html]
--- a/layout/generic/test/mochitest.ini
+++ b/layout/generic/test/mochitest.ini
@@ -1,16 +1,15 @@
 [DEFAULT]
 prefs =
   gfx.font_loader.delay=0
 skip-if = toolkit == 'android' #CRASH_DUMP, RANDOM, ONLY IN CHUNK 10
 support-files =
   ../../reftests/backgrounds/blue-32x32.png
   ../../reftests/backgrounds/fuchsia-32x32.png
-  ../../../dom/plugins/test/mochitest/plugin-utils.js
   file_BrokenImageReference.png
   file_Dolske.png
   file_IconTestServer.sjs
   file_LoadingImageReference.png
   file_SlowImage.sjs
   file_SlowPage.sjs
   file_SlowTallImage.sjs
   bug1174521.html
--- a/layout/reftests/reftest.list
+++ b/layout/reftests/reftest.list
@@ -295,19 +295,16 @@ skip-if(browserIsRemote) include mp4-vid
 include ../../parser/htmlparser/tests/reftest/reftest.list
 
 # percent-overflow-sizing/
 include percent-overflow-sizing/reftest.list
 
 # pixel-rounding/
 include pixel-rounding/reftest.list
 
-# plugin/
-include ../../dom/plugins/test/reftest/reftest.list
-
 # position-dynamic-changes/
 include position-dynamic-changes/reftest.list
 
 # printing
 # Disabled on Linux for frequent failures, bug 1634335
 # Diasbled on Android because pdf.js load fails.
 skip-if(!winWidget&&!cocoaWidget) include printing/reftest.list
 
--- a/layout/tools/reftest/reftest.jsm
+++ b/layout/tools/reftest/reftest.jsm
@@ -3,17 +3,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 "use strict";
 
 var EXPORTED_SYMBOLS = [
     "OnRefTestLoad",
     "OnRefTestUnload",
-    "getTestPlugin"
 ];
 
 Cu.import("resource://gre/modules/FileUtils.jsm");
 Cu.import("resource://reftest/globals.jsm", this);
 Cu.import("resource://reftest/httpd.jsm", this);
 Cu.import("resource://reftest/manifest.jsm", this);
 Cu.import("resource://reftest/StructuredLog.jsm", this);
 Cu.import("resource://reftest/PerTestCoverageUtils.jsm", this);
@@ -127,30 +126,16 @@ function IDForEventTarget(event)
 {
     try {
         return "'" + event.target.getAttribute('id') + "'";
     } catch (ex) {
         return "<unknown>";
     }
 }
 
-function getTestPlugin(aName) {
-  var ph = Cc["@mozilla.org/plugin/host;1"].getService(Ci.nsIPluginHost);
-  var tags = ph.getPluginTags();
-
-  // Find the test plugin
-  for (var i = 0; i < tags.length; i++) {
-    if (tags[i].name == aName)
-      return tags[i];
-  }
-
-  logger.warning("Failed to find the test-plugin.");
-  return null;
-}
-
 function OnRefTestLoad(win)
 {
     g.crashDumpDir = Cc[NS_DIRECTORY_SERVICE_CONTRACTID]
                     .getService(Ci.nsIProperties)
                     .get("ProfD", Ci.nsIFile);
     g.crashDumpDir.append("minidumps");
 
     g.pendingCrashDumpDir = Cc[NS_DIRECTORY_SERVICE_CONTRACTID]
@@ -200,27 +185,16 @@ function OnRefTestLoad(win)
       doc.appendChild(g.browser);
       // TODO Bug 1156817: reftests don't have most of GeckoView infra so we
       // can't register this actor
       ChromeUtils.unregisterWindowActor("LoadURIDelegate");
     } else {
       document.getElementById("reftest-window").appendChild(g.browser);
     }
 
-    // reftests should have the test plugins enabled, not click-to-play
-    let plugin1 = getTestPlugin("Test Plug-in");
-    let plugin2 = getTestPlugin("Second Test Plug-in");
-    if (plugin1 && plugin2) {
-      g.testPluginEnabledStates = [plugin1.enabledState, plugin2.enabledState];
-      plugin1.enabledState = Ci.nsIPluginTag.STATE_ENABLED;
-      plugin2.enabledState = Ci.nsIPluginTag.STATE_ENABLED;
-    } else {
-      logger.warning("Could not get test plugin tags.");
-    }
-
     g.browserMessageManager = g.browser.frameLoader.messageManager;
     // The content script waits for the initial onload, then notifies
     // us.
     RegisterMessageListenersAndLoadContentScript(false);
 }
 
 function InitAndStartRefTests()
 {
@@ -573,24 +547,16 @@ function StartTests()
         ++g.testResults.Exception;
         logger.error("EXCEPTION: " + ex);
         DoneTests();
     }
 }
 
 function OnRefTestUnload()
 {
-  let plugin1 = getTestPlugin("Test Plug-in");
-  let plugin2 = getTestPlugin("Second Test Plug-in");
-  if (plugin1 && plugin2) {
-    plugin1.enabledState = g.testPluginEnabledStates[0];
-    plugin2.enabledState = g.testPluginEnabledStates[1];
-  } else {
-    logger.warning("Failed to get test plugin tags.");
-  }
 }
 
 function AddURIUseCount(uri)
 {
     if (uri == null)
         return;
 
     var spec = uri.spec;
--- a/testing/specialpowers/content/SpecialPowersChild.jsm
+++ b/testing/specialpowers/content/SpecialPowersChild.jsm
@@ -865,23 +865,16 @@ class SpecialPowersChild extends JSWindo
   registerObservers(topic) {
     var msg = {
       op: "add",
       observerTopic: topic,
     };
     return this.sendQuery("SPObserverService", msg);
   }
 
-  setTestPluginEnabledState(newEnabledState, pluginName) {
-    return this.sendQuery("SPSetTestPluginEnabledState", {
-      newEnabledState,
-      pluginName,
-    });
-  }
-
   async pushPrefEnv(inPrefs, callback = null) {
     await this.sendQuery("PushPrefEnv", inPrefs).then(callback);
     await this.promiseTimeout(0);
   }
 
   async popPrefEnv(callback = null) {
     await this.sendQuery("PopPrefEnv").then(callback);
     await this.promiseTimeout(0);
--- a/testing/specialpowers/content/SpecialPowersParent.jsm
+++ b/testing/specialpowers/content/SpecialPowersParent.jsm
@@ -24,29 +24,16 @@ XPCOMUtils.defineLazyModuleGetters(this,
 });
 
 class SpecialPowersError extends Error {
   get name() {
     return "SpecialPowersError";
   }
 }
 
-function getTestPlugin(pluginName) {
-  var ph = Cc["@mozilla.org/plugin/host;1"].getService(Ci.nsIPluginHost);
-  var tags = ph.getPluginTags();
-  var name = pluginName || "Test Plug-in";
-  for (var tag of tags) {
-    if (tag.name == name) {
-      return tag;
-    }
-  }
-
-  return null;
-}
-
 const PREF_TYPES = {
   [Ci.nsIPrefBranch.PREF_INVALID]: "INVALID",
   [Ci.nsIPrefBranch.PREF_INT]: "INT",
   [Ci.nsIPrefBranch.PREF_BOOL]: "BOOL",
   [Ci.nsIPrefBranch.PREF_STRING]: "CHAR",
   number: "INT",
   boolean: "BOOL",
   string: "CHAR",
@@ -934,26 +921,16 @@ class SpecialPowersParent extends JSWind
             default:
               throw new SpecialPowersError(
                 "Invalid operation for SPPermissionManager"
               );
           }
           return undefined; // See comment at the beginning of this function.
         }
 
-        case "SPSetTestPluginEnabledState": {
-          var plugin = getTestPlugin(aMessage.data.pluginName);
-          if (!plugin) {
-            return undefined;
-          }
-          var oldEnabledState = plugin.enabledState;
-          plugin.enabledState = aMessage.data.newEnabledState;
-          return oldEnabledState;
-        }
-
         case "SPObserverService": {
           let topic = aMessage.json.observerTopic;
           switch (aMessage.json.op) {
             case "notify":
               let data = aMessage.json.observerData;
               Services.obs.notifyObservers(null, topic, data);
               break;
             case "add":
--- a/toolkit/components/crashes/tests/xpcshell/test_crash_manager.js
+++ b/toolkit/components/crashes/tests/xpcshell/test_crash_manager.js
@@ -181,17 +181,17 @@ add_task(async function test_aggregate_i
   Assert.equal(count, 1);
 });
 
 add_task(async function test_prune_old() {
   let m = await getManager();
   let oldDate = new Date(Date.now() - 86400000);
   let newDate = new Date(Date.now() - 10000);
   await m.createEventsFile("1", "crash.main.3", oldDate, "id1", "{}");
-  await m.addCrash(m.PROCESS_TYPE_PLUGIN, m.CRASH_TYPE_CRASH, "id2", newDate);
+  await m.addCrash(m.PROCESS_TYPE_CONTENT, m.CRASH_TYPE_CRASH, "id2", newDate);
 
   await m.aggregateEventsFiles();
 
   let crashes = await m.getCrashes();
   Assert.equal(crashes.length, 2);
 
   await m.pruneOldCrashes(new Date(oldDate.getTime() + 10000));
 
@@ -451,28 +451,16 @@ add_task(async function test_addCrash() 
   );
   await m.addCrash(
     m.PROCESS_TYPE_CONTENT,
     m.CRASH_TYPE_HANG,
     "content-hang",
     DUMMY_DATE
   );
   await m.addCrash(
-    m.PROCESS_TYPE_PLUGIN,
-    m.CRASH_TYPE_CRASH,
-    "plugin-crash",
-    DUMMY_DATE
-  );
-  await m.addCrash(
-    m.PROCESS_TYPE_PLUGIN,
-    m.CRASH_TYPE_HANG,
-    "plugin-hang",
-    DUMMY_DATE
-  );
-  await m.addCrash(
     m.PROCESS_TYPE_GMPLUGIN,
     m.CRASH_TYPE_CRASH,
     "gmplugin-crash",
     DUMMY_DATE
   );
   await m.addCrash(
     m.PROCESS_TYPE_GPU,
     m.CRASH_TYPE_CRASH,
@@ -507,17 +495,17 @@ add_task(async function test_addCrash() 
   await m.addCrash(
     m.PROCESS_TYPE_CONTENT,
     m.CRASH_TYPE_HANG,
     "changing-item",
     DUMMY_DATE_2
   );
 
   crashes = await m.getCrashes();
-  Assert.equal(crashes.length, 12);
+  Assert.equal(crashes.length, 10);
 
   let map = new Map(crashes.map(crash => [crash.id, crash]));
 
   let crash = map.get("main-crash");
   Assert.ok(!!crash);
   Assert.equal(crash.crashDate, DUMMY_DATE);
   Assert.equal(crash.type, m.PROCESS_TYPE_MAIN + "-" + m.CRASH_TYPE_CRASH);
   Assert.ok(crash.isOfType(m.PROCESS_TYPE_MAIN, m.CRASH_TYPE_CRASH));
@@ -535,28 +523,16 @@ add_task(async function test_addCrash() 
   Assert.ok(crash.isOfType(m.PROCESS_TYPE_CONTENT, m.CRASH_TYPE_CRASH));
 
   crash = map.get("content-hang");
   Assert.ok(!!crash);
   Assert.equal(crash.crashDate, DUMMY_DATE);
   Assert.equal(crash.type, m.PROCESS_TYPE_CONTENT + "-" + m.CRASH_TYPE_HANG);
   Assert.ok(crash.isOfType(m.PROCESS_TYPE_CONTENT, m.CRASH_TYPE_HANG));
 
-  crash = map.get("plugin-crash");
-  Assert.ok(!!crash);
-  Assert.equal(crash.crashDate, DUMMY_DATE);
-  Assert.equal(crash.type, m.PROCESS_TYPE_PLUGIN + "-" + m.CRASH_TYPE_CRASH);
-  Assert.ok(crash.isOfType(m.PROCESS_TYPE_PLUGIN, m.CRASH_TYPE_CRASH));
-
-  crash = map.get("plugin-hang");
-  Assert.ok(!!crash);
-  Assert.equal(crash.crashDate, DUMMY_DATE);
-  Assert.equal(crash.type, m.PROCESS_TYPE_PLUGIN + "-" + m.CRASH_TYPE_HANG);
-  Assert.ok(crash.isOfType(m.PROCESS_TYPE_PLUGIN, m.CRASH_TYPE_HANG));
-
   crash = map.get("gmplugin-crash");
   Assert.ok(!!crash);
   Assert.equal(crash.crashDate, DUMMY_DATE);
   Assert.equal(crash.type, m.PROCESS_TYPE_GMPLUGIN + "-" + m.CRASH_TYPE_CRASH);
   Assert.ok(crash.isOfType(m.PROCESS_TYPE_GMPLUGIN, m.CRASH_TYPE_CRASH));
 
   crash = map.get("gpu-crash");
   Assert.ok(!!crash);
@@ -595,17 +571,16 @@ add_task(async function test_child_proce
     m.PROCESS_TYPE_CONTENT,
     m.PROCESS_TYPE_GPU,
     m.PROCESS_TYPE_VR,
     m.PROCESS_TYPE_RDD,
     m.PROCESS_TYPE_SOCKET,
   ];
 
   const UNEXPECTED_PROCESSES = [
-    m.PROCESS_TYPE_PLUGIN,
     m.PROCESS_TYPE_GMPLUGIN,
     null,
     12, // non-string process type
   ];
 
   let ac = new TelemetryArchiveTesting.Checker();
   await ac.promiseInit();
 
--- a/toolkit/components/crashes/tests/xpcshell/test_crash_store.js
+++ b/toolkit/components/crashes/tests/xpcshell/test_crash_store.js
@@ -16,17 +16,16 @@ const DUMMY_DATE = new Date(Date.now() -
 DUMMY_DATE.setMilliseconds(0);
 
 const DUMMY_DATE_2 = new Date(Date.now() - 5 * 24 * 60 * 60 * 1000);
 DUMMY_DATE_2.setMilliseconds(0);
 
 const {
   PROCESS_TYPE_MAIN,
   PROCESS_TYPE_CONTENT,
-  PROCESS_TYPE_PLUGIN,
   PROCESS_TYPE_GMPLUGIN,
   PROCESS_TYPE_GPU,
   PROCESS_TYPE_VR,
   PROCESS_TYPE_RDD,
   PROCESS_TYPE_SOCKET,
   CRASH_TYPE_CRASH,
   CRASH_TYPE_HANG,
   SUBMISSION_RESULT_OK,
@@ -232,70 +231,16 @@ add_task(async function test_add_content
     s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG, "id1", new Date())
   );
   Assert.equal(s.crashesCount, 2);
 
   let crashes = s.getCrashesOfType(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG);
   Assert.equal(crashes.length, 2);
 });
 
-add_task(async function test_add_plugin_crash() {
-  let s = await getStore();
-
-  Assert.ok(
-    s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH, "id1", new Date())
-  );
-  Assert.equal(s.crashesCount, 1);
-
-  let c = s.crashes[0];
-  Assert.ok(c.crashDate);
-  Assert.equal(c.type, PROCESS_TYPE_PLUGIN + "-" + CRASH_TYPE_CRASH);
-  Assert.ok(c.isOfType(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH));
-
-  Assert.ok(
-    s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH, "id2", new Date())
-  );
-  Assert.equal(s.crashesCount, 2);
-
-  Assert.ok(
-    s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH, "id1", new Date())
-  );
-  Assert.equal(s.crashesCount, 2);
-
-  let crashes = s.getCrashesOfType(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH);
-  Assert.equal(crashes.length, 2);
-});
-
-add_task(async function test_add_plugin_hang() {
-  let s = await getStore();
-
-  Assert.ok(
-    s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG, "id1", new Date())
-  );
-  Assert.equal(s.crashesCount, 1);
-
-  let c = s.crashes[0];
-  Assert.ok(c.crashDate);
-  Assert.equal(c.type, PROCESS_TYPE_PLUGIN + "-" + CRASH_TYPE_HANG);
-  Assert.ok(c.isOfType(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG));
-
-  Assert.ok(
-    s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG, "id2", new Date())
-  );
-  Assert.equal(s.crashesCount, 2);
-
-  Assert.ok(
-    s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG, "id1", new Date())
-  );
-  Assert.equal(s.crashesCount, 2);
-
-  let crashes = s.getCrashesOfType(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG);
-  Assert.equal(crashes.length, 2);
-});
-
 add_task(async function test_add_gmplugin_crash() {
   let s = await getStore();
 
   Assert.ok(
     s.addCrash(PROCESS_TYPE_GMPLUGIN, CRASH_TYPE_CRASH, "id1", new Date())
   );
   Assert.equal(s.crashesCount, 1);
 
@@ -416,18 +361,16 @@ add_task(async function test_add_mixed_t
       s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_HANG, "mhang", new Date()) &&
       s.addCrash(
         PROCESS_TYPE_CONTENT,
         CRASH_TYPE_CRASH,
         "ccrash",
         new Date()
       ) &&
       s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG, "chang", new Date()) &&
-      s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH, "pcrash", new Date()) &&
-      s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG, "phang", new Date()) &&
       s.addCrash(
         PROCESS_TYPE_GMPLUGIN,
         CRASH_TYPE_CRASH,
         "gmpcrash",
         new Date()
       ) &&
       s.addCrash(PROCESS_TYPE_GPU, CRASH_TYPE_CRASH, "gpucrash", new Date()) &&
       s.addCrash(PROCESS_TYPE_VR, CRASH_TYPE_CRASH, "vrcrash", new Date()) &&
@@ -435,39 +378,35 @@ add_task(async function test_add_mixed_t
       s.addCrash(
         PROCESS_TYPE_SOCKET,
         CRASH_TYPE_CRASH,
         "socketcrash",
         new Date()
       )
   );
 
-  Assert.equal(s.crashesCount, 11);
+  Assert.equal(s.crashesCount, 9);
 
   await s.save();
 
   s._data.crashes.clear();
   Assert.equal(s.crashesCount, 0);
 
   await s.load();
 
-  Assert.equal(s.crashesCount, 11);
+  Assert.equal(s.crashesCount, 9);
 
   let crashes = s.getCrashesOfType(PROCESS_TYPE_MAIN, CRASH_TYPE_CRASH);
   Assert.equal(crashes.length, 1);
   crashes = s.getCrashesOfType(PROCESS_TYPE_MAIN, CRASH_TYPE_HANG);
   Assert.equal(crashes.length, 1);
   crashes = s.getCrashesOfType(PROCESS_TYPE_CONTENT, CRASH_TYPE_CRASH);
   Assert.equal(crashes.length, 1);
   crashes = s.getCrashesOfType(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG);
   Assert.equal(crashes.length, 1);
-  crashes = s.getCrashesOfType(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH);
-  Assert.equal(crashes.length, 1);
-  crashes = s.getCrashesOfType(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG);
-  Assert.equal(crashes.length, 1);
   crashes = s.getCrashesOfType(PROCESS_TYPE_GMPLUGIN, CRASH_TYPE_CRASH);
   Assert.equal(crashes.length, 1);
   crashes = s.getCrashesOfType(PROCESS_TYPE_GPU, CRASH_TYPE_CRASH);
   Assert.equal(crashes.length, 1);
   crashes = s.getCrashesOfType(PROCESS_TYPE_VR, CRASH_TYPE_CRASH);
   Assert.equal(crashes.length, 1);
   crashes = s.getCrashesOfType(PROCESS_TYPE_RDD, CRASH_TYPE_CRASH);
   Assert.equal(crashes.length, 1);
@@ -487,60 +426,46 @@ add_task(async function test_high_water(
     Assert.ok(
       s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_CRASH, "mc1" + i, d1) &&
         s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_CRASH, "mc2" + i, d2) &&
         s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_HANG, "mh1" + i, d1) &&
         s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_HANG, "mh2" + i, d2) &&
         s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_CRASH, "cc1" + i, d1) &&
         s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_CRASH, "cc2" + i, d2) &&
         s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG, "ch1" + i, d1) &&
-        s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG, "ch2" + i, d2) &&
-        s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH, "pc1" + i, d1) &&
-        s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH, "pc2" + i, d2) &&
-        s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG, "ph1" + i, d1) &&
-        s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG, "ph2" + i, d2)
+        s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG, "ch2" + i, d2)
     );
   }
 
   Assert.ok(
     s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_CRASH, "mc1" + i, d1) &&
       s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_CRASH, "mc2" + i, d2) &&
       s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_HANG, "mh1" + i, d1) &&
       s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_HANG, "mh2" + i, d2)
   );
 
   Assert.ok(!s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_CRASH, "cc1" + i, d1));
   Assert.ok(!s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_CRASH, "cc2" + i, d2));
   Assert.ok(!s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG, "ch1" + i, d1));
   Assert.ok(!s.addCrash(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG, "ch2" + i, d2));
 
-  Assert.ok(!s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH, "pc1" + i, d1));
-  Assert.ok(!s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH, "pc2" + i, d2));
-  Assert.ok(!s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG, "ph1" + i, d1));
-  Assert.ok(!s.addCrash(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG, "ph2" + i, d2));
-
-  // We preserve main process crashes and hangs. Content and plugin crashes and
+  // We preserve main process crashes and hangs. Content crashes and
   // hangs beyond should be discarded.
-  Assert.equal(s.crashesCount, 12 * s.HIGH_WATER_DAILY_THRESHOLD + 4);
+  Assert.equal(s.crashesCount, 8 * s.HIGH_WATER_DAILY_THRESHOLD + 4);
 
   let crashes = s.getCrashesOfType(PROCESS_TYPE_MAIN, CRASH_TYPE_CRASH);
   Assert.equal(crashes.length, 2 * s.HIGH_WATER_DAILY_THRESHOLD + 2);
   crashes = s.getCrashesOfType(PROCESS_TYPE_MAIN, CRASH_TYPE_HANG);
   Assert.equal(crashes.length, 2 * s.HIGH_WATER_DAILY_THRESHOLD + 2);
 
   crashes = s.getCrashesOfType(PROCESS_TYPE_CONTENT, CRASH_TYPE_CRASH);
   Assert.equal(crashes.length, 2 * s.HIGH_WATER_DAILY_THRESHOLD);
   crashes = s.getCrashesOfType(PROCESS_TYPE_CONTENT, CRASH_TYPE_HANG);
   Assert.equal(crashes.length, 2 * s.HIGH_WATER_DAILY_THRESHOLD);
 
-  crashes = s.getCrashesOfType(PROCESS_TYPE_PLUGIN, CRASH_TYPE_CRASH);
-  Assert.equal(crashes.length, 2 * s.HIGH_WATER_DAILY_THRESHOLD);
-  crashes = s.getCrashesOfType(PROCESS_TYPE_PLUGIN, CRASH_TYPE_HANG);
-  Assert.equal(crashes.length, 2 * s.HIGH_WATER_DAILY_THRESHOLD);
-
   // But raw counts should be preserved.
   let day1 = dateToDays(d1);
   let day2 = dateToDays(d2);
   Assert.ok(s._countsByDay.has(day1));
   Assert.ok(s._countsByDay.has(day2));
 
   Assert.equal(
     s._countsByDay.get(day1).get(PROCESS_TYPE_MAIN + "-" + CRASH_TYPE_CRASH),
@@ -555,25 +480,16 @@ add_task(async function test_high_water(
     s._countsByDay.get(day1).get(PROCESS_TYPE_CONTENT + "-" + CRASH_TYPE_CRASH),
     s.HIGH_WATER_DAILY_THRESHOLD + 1
   );
   Assert.equal(
     s._countsByDay.get(day1).get(PROCESS_TYPE_CONTENT + "-" + CRASH_TYPE_HANG),
     s.HIGH_WATER_DAILY_THRESHOLD + 1
   );
 
-  Assert.equal(
-    s._countsByDay.get(day1).get(PROCESS_TYPE_PLUGIN + "-" + CRASH_TYPE_CRASH),
-    s.HIGH_WATER_DAILY_THRESHOLD + 1
-  );
-  Assert.equal(
-    s._countsByDay.get(day1).get(PROCESS_TYPE_PLUGIN + "-" + CRASH_TYPE_HANG),
-    s.HIGH_WATER_DAILY_THRESHOLD + 1
-  );
-
   await s.save();
   await s.load();
 
   Assert.ok(s._countsByDay.has(day1));
   Assert.ok(s._countsByDay.has(day2));
 
   Assert.equal(
     s._countsByDay.get(day1).get(PROCESS_TYPE_MAIN + "-" + CRASH_TYPE_CRASH),
@@ -587,25 +503,16 @@ add_task(async function test_high_water(
   Assert.equal(
     s._countsByDay.get(day1).get(PROCESS_TYPE_CONTENT + "-" + CRASH_TYPE_CRASH),
     s.HIGH_WATER_DAILY_THRESHOLD + 1
   );
   Assert.equal(
     s._countsByDay.get(day1).get(PROCESS_TYPE_CONTENT + "-" + CRASH_TYPE_HANG),
     s.HIGH_WATER_DAILY_THRESHOLD + 1
   );
-
-  Assert.equal(
-    s._countsByDay.get(day1).get(PROCESS_TYPE_PLUGIN + "-" + CRASH_TYPE_CRASH),
-    s.HIGH_WATER_DAILY_THRESHOLD + 1
-  );
-  Assert.equal(
-    s._countsByDay.get(day1).get(PROCESS_TYPE_PLUGIN + "-" + CRASH_TYPE_HANG),
-    s.HIGH_WATER_DAILY_THRESHOLD + 1
-  );
 });
 
 add_task(async function test_addSubmission() {
   let s = await getStore();
 
   Assert.ok(
     s.addCrash(PROCESS_TYPE_MAIN, CRASH_TYPE_CRASH, "crash1", DUMMY_DATE)
   );
--- a/toolkit/components/telemetry/tests/unit/TelemetryEnvironmentTesting.jsm
+++ b/toolkit/components/telemetry/tests/unit/TelemetryEnvironmentTesting.jsm
@@ -44,22 +44,16 @@ const PARTNER_ID = "NicePartner-ID-3785"
 const PROFILE_RESET_DATE_MS = Date.now();
 // The profile creation date, in milliseconds (Yesterday).
 const PROFILE_FIRST_USE_MS = PROFILE_RESET_DATE_MS - MILLISECONDS_PER_DAY;
 const PROFILE_CREATION_DATE_MS = PROFILE_FIRST_USE_MS - MILLISECONDS_PER_DAY;
 
 const GFX_VENDOR_ID = "0xabcd";
 const GFX_DEVICE_ID = "0x1234";
 
-const FLASH_PLUGIN_NAME = "Shockwave Flash";
-const FLASH_PLUGIN_DESC = "A mock flash plugin";
-const FLASH_PLUGIN_VERSION = "\u201c1.1.1.1\u201d";
-const PLUGIN_MIME_TYPE1 = "application/x-shockwave-flash";
-const PLUGIN_MIME_TYPE2 = "text/plain";
-
 const EXPECTED_HDD_FIELDS = ["profile", "binary", "system"];
 
 // Valid attribution code to write so that settings.attribution can be tested.
 const ATTRIBUTION_CODE = "source%3Dgoogle.com";
 
 function truncateToDays(aMsec) {
   return Math.floor(aMsec / MILLISECONDS_PER_DAY);
 }
@@ -98,106 +92,31 @@ var SysInfo = {
 
   get processInfo() {
     return this._genuine.QueryInterface(Ci.nsISystemInfo).processInfo;
   },
 
   QueryInterface: ChromeUtils.generateQI(["nsIPropertyBag2", "nsISystemInfo"]),
 };
 
-const pluginHost = Cc["@mozilla.org/plugin/host;1"].getService(
-  Ci.nsIPluginHost
-);
-
-/**
- * Used to mock plugin tags in our fake plugin host.
- */
-class PluginTag {
-  constructor(aName, aDescription, aVersion, aEnabled) {
-    this.mimeTypes = [PLUGIN_MIME_TYPE1, PLUGIN_MIME_TYPE2];
-    this.pluginTag = pluginHost.createFakePlugin({
-      handlerURI: "resource://fake-plugin/${Math.random()}.xhtml",
-      mimeEntries: this.mimeTypes.map(type => ({ type })),
-      name: aName,
-      description: aDescription,
-      fileName: `${aName}.so`,
-      version: aVersion,
-    });
-    this.name = aName;
-    this.description = aDescription;
-    this.version = aVersion;
-    this.disabled = !aEnabled;
-  }
-
-  get disabled() {
-    return this.pluginTag.enabledState == Ci.nsIPluginTag.STATE_DISABLED;
-  }
-
-  set disabled(val) {
-    this.pluginTag.enabledState =
-      Ci.nsIPluginTag[val ? "STATE_DISABLED" : "STATE_CLICKTOPLAY"];
-  }
-
-  getMimeTypes() {
-    return this.mimeTypes;
-  }
-}
-
-// A container for the plugins handled by the fake plugin host.
-var gInstalledPlugins = [
-  new PluginTag("Java", "A mock Java plugin", "1.0", false /* Disabled */),
-  new PluginTag(
-    FLASH_PLUGIN_NAME,
-    FLASH_PLUGIN_DESC,
-    FLASH_PLUGIN_VERSION,
-    true
-  ),
-];
-
-// A fake plugin host for testing plugin telemetry environment.
-var PluginHost = {
-  getPluginTags() {
-    return gInstalledPlugins.map(plugin => plugin.pluginTag);
-  },
-
-  QueryInterface: ChromeUtils.generateQI(["nsIPluginHost"]),
-};
-
 /**
  * TelemetryEnvironmentTesting - tools for testing the telemetry environment
  * reporting.
  */
 var TelemetryEnvironmentTesting = {
   EXPECTED_HDD_FIELDS,
-  FLASH_PLUGIN_NAME,
-  FLASH_PLUGIN_DESC,
-  FLASH_PLUGIN_VERSION,
-  PLUGIN_MIME_TYPE1,
-  PLUGIN_MIME_TYPE2,
 
   init(appInfo) {
     this.appInfo = appInfo;
   },
 
   setSysInfoOverrides(overrides) {
     SysInfo.overrides = overrides;
   },
 
-  addPlugin(name, description, version, enabled) {
-    gInstalledPlugins.push(new PluginTag(name, description, version, enabled));
-  },
-
-  removePlugin(name) {
-    let plugin = gInstalledPlugins.find(p => p.name == name);
-    Assert.ok(plugin, "The test plugin must exist.");
-
-    // Remove it from the PluginHost.
-    gInstalledPlugins = gInstalledPlugins.filter(p => p != plugin);
-  },
-
   spoofGfxAdapter() {
     try {
       let gfxInfo = Cc["@mozilla.org/gfx/info;1"].getService(
         Ci.nsIGfxInfoDebug
       );
       gfxInfo.fireTestProcess();
       gfxInfo.spoofVendorID(GFX_VENDOR_ID);
       gfxInfo.spoofDeviceID(GFX_DEVICE_ID);
@@ -245,20 +164,16 @@ var TelemetryEnvironmentTesting = {
       AttributionCode._clearCache();
     }
   },
 
   registerFakeSysInfo() {
     MockRegistrar.register("@mozilla.org/system-info;1", SysInfo);
   },
 
-  registerFakePluginHost() {
-    MockRegistrar.register("@mozilla.org/plugin/host;1", PluginHost);
-  },
-
   /**
    * Check that a value is a string and not empty.
    *
    * @param aValue The variable to check.
    * @return True if |aValue| has type "string" and is not empty, False otherwise.
    */
   checkString(aValue) {
     return typeof aValue == "string" && aValue != "";
@@ -811,42 +726,16 @@ var TelemetryEnvironmentTesting = {
     }
 
     if (!partialRecord) {
       // We check "description" separately, as it can be null.
       Assert.ok(this.checkNullOrString(data.description));
     }
   },
 
-  checkPlugin(data) {
-    const EXPECTED_PLUGIN_FIELDS_TYPES = {
-      name: "string",
-      version: "string",
-      description: "string",
-      blocklisted: "boolean",
-      disabled: "boolean",
-      clicktoplay: "boolean",
-      updateDay: "number",
-    };
-
-    for (let f in EXPECTED_PLUGIN_FIELDS_TYPES) {
-      Assert.ok(f in data, f + " must be available.");
-      Assert.equal(
-        typeof data[f],
-        EXPECTED_PLUGIN_FIELDS_TYPES[f],
-        f + " must have the correct type."
-      );
-    }
-
-    Assert.ok(Array.isArray(data.mimeTypes));
-    for (let type of data.mimeTypes) {
-      Assert.ok(this.checkString(type));
-    }
-  },
-
   checkTheme(data) {
     const EXPECTED_THEME_FIELDS_TYPES = {
       id: "string",
       blocklisted: "boolean",
       name: "string",
       userDisabled: "boolean",
       appDisabled: "boolean",
       version: "string",
@@ -874,22 +763,17 @@ var TelemetryEnvironmentTesting = {
     if (data.version) {
       Assert.equal(typeof data.version, "string");
     }
     Assert.equal(typeof data.userDisabled, "boolean");
     Assert.equal(typeof data.applyBackgroundUpdates, "number");
   },
 
   checkAddonsSection(data, expectBrokenAddons, partialAddonsRecords) {
-    const EXPECTED_FIELDS = [
-      "activeAddons",
-      "theme",
-      "activePlugins",
-      "activeGMPlugins",
-    ];
+    const EXPECTED_FIELDS = ["activeAddons", "theme", "activeGMPlugins"];
 
     Assert.ok(
       "addons" in data,
       "There must be an addons section in Environment."
     );
     for (let f of EXPECTED_FIELDS) {
       Assert.ok(f in data.addons, f + " must be available.");
     }
@@ -902,22 +786,16 @@ var TelemetryEnvironmentTesting = {
       }
     }
 
     // Check "theme" structure.
     if (Object.keys(data.addons.theme).length !== 0) {
       this.checkTheme(data.addons.theme);
     }
 
-    // Check the active plugins.
-    Assert.ok(Array.isArray(data.addons.activePlugins));
-    for (let plugin of data.addons.activePlugins) {
-      this.checkPlugin(plugin);
-    }
-
     // Check active GMPlugins
     let activeGMPlugins = data.addons.activeGMPlugins;
     for (let gmPlugin in activeGMPlugins) {
       this.checkActiveGMPlugin(activeGMPlugins[gmPlugin]);
     }
   },
 
   checkEnvironmentData(data, options = {}) {
--- a/toolkit/components/telemetry/tests/unit/test_TelemetryEnvironment.js
+++ b/toolkit/components/telemetry/tests/unit/test_TelemetryEnvironment.js
@@ -33,18 +33,16 @@ async function installXPIFromURL(url) {
 
 // The webserver hosting the addons.
 var gHttpServer = null;
 // The URL of the webserver root.
 var gHttpRoot = null;
 // The URL of the data directory, on the webserver.
 var gDataRoot = null;
 
-const PLUGIN_UPDATED_TOPIC = "plugins-list-updated";
-
 function MockAddonWrapper(aAddon) {
   this.addon = aAddon;
 }
 MockAddonWrapper.prototype = {
   get id() {
     return this.addon.id;
   },
 
@@ -169,20 +167,17 @@ add_task(async function setup() {
   await AddonTestUtils.promiseShutdownManager();
   await AddonTestUtils.overrideBuiltIns({ system: [] });
   AddonTestUtils.addonStartup.remove(true);
   await AddonTestUtils.promiseStartupManager();
   // Override ExtensionXPCShellUtils.jsm's overriding of the pref as the
   // search service needs it.
   Services.prefs.clearUserPref("services.settings.default_bucket");
 
-  // Register a fake plugin host for consistent flash version data.
-  TelemetryEnvironmentTesting.registerFakePluginHost();
-
-  // Setup a webserver to serve Addons, Plugins, etc.
+  // Setup a webserver to serve Addons, etc.
   gHttpServer = new HttpServer();
   gHttpServer.start(-1);
   let port = gHttpServer.identity.primaryPort;
   gHttpRoot = "http://localhost:" + port + "/";
   gDataRoot = gHttpRoot + "data/";
   gHttpServer.registerDirectory("/data/", do_get_cwd());
   registerCleanupFunction(() => gHttpServer.stop(() => {}));
 
@@ -493,96 +488,16 @@ add_task(async function test_addonsWatch
 
   Assert.equal(
     receivedNotifications,
     EXPECTED_NOTIFICATIONS,
     "We must only receive the notifications we expect."
   );
 });
 
-add_task(async function test_pluginsWatch_Add() {
-  if (!gIsFirefox) {
-    Assert.ok(true, "Skipping: there is no Plugin Manager on Android.");
-    return;
-  }
-
-  Assert.equal(
-    TelemetryEnvironment.currentEnvironment.addons.activePlugins.length,
-    1
-  );
-
-  TelemetryEnvironmentTesting.addPlugin(
-    PLUGIN2_NAME,
-    PLUGIN2_DESC,
-    PLUGIN2_VERSION,
-    true
-  );
-
-  let receivedNotifications = 0;
-  let callback = (reason, data) => {
-    receivedNotifications++;
-  };
-  TelemetryEnvironment.registerChangeListener("testWatchPlugins_Add", callback);
-
-  Services.obs.notifyObservers(null, PLUGIN_UPDATED_TOPIC);
-
-  await ContentTaskUtils.waitForCondition(() => {
-    return (
-      TelemetryEnvironment.currentEnvironment.addons.activePlugins.length == 2
-    );
-  });
-
-  TelemetryEnvironment.unregisterChangeListener("testWatchPlugins_Add");
-
-  Assert.equal(
-    receivedNotifications,
-    0,
-    "We must not receive any notifications."
-  );
-});
-
-add_task(async function test_pluginsWatch_Remove() {
-  if (!gIsFirefox) {
-    Assert.ok(true, "Skipping: there is no Plugin Manager on Android.");
-    return;
-  }
-
-  Assert.equal(
-    TelemetryEnvironment.currentEnvironment.addons.activePlugins.length,
-    2
-  );
-
-  TelemetryEnvironmentTesting.removePlugin(PLUGIN2_NAME);
-
-  let receivedNotifications = 0;
-  let callback = () => {
-    receivedNotifications++;
-  };
-  TelemetryEnvironment.registerChangeListener(
-    "testWatchPlugins_Remove",
-    callback
-  );
-
-  Services.obs.notifyObservers(null, PLUGIN_UPDATED_TOPIC);
-
-  await ContentTaskUtils.waitForCondition(() => {
-    return (
-      TelemetryEnvironment.currentEnvironment.addons.activePlugins.length == 1
-    );
-  });
-
-  TelemetryEnvironment.unregisterChangeListener("testWatchPlugins_Remove");
-
-  Assert.equal(
-    receivedNotifications,
-    0,
-    "We must not receive any notifications."
-  );
-});
-
 add_task(async function test_addonsWatch_NotInterestingChange() {
   // We are not interested to dictionary addons changes.
   const DICTIONARY_ADDON_INSTALL_URL = gDataRoot + "dictionary.xpi";
   const INTERESTING_ADDON_INSTALL_URL = gDataRoot + "restartless.xpi";
 
   let receivedNotification = false;
   let deferred = PromiseUtils.defer();
   TelemetryEnvironment.registerChangeListener("testNotInteresting", () => {
@@ -608,17 +523,17 @@ add_task(async function test_addonsWatch
 
   TelemetryEnvironment.unregisterChangeListener("testNotInteresting");
 
   dictionaryAddon.uninstall();
   await interestingAddon.startupPromise;
   interestingAddon.uninstall();
 });
 
-add_task(async function test_addonsAndPlugins() {
+add_task(async function test_addons() {
   const ADDON_INSTALL_URL = gDataRoot + "restartless.xpi";
   const ADDON_ID = "tel-restartless-webext@tests.mozilla.org";
   const ADDON_INSTALL_DATE = truncateToDays(Date.now());
   const EXPECTED_ADDON_DATA = {
     blocklisted: false,
     description: "A restartless addon which gets enabled without a reboot.",
     name: "XPI Telemetry Restartless Test",
     userDisabled: false,
@@ -671,25 +586,16 @@ add_task(async function test_addonsAndPl
     installDay: WEBEXTENSION_ADDON_INSTALL_DATE,
     updateDay: WEBEXTENSION_ADDON_INSTALL_DATE,
     signedState: AddonManager.SIGNEDSTATE_PRIVILEGED,
     isSystem: false,
     isWebExtension: true,
     multiprocessCompatible: true,
   };
 
-  const EXPECTED_PLUGIN_DATA = {
-    name: TelemetryEnvironmentTesting.FLASH_PLUGIN_NAME,
-    version: TelemetryEnvironmentTesting.FLASH_PLUGIN_VERSION,
-    description: TelemetryEnvironmentTesting.FLASH_PLUGIN_DESC,
-    blocklisted: false,
-    disabled: false,
-    clicktoplay: true,
-  };
-
   let deferred = PromiseUtils.defer();
   TelemetryEnvironment.registerChangeListener(
     "test_WebExtension",
     (reason, data) => {
       Assert.equal(reason, "addons-changed");
       deferred.resolve();
     }
   );
@@ -760,44 +666,16 @@ add_task(async function test_addonsAndPl
       targetWebExtensionAddon[f],
       EXPECTED_WEBEXTENSION_ADDON_DATA[f],
       f + " must have the correct value."
     );
   }
 
   await webextension.unload();
 
-  // Check plugin data.
-  Assert.equal(
-    data.addons.activePlugins.length,
-    1,
-    "We must have only one active plugin."
-  );
-  let targetPlugin = data.addons.activePlugins[0];
-  for (let f in EXPECTED_PLUGIN_DATA) {
-    Assert.equal(
-      targetPlugin[f],
-      EXPECTED_PLUGIN_DATA[f],
-      f + " must have the correct value."
-    );
-  }
-
-  // Check plugin mime types.
-  Assert.ok(
-    targetPlugin.mimeTypes.find(
-      m => m == TelemetryEnvironmentTesting.PLUGIN_MIME_TYPE1
-    )
-  );
-  Assert.ok(
-    targetPlugin.mimeTypes.find(
-      m => m == TelemetryEnvironmentTesting.PLUGIN_MIME_TYPE2
-    )
-  );
-  Assert.ok(!targetPlugin.mimeTypes.find(m => m == "Not There."));
-
   // Uninstall the addon.
   await addon.startupPromise;
   await addon.uninstall();
 });
 
 add_task(async function test_signedAddon() {
   AddonTestUtils.useRealCertChecks = true;
 
--- a/toolkit/components/telemetry/tests/unit/test_TelemetryEnvironment_search.js
+++ b/toolkit/components/telemetry/tests/unit/test_TelemetryEnvironment_search.js
@@ -63,20 +63,17 @@ add_task(async function setup() {
   await AddonTestUtils.promiseShutdownManager();
   await AddonTestUtils.overrideBuiltIns({ system: [] });
   AddonTestUtils.addonStartup.remove(true);
   await AddonTestUtils.promiseStartupManager();
   // Override ExtensionXPCShellUtils.jsm's overriding of the pref as the
   // search service needs it.
   Services.prefs.clearUserPref("services.settings.default_bucket");
 
-  // Register a fake plugin host for consistent flash version data.
-  TelemetryEnvironmentTesting.registerFakePluginHost();
-
-  // Setup a webserver to serve Addons, Plugins, etc.
+  // Setup a webserver to serve Addons, etc.
   gHttpServer = new HttpServer();
   gHttpServer.start(-1);
   let port = gHttpServer.identity.primaryPort;
   gHttpRoot = "http://localhost:" + port + "/";
   gDataRoot = gHttpRoot + "data/";
   gHttpServer.registerDirectory("/data/", do_get_cwd());
   registerCleanupFunction(() => gHttpServer.stop(() => {}));
 
--- a/toolkit/content/tests/browser/head.js
+++ b/toolkit/content/tests/browser/head.js
@@ -133,54 +133,16 @@ async function waitForTabPlayingEvent(ta
           return true;
         }
         return false;
       }
     );
   }
 }
 
-function getTestPlugin(pluginName) {
-  var ph = SpecialPowers.Cc["@mozilla.org/plugin/host;1"].getService(
-    SpecialPowers.Ci.nsIPluginHost
-  );
-  var tags = ph.getPluginTags();
-  var name = pluginName || "Test Plug-in";
-  for (var tag of tags) {
-    if (tag.name == name) {
-      return tag;
-    }
-  }
-
-  ok(false, "Could not find plugin tag with plugin name '" + name + "'");
-  return null;
-}
-
-async function setTestPluginEnabledState(newEnabledState, pluginName) {
-  var oldEnabledState = await SpecialPowers.setTestPluginEnabledState(
-    newEnabledState,
-    pluginName
-  );
-  if (!oldEnabledState) {
-    return;
-  }
-  var plugin = getTestPlugin(pluginName);
-  // Run a nested event loop to wait for the preference change to
-  // propagate to the child. Yuck!
-  SpecialPowers.Services.tm.spinEventLoopUntil(
-    "Test(browser/head.js:setTestPluginEnabledState)",
-    () => {
-      return plugin.enabledState == newEnabledState;
-    }
-  );
-  SimpleTest.registerCleanupFunction(function() {
-    return SpecialPowers.setTestPluginEnabledState(oldEnabledState, pluginName);
-  });
-}
-
 function disable_non_test_mouse(disable) {
   let utils = window.windowUtils;
   utils.disableNonTestMouseEvents(disable);
 }
 
 function hover_icon(icon, tooltip) {
   disable_non_test_mouse(true);
 
--- a/toolkit/mozapps/extensions/internal/AddonTestUtils.jsm
+++ b/toolkit/mozapps/extensions/internal/AddonTestUtils.jsm
@@ -204,21 +204,16 @@ class MockBlocklist {
     if (state != Ci.nsIBlocklistService.STATE_NOT_BLOCKED) {
       return {
         state,
         url: "http://example.com/",
       };
     }
     return null;
   }
-
-  async getPluginBlocklistState(plugin, version, appVersion, toolkitVersion) {
-    await new Promise(r => setTimeout(r, 150));
-    return Ci.nsIBlocklistService.STATE_NOT_BLOCKED;
-  }
 }
 
 MockBlocklist.prototype.QueryInterface = ChromeUtils.generateQI([
   "nsIBlocklistService",
 ]);
 
 class AddonsList {
   constructor(file) {
@@ -784,34 +779,31 @@ var AddonTestUtils = {
   /**
    * Load the data from the specified files into the *real* blocklist providers.
    * Loads using loadBlocklistRawData, which will treat this as an update.
    *
    * @param {nsIFile} dir
    *        The directory in which the files live.
    * @param {string} prefix
    *        a prefix for the files which ought to be loaded.
-   *        This method will suffix -extensions.json and -plugins.json
-   *        to the prefix it is given, and attempt to load both.
-   *        Insofar as either exists, their data will be dumped into
-   *        the respective store, and the respective update handlers
+   *        This method will suffix -extensions.json
+   *        to the prefix it is given, and attempt to load it.
+   *        If it exists, its data will be dumped into
+   *        the respective store, and the update handler
    *        will be called.
    */
   async loadBlocklistData(dir, prefix) {
     let loadedData = {};
-    for (let fileSuffix of ["extensions", "plugins"]) {
-      const fileName = `${prefix}-${fileSuffix}.json`;
-      let jsonStr = await OS.File.read(OS.Path.join(dir.path, fileName), {
-        encoding: "UTF-8",
-      }).catch(() => {});
-      if (!jsonStr) {
-        continue;
-      }
+    let fileSuffix = "extensions";
+    const fileName = `${prefix}-${fileSuffix}.json`;
+    let jsonStr = await OS.File.read(OS.Path.join(dir.path, fileName), {
+      encoding: "UTF-8",
+    }).catch(() => {});
+    if (jsonStr) {
       this.info(`Loaded ${fileName}`);
-
       loadedData[fileSuffix] = JSON.parse(jsonStr);
     }
     return this.loadBlocklistRawData(loadedData);
   },
 
   /**
    * Load the following data into the *real* blocklist providers.
    * While `overrideBlocklist` replaces the blocklist entirely with a mock
@@ -825,17 +817,16 @@ var AddonTestUtils = {
   async loadBlocklistRawData(data) {
     const bsPass = ChromeUtils.import(
       "resource://gre/modules/Blocklist.jsm",
       null
     );
     const blocklistMapping = {
       extensions: bsPass.ExtensionBlocklistRS,
       extensionsMLBF: bsPass.ExtensionBlocklistMLBF,
-      plugins: bsPass.PluginBlocklistRS,
     };
 
     // Since we load the specified test data, we shouldn't let the
     // packaged JSON dumps to interfere.
     const pref = "services.settings.load_dump";
     const backup = Services.prefs.getBoolPref(pref, null);
     Services.prefs.setBoolPref(pref, false);
     if (this.testScope) {
--- a/toolkit/mozapps/extensions/test/browser/browser.ini
+++ b/toolkit/mozapps/extensions/test/browser/browser.ini
@@ -1,11 +1,9 @@
 [DEFAULT]
-prefs =
-  plugin.load_flash_only=false
 tags = addons
 support-files =
   addons/browser_dragdrop1.xpi
   addons/browser_dragdrop1.zip
   addons/browser_dragdrop2.xpi
   addons/browser_dragdrop2.zip
   addons/browser_dragdrop_incompat.xpi
   addons/browser_installssl.xpi
@@ -39,18 +37,16 @@ generated-files =
   addons/browser_dragdrop2.zip
   addons/browser_dragdrop_incompat.xpi
   addons/browser_installssl.xpi
   addons/browser_theme.xpi
   addons/options_signed.xpi
 
 [browser_about_debugging_link.js]
 [browser_addon_list_reordering.js]
-[browser_bug523784.js]
-skip-if = (!debug && os == 'win') #Bug 1489496
 [browser_bug572561.js]
 [browser_checkAddonCompatibility.js]
 [browser_dragdrop.js]
 skip-if = true # Bug 1626824
 [browser_permission_prompt.js]
 [browser_file_xpi_no_process_switch.js]
 [browser_globalwarnings.js]
 [browser_gmpProvider.js]
deleted file mode 100644
--- a/toolkit/mozapps/extensions/test/browser/browser_bug523784.js
+++ /dev/null
@@ -1,153 +0,0 @@
-/* Any copyright is dedicated to the Public Domain.
-   http://creativecommons.org/publicdomain/zero/1.0/ */
-
-const URI_BLOCKLIST_DIALOG =
-  "chrome://mozapps/content/extensions/blocklist.xhtml";
-
-// This tests that the blocklist dialog still affects soft-blocked add-ons
-// if the user clicks the "Restart Later" button. It also ensures that the
-// "Cancel" button is correctly renamed (to "Restart Later").
-var args = {
-  restart: false,
-  list: [
-    {
-      name: "Bug 523784 softblocked addon",
-      version: "1",
-      icon: "chrome://global/skin/icons/plugin.svg",
-      disable: false,
-      blocked: false,
-      url: "http://example.com/bug523784_1",
-    },
-  ],
-};
-
-function test() {
-  waitForExplicitFinish();
-
-  let windowObserver = function(win, aTopic, aData) {
-    if (aTopic != "domwindowopened") {
-      return;
-    }
-
-    Services.ww.unregisterNotification(windowObserver);
-
-    win.addEventListener(
-      "load",
-      function() {
-        executeSoon(() => bug523784_test1(win));
-      },
-      { once: true }
-    );
-  };
-  Services.ww.registerNotification(windowObserver);
-
-  args.wrappedJSObject = args;
-  Services.ww.openWindow(
-    null,
-    URI_BLOCKLIST_DIALOG,
-    "",
-    "chrome,centerscreen,dialog,titlebar",
-    args
-  );
-}
-
-function bug523784_test1(win) {
-  let bundle = Services.strings.createBundle(
-    "chrome://mozapps/locale/update/updates.properties"
-  );
-  let cancelButton = win.document
-    .getElementById("BlocklistDialog")
-    .getButton("cancel");
-  let moreInfoLink = win.document.getElementById("moreInfo");
-
-  is(
-    cancelButton.getAttribute("label"),
-    bundle.GetStringFromName("restartLaterButton"),
-    "Text should be changed on Cancel button"
-  );
-  is(
-    cancelButton.getAttribute("accesskey"),
-    bundle.GetStringFromName("restartLaterButton.accesskey"),
-    "Accesskey should also be changed on Cancel button"
-  );
-  is(
-    moreInfoLink.getAttribute("href"),
-    "http://example.com/bug523784_1",
-    "More Info link should link to a detailed blocklist page."
-  );
-  let windowObserver = function(aSubject, aTopic, aData) {
-    if (aTopic != "domwindowclosed") {
-      return;
-    }
-
-    Services.ww.unregisterNotification(windowObserver);
-
-    ok(args.list[0].disable, "Should be blocking add-on");
-    ok(!args.restart, "Should not restart browser immediately");
-
-    executeSoon(bug523784_test2);
-  };
-  Services.ww.registerNotification(windowObserver);
-
-  cancelButton.doCommand();
-}
-
-function bug523784_test2(win) {
-  let windowObserver = function(win, aTopic, aData) {
-    if (aTopic != "domwindowopened") {
-      return;
-    }
-
-    Services.ww.unregisterNotification(windowObserver);
-    win.addEventListener(
-      "load",
-      function() {
-        executeSoon(function() {
-          let moreInfoLink = win.document.getElementById("moreInfo");
-          let cancelButton = win.document
-            .getElementById("BlocklistDialog")
-            .getButton("cancel");
-          is(
-            moreInfoLink.getAttribute("href"),
-            Services.urlFormatter.formatURLPref(
-              "extensions.blocklist.detailsURL"
-            ),
-            "More Info link should link to the general blocklist page."
-          );
-          cancelButton.doCommand();
-          executeSoon(finish);
-        });
-      },
-      { once: true }
-    );
-  };
-  Services.ww.registerNotification(windowObserver);
-
-  // Add 2 more addons to the blocked list to check that the more info link
-  // points to the general blocked list page.
-  args.list.push({
-    name: "Bug 523784 softblocked addon 2",
-    version: "2",
-    icon: "chrome://global/skin/icons/plugin.svg",
-    disable: false,
-    blocked: false,
-    url: "http://example.com/bug523784_2",
-  });
-  args.list.push({
-    name: "Bug 523784 softblocked addon 3",
-    version: "4",
-    icon: "chrome://global/skin/icons/plugin.svg",
-    disable: false,
-    blocked: false,
-    url: "http://example.com/bug523784_3",
-  });
-
-  args.wrappedJSObject = args;
-  Services.ww.openWindow(
-    null,
-    URI_BLOCKLIST_DIALOG,
-    "",
-    "chrome,centerscreen,dialog,titlebar",
-    args
-  );
-}
--- a/toolkit/mozapps/extensions/test/browser/browser_gmpProvider.js
+++ b/toolkit/mozapps/extensions/test/browser/browser_gmpProvider.js
@@ -291,27 +291,16 @@ add_task(async function testInstalledDet
 add_task(async function testInstalledGlobalEmeDisabled() {
   let win = await loadInitialView("plugin");
   gPrefs.setBoolPref(GMPScope.GMPPrefs.KEY_EME_ENABLED, false);
 
   for (let addon of gMockAddons) {
     let item = getAddonCard(win, addon.id);
     if (addon.isEME) {
       is(item.parentNode.getAttribute("section"), "1", "Should be disabled");
-      // Open the options menu (needed to check the disabled buttons).
-      const pluginOptions = item.querySelector("plugin-options");
-      pluginOptions.querySelector("panel-list").open = true;
-      const askActivate = pluginOptions.querySelector(
-        "panel-item[action=ask-to-activate]"
-      );
-      ok(
-        askActivate.shadowRoot.querySelector("button").disabled,
-        "ask-to-activate should be disabled"
-      );
-      pluginOptions.querySelector("panel-list").open = false;
     } else {
       Assert.ok(item, "Got add-on element.");
     }
   }
 
   gPrefs.setBoolPref(GMPScope.GMPPrefs.KEY_EME_ENABLED, true);
   await closeView(win);
 });
--- a/toolkit/mozapps/extensions/test/browser/browser_html_warning_messages.js
+++ b/toolkit/mozapps/extensions/test/browser/browser_html_warning_messages.js
@@ -1,22 +1,16 @@
 /* Any copyright is dedicated to the Public Domain.
    http://creativecommons.org/publicdomain/zero/1.0/ */
 /* eslint max-len: ["error", 80] */
 
 "use strict";
 
 let gProvider;
-const {
-  STATE_BLOCKED,
-  STATE_OUTDATED,
-  STATE_SOFTBLOCKED,
-  STATE_VULNERABLE_NO_UPDATE,
-  STATE_VULNERABLE_UPDATE_AVAILABLE,
-} = Ci.nsIBlocklistService;
+const { STATE_BLOCKED, STATE_SOFTBLOCKED } = Ci.nsIBlocklistService;
 
 const brandBundle = Services.strings.createBundle(
   "chrome://branding/locale/brand.properties"
 );
 const appName = brandBundle.GetStringFromName("brandShortName");
 const appVersion = Services.appinfo.version;
 const SUPPORT_URL = Services.urlFormatter.formatURL(
   Services.prefs.getStringPref("app.support.baseURL")
@@ -274,73 +268,16 @@ add_task(async function testSoftBlocked(
   await checkMessageState(id, "extension", {
     linkText: "More Information",
     linkUrl,
     text: "Soft Blocked is known to cause security or stability issues.",
     type: "warning",
   });
 });
 
-add_task(async function testOutdated() {
-  let id = "outdated@mochi.test";
-  let linkUrl = "https://example.com/addon-blocked";
-  gProvider.createAddons([
-    {
-      blocklistState: STATE_OUTDATED,
-      blocklistURL: linkUrl,
-      id,
-      name: "Outdated",
-    },
-  ]);
-  await checkMessageState(id, "extension", {
-    linkText: "Update Now",
-    linkUrl,
-    text: "An important update is available for Outdated.",
-    type: "warning",
-  });
-});
-
-add_task(async function testVulnerableUpdate() {
-  let id = "vulnerable-update@mochi.test";
-  let linkUrl = "https://example.com/addon-blocked";
-  gProvider.createAddons([
-    {
-      blocklistState: STATE_VULNERABLE_UPDATE_AVAILABLE,
-      blocklistURL: linkUrl,
-      id,
-      name: "Vulnerable Update",
-    },
-  ]);
-  await checkMessageState(id, "extension", {
-    linkText: "Update Now",
-    linkUrl,
-    text: "Vulnerable Update is known to be vulnerable and should be updated.",
-    type: "error",
-  });
-});
-
-add_task(async function testVulnerableNoUpdate() {
-  let id = "vulnerable-no-update@mochi.test";
-  let linkUrl = "https://example.com/addon-blocked";
-  gProvider.createAddons([
-    {
-      blocklistState: STATE_VULNERABLE_NO_UPDATE,
-      blocklistURL: linkUrl,
-      id,
-      name: "Vulnerable No Update",
-    },
-  ]);
-  await checkMessageState(id, "extension", {
-    linkText: "More Information",
-    linkUrl,
-    text: "Vulnerable No Update is known to be vulnerable. Use with caution.",
-    type: "error",
-  });
-});
-
 add_task(async function testPluginInstalling() {
   let id = "plugin-installing@mochi.test";
   gProvider.createAddons([
     {
       id,
       isActive: true,
       isGMPlugin: true,
       isInstalled: false,
--- a/toolkit/mozapps/extensions/test/browser/head.js
+++ b/toolkit/mozapps/extensions/test/browser/head.js
@@ -659,19 +659,16 @@ function addCertOverrides() {
 function MockProvider() {
   this.addons = [];
   this.installs = [];
   this.types = [
     {
       id: "extension",
       name: "Extensions",
       uiPriority: 4000,
-      flags:
-        AddonManager.TYPE_UI_VIEW_LIST |
-        AddonManager.TYPE_SUPPORTS_UNDO_RESTARTLESS_UNINSTALL,
     },
   ];
 
   var self = this;
   registerCleanupFunction(function() {
     if (self.started) {
       self.unregister();
     }
@@ -1439,30 +1436,16 @@ function waitForCondition(condition, nex
     tries++;
   }, 100);
   let moveOn = function() {
     clearInterval(interval);
     nextTest();
   };
 }
 
-function getTestPluginTag() {
-  let ph = Cc["@mozilla.org/plugin/host;1"].getService(Ci.nsIPluginHost);
-  let tags = ph.getPluginTags();
-
-  // Find the test plugin
-  for (let i = 0; i < tags.length; i++) {
-    if (tags[i].name == "Test Plug-in") {
-      return tags[i];
-    }
-  }
-  ok(false, "Unable to find plugin");
-  return null;
-}
-
 // Wait for and then acknowledge (by pressing the primary button) the
 // given notification.
 function promiseNotification(id = "addon-webext-permissions") {
   if (
     !Services.prefs.getBoolPref("extensions.webextPermissionPrompts", false)
   ) {
     return Promise.resolve();
   }
--- a/toolkit/mozapps/extensions/test/xpcshell/data/test_pluginBlocklistCtp.xml
+++ b/toolkit/mozapps/extensions/test/xpcshell/data/test_pluginBlocklistCtp.xml
@@ -1,26 +1,26 @@
 <?xml version="1.0" encoding="UTF-8"?>
 
 <blocklist xmlns="http://www.mozilla.org/2006/addons-blocklist">
   <pluginItems>
     <pluginItem>
       <match name="name" exp="^test_plugin_0"/>
-      <versionRange minVersion="0" maxVersion="*" severity="0" vulnerabilitystatus="0"/>
+      <versionRange minVersion="0" maxVersion="*" severity="0"/>
     </pluginItem>
     <pluginItem>
       <match name="name" exp="^test_plugin_1"/>
-      <versionRange minVersion="0" maxVersion="*" severity="0" vulnerabilitystatus="1"/>
+      <versionRange minVersion="0" maxVersion="*" severity="0"/>
     </pluginItem>
     <pluginItem>
       <match name="name" exp="^test_plugin_2"/>
-      <versionRange minVersion="0" maxVersion="*" severity="0" vulnerabilitystatus="2"/>
+      <versionRange minVersion="0" maxVersion="*" severity="0"/>
     </pluginItem>
     <pluginItem>
       <match name="name" exp="^test_plugin_3"/>
-      <versionRange minVersion="0" maxVersion="*" vulnerabilitystatus="2"/>
+      <versionRange minVersion="0" maxVersion="*"/>
     </pluginItem>
     <pluginItem>
       <match name="name" exp="^test_plugin_4"/>
-      <versionRange minVersion="0" maxVersion="*" severity="1" vulnerabilitystatus="2"/>
+      <versionRange minVersion="0" maxVersion="*" severity="1"/>
     </pluginItem>
   </pluginItems>
 </blocklist>
--- a/toolkit/mozapps/extensions/test/xpcshell/data/test_pluginBlocklistCtpUndo.xml
+++ b/toolkit/mozapps/extensions/test/xpcshell/data/test_pluginBlocklistCtpUndo.xml
@@ -1,10 +1,10 @@
 <?xml version="1.0" encoding="UTF-8"?>
 
 <blocklist xmlns="http://www.mozilla.org/2006/addons-blocklist">
   <pluginItems>
     <pluginItem>
       <match name="name" exp="^Test Plug-in"/>
-      <versionRange minVersion="0" maxVersion="*" severity="0" vulnerabilitystatus="2"/>
+      <versionRange minVersion="0" maxVersion="*" severity="0"/>
     </pluginItem>
   </pluginItems>
 </blocklist>
--- a/toolkit/mozapps/extensions/test/xpcshell/head_addons.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/head_addons.js
@@ -1260,67 +1260,16 @@ async function saveJSON(aData, aFile) {
   info("Starting to save JSON file " + aFile);
   await OS.File.writeAtomic(
     aFile,
     new TextEncoder().encode(JSON.stringify(aData, null, 2))
   );
   info("Done saving JSON file " + aFile);
 }
 
-XPCOMUtils.defineLazyServiceGetter(
-  this,
-  "pluginHost",
-  "@mozilla.org/plugin/host;1",
-  "nsIPluginHost"
-);
-
-class MockPluginTag {
-  constructor(opts, enabledState = Ci.nsIPluginTag.STATE_ENABLED) {
-    this.pluginTag = pluginHost.createFakePlugin({
-      handlerURI: "resource://fake-plugin/${Math.random()}.xhtml",
-      mimeEntries: [{ type: "application/x-fake-plugin" }],
-      fileName: `${opts.name}.so`,
-      ...opts,
-    });
-    this.pluginTag.enabledState = enabledState;
-
-    this.name = opts.name;
-    this.version = opts.version;
-  }
-  async isBlocklisted() {
-    let state = await Blocklist.getPluginBlocklistState(this.pluginTag);
-    return state == Services.blocklist.STATE_BLOCKED;
-  }
-  get disabled() {
-    return this.pluginTag.enabledState == Ci.nsIPluginTag.STATE_DISABLED;
-  }
-  set disabled(val) {
-    this.enabledState =
-      Ci.nsIPluginTag[val ? "STATE_DISABLED" : "STATE_ENABLED"];
-  }
-  get enabledState() {
-    return this.pluginTag.enabledState;
-  }
-  set enabledState(val) {
-    this.pluginTag.enabledState = val;
-  }
-}
-
-function mockPluginHost(plugins) {
-  let PluginHost = {
-    getPluginTags() {
-      return plugins.map(p => p.pluginTag);
-    },
-
-    QueryInterface: ChromeUtils.generateQI(["nsIPluginHost"]),
-  };
-
-  MockRegistrar.register("@mozilla.org/plugin/host;1", PluginHost);
-}
-
 async function setInitialState(addon, initialState) {
   if (initialState.userDisabled) {
     await addon.disable();
   } else if (initialState.userDisabled === false) {
     await addon.enable();
   }
 }
 
--- a/toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_clients.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_clients.js
@@ -25,46 +25,41 @@ add_task(async function setup() {
     "XPCShell",
     "xpcshell@tests.mozilla.org",
     "1",
     ""
   );
 
   // This will initialize the remote settings clients for blocklists.
   BlocklistGlobal.ExtensionBlocklistRS.ensureInitialized();
-  BlocklistGlobal.PluginBlocklistRS.ensureInitialized();
   BlocklistGlobal.GfxBlocklistRS._ensureInitialized();
 
   gBlocklistClients = [
     {
       client: BlocklistGlobal.ExtensionBlocklistRS._client,
       testData: ["i808", "i720", "i539"],
     },
     {
-      client: BlocklistGlobal.PluginBlocklistRS._client,
-      testData: ["p1044", "p32", "p28"],
-    },
-    {
       client: BlocklistGlobal.GfxBlocklistRS._client,
       testData: ["g204", "g200", "g36"],
     },
   ];
 
   await promiseStartupManager();
 });
 
 add_task(
   async function test_initial_dump_is_loaded_as_synced_when_collection_is_empty() {
     for (let { client } of gBlocklistClients) {
       if (
         IS_ANDROID &&
         client.collectionName !=
           BlocklistGlobal.ExtensionBlocklistRS._client.collectionName
       ) {
-        // On Android we don't ship the dumps of plugins and gfx.
+        // On Android we don't ship the dumps of gfx.
         continue;
       }
       Assert.ok(
         await RemoteSettingsUtils.hasLocalDump(
           client.bucketName,
           client.collectionName
         )
       );
--- a/toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_targetapp_filter.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_targetapp_filter.js
@@ -28,72 +28,70 @@ function run_test() {
   AddonTestUtils.createAppInfo(
     "xpcshell@tests.mozilla.org",
     "XPCShell",
     "58",
     ""
   );
   // This will initialize the remote settings clients for blocklists,
   // with their specific options etc.
-  BlocklistGlobal.PluginBlocklistRS.ensureInitialized();
+  BlocklistGlobal.ExtensionBlocklistRS.ensureInitialized();
   // Obtain one of the instantiated client for our tests.
-  client = RemoteSettings("plugins", { bucketName: "blocklists" });
+  client = RemoteSettings("addons", { bucketName: "blocklists" });
 
   run_next_test();
 }
 
 add_task(async function test_supports_filter_expressions() {
   await createRecords([
     {
-      matchName: "Adobe Flex",
+      name: "My Extension",
       filter_expression: 'env.appinfo.ID == "xpcshell@tests.mozilla.org"',
     },
     {
-      matchName: "Adobe Flex",
+      name: "My Extension",
       filter_expression: "1 == 2",
     },
   ]);
 
   const list = await client.get();
   equal(list.length, 1);
 });
 add_task(clear_state);
 
 add_task(async function test_returns_all_without_target() {
   await createRecords([
     {
-      matchName: "Adobe Flex",
+      name: "My Extension",
     },
     {
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [],
     },
     {
-      matchName: "PDF reader",
+      name: "My Other Extension",
       versionRange: [
         {
           severity: 0,
-          vulnerabilityStatus: 1,
           targetApplication: [],
         },
       ],
     },
     {
-      matchName:
+      name:
         "Java(\\(TM\\))? Plug-in 11\\.(7[6-9]|[8-9]\\d|1([0-6]\\d|70))(\\.\\d+)?([^\\d\\._]|$)",
       versionRange: [
         {
           severity: 0,
-          vulnerabilityStatus: 1,
         },
       ],
       matchFilename: "libnpjp2\\.so",
     },
     {
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [],
           maxVersion: "1",
           minVersion: "0",
           severity: "1",
         },
       ],
@@ -104,52 +102,52 @@ add_task(async function test_returns_all
   equal(list.length, 5);
 });
 add_task(clear_state);
 
 add_task(async function test_returns_without_guid_or_with_matching_guid() {
   await createRecords([
     {
       willMatch: true,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [{}],
         },
       ],
     },
     {
       willMatch: false,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: "some-guid",
             },
           ],
         },
       ],
     },
     {
       willMatch: true,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: APP_ID,
             },
           ],
         },
       ],
     },
     {
       willMatch: true,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: TOOLKIT_ID,
             },
           ],
         },
@@ -164,88 +162,88 @@ add_task(async function test_returns_wit
 });
 add_task(clear_state);
 
 add_task(
   async function test_returns_without_app_version_or_with_matching_version() {
     await createRecords([
       {
         willMatch: true,
-        matchName: "foopydoo",
+        name: "foopydoo",
         versionRange: [
           {
             targetApplication: [
               {
                 guid: APP_ID,
               },
             ],
           },
         ],
       },
       {
         willMatch: true,
-        matchName: "foopydoo",
+        name: "foopydoo",
         versionRange: [
           {
             targetApplication: [
               {
                 guid: APP_ID,
                 minVersion: "0",
               },
             ],
           },
         ],
       },
       {
         willMatch: true,
-        matchName: "foopydoo",
+        name: "foopydoo",
         versionRange: [
           {
             targetApplication: [
               {
                 guid: APP_ID,
                 minVersion: "0",
                 maxVersion: "9999",
               },
             ],
           },
         ],
       },
       {
         willMatch: false,
-        matchName: "foopydoo",
+        name: "foopydoo",
         versionRange: [
           {
             targetApplication: [
               {
                 guid: APP_ID,
                 minVersion: "0",
                 maxVersion: "1",
               },
             ],
           },
         ],
       },
       {
         willMatch: true,
-        matchName: "foopydoo",
+        name: "foopydoo",
         versionRange: [
           {
             targetApplication: [
               {
                 guid: TOOLKIT_ID,
                 minVersion: "0",
               },
             ],
           },
         ],
       },
       {
         willMatch: true,
-        matchName: "foopydoo",
+        name: "foopydoo",
         versionRange: [
           {
             targetApplication: [
               {
                 guid: TOOLKIT_ID,
                 minVersion: "0",
                 maxVersion: "9999",
               },
@@ -263,17 +261,17 @@ add_task(
   }
 );
 add_task(clear_state);
 
 add_task(async function test_multiple_version_and_target_applications() {
   await createRecords([
     {
       willMatch: true,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: "other-guid",
             },
           ],
         },
@@ -285,17 +283,17 @@ add_task(async function test_multiple_ve
               maxVersion: "*",
             },
           ],
         },
       ],
     },
     {
       willMatch: true,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: "other-guid",
             },
           ],
         },
@@ -306,17 +304,17 @@ add_task(async function test_multiple_ve
               minVersion: "0",
             },
           ],
         },
       ],
     },
     {
       willMatch: false,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: APP_ID,
               maxVersion: "57.*",
             },
           ],
@@ -342,45 +340,45 @@ add_task(async function test_multiple_ve
   ok(list.every(e => e.willMatch));
 });
 add_task(clear_state);
 
 add_task(async function test_complex_version() {
   await createRecords([
     {
       willMatch: false,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: APP_ID,
               maxVersion: "57.*",
             },
           ],
         },
       ],
     },
     {
       willMatch: true,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: APP_ID,
               maxVersion: "9999.*",
             },
           ],
         },
       ],
     },
     {
       willMatch: true,
-      matchName: "foopydoo",
+      name: "foopydoo",
       versionRange: [
         {
           targetApplication: [
             {
               guid: APP_ID,
               minVersion: "19.0a1",
             },
           ],
--- a/toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_telemetry.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/rs-blocklist/test_blocklist_telemetry.js
@@ -38,30 +38,28 @@ add_task(async function test_setup() {
 });
 
 add_task(async function test_blocklist_lastModified_rs_scalars() {
   const now = Date.now();
 
   const lastEntryTimes = {
     addons: now - 5000,
     addons_mlbf: now - 4000,
-    plugins: now - 3000,
   };
 
   const lastEntryTimesUTC = {};
   const toUTC = t => new Date(t).toUTCString();
   for (const key of Object.keys(lastEntryTimes)) {
     lastEntryTimesUTC[key] = toUTC(lastEntryTimes[key]);
   }
 
   const {
     BlocklistTelemetry,
     ExtensionBlocklistRS,
     ExtensionBlocklistMLBF,
-    PluginBlocklistRS,
   } = ChromeUtils.import("resource://gre/modules/Blocklist.jsm", null);
 
   // Return a promise resolved when the recordRSBlocklistLastModified method
   // has been called (by temporarily replacing the method with a function that
   // calls the real method and then resolve the promise).
   function promiseScalarRecorded() {
     return new Promise(resolve => {
       let origFn = BlocklistTelemetry.recordRSBlocklistLastModified;
@@ -74,51 +72,40 @@ add_task(async function test_blocklist_l
     });
   }
 
   async function fakeRemoteSettingsSync(rsClient, lastModified) {
     await rsClient.db.importChanges({}, lastModified);
     await rsClient.emit("sync");
   }
 
-  info("Test RS plugins blocklist lastModified scalar");
-
-  await PluginBlocklistRS.ensureInitialized();
-  await Promise.all([
-    promiseScalarRecorded(),
-    fakeRemoteSettingsSync(PluginBlocklistRS._client, lastEntryTimes.plugins),
-  ]);
-
   assertTelemetryScalars({
     "blocklist.lastModified_rs_addons": undefined,
     "blocklist.lastModified_rs_addons_mlbf": undefined,
-    "blocklist.lastModified_rs_plugins": lastEntryTimesUTC.plugins,
   });
 
   info("Test RS addon blocklist lastModified scalar");
 
   await ExtensionBlocklistRS.ensureInitialized();
   await Promise.all([
     promiseScalarRecorded(),
     fakeRemoteSettingsSync(ExtensionBlocklistRS._client, lastEntryTimes.addons),
   ]);
 
   assertTelemetryScalars({
     "blocklist.lastModified_rs_addons": lastEntryTimesUTC.addons,
     "blocklist.lastModified_rs_addons_mlbf": undefined,
-    "blocklist.lastModified_rs_plugins": lastEntryTimesUTC.plugins,
   });
 
   await ExtensionBlocklistMLBF.ensureInitialized();
   await Promise.all([
     promiseScalarRecorded(),
     fakeRemoteSettingsSync(
       ExtensionBlocklistMLBF._client,
       lastEntryTimes.addons_mlbf
     ),
   ]);
 
   assertTelemetryScalars({
     "blocklist.lastModified_rs_addons": lastEntryTimesUTC.addons,
     "blocklist.lastModified_rs_addons_mlbf": lastEntryTimesUTC.addons_mlbf,
-    "blocklist.lastModified_rs_plugins": lastEntryTimesUTC.plugins,
   });
 });
deleted file mode 100644
--- a/toolkit/mozapps/extensions/test/xpcshell/test_duplicateplugins.js
+++ /dev/null
@@ -1,160 +0,0 @@
-/* Any copyright is dedicated to the Public Domain.
- * http://creativecommons.org/publicdomain/zero/1.0/
- */
-
-// This verifies that duplicate plugins are coalesced and maintain their ID
-// across restarts.
-
-class MockPlugin extends MockPluginTag {
-  constructor(opts) {
-    super(opts, opts.enabledState);
-    this.blocklisted = opts.blocklisted;
-  }
-}
-
-var PLUGINS = [
-  {
-    name: "Duplicate Plugin 1",
-    description: "A duplicate plugin",
-    version: "1",
-    blocklisted: false,
-    enabledState: Ci.nsIPluginTag.STATE_ENABLED,
-    filename: "/home/mozilla/.plugins/dupplugin1.so",
-  },
-  {
-    name: "Duplicate Plugin 1",
-    description: "A duplicate plugin",
-    version: "1",
-    blocklisted: false,
-    enabledState: Ci.nsIPluginTag.STATE_ENABLED,
-    filename: "/usr/lib/plugins/dupplugin1.so",
-  },
-  {
-    name: "Duplicate Plugin 2",
-    description: "Another duplicate plugin",
-    version: "1",
-    blocklisted: false,
-    enabledState: Ci.nsIPluginTag.STATE_ENABLED,
-    filename: "/home/mozilla/.plugins/dupplugin2.so",
-  },
-  {
-    name: "Duplicate Plugin 2",
-    description: "Another duplicate plugin",
-    version: "1",
-    blocklisted: false,
-    enabledState: Ci.nsIPluginTag.STATE_ENABLED,
-    filename: "/usr/lib/plugins/dupplugin2.so",
-  },
-  {
-    name: "Non-duplicate Plugin", // 3
-    description: "Not a duplicate plugin",
-    version: "1",
-    blocklisted: false,
-    enabledState: Ci.nsIPluginTag.STATE_ENABLED,
-    filename: "/home/mozilla/.plugins/dupplugin3.so",
-  },
-  {
-    name: "Non-duplicate Plugin", // 4
-    description: "Not a duplicate because the descriptions are different",
-    version: "1",
-    blocklisted: false,
-    enabledState: Ci.nsIPluginTag.STATE_ENABLED,
-    filename: "/usr/lib/plugins/dupplugin4.so",
-  },
-  {
-    name: "Another Non-duplicate Plugin", // 5
-    description: "Not a duplicate plugin",
-    version: "1",
-    blocklisted: false,
-    enabledState: Ci.nsIPluginTag.STATE_ENABLED,
-    filename: "/home/mozilla/.plugins/dupplugin5.so",
-  },
-].map(opts => new MockPlugin(opts));
-
-mockPluginHost(PLUGINS);
-
-var gPluginIDs = [null, null, null, null, null];
-
-async function run_test() {
-  do_test_pending();
-  createAppInfo("xpcshell@tests.mozilla.org", "XPCShell", "1", "1.9.2");
-  Services.prefs.setBoolPref("media.gmp-provider.enabled", false);
-
-  await promiseStartupManager();
-
-  run_test_1();
-}
-
-function found_plugin(aNum, aId) {
-  if (gPluginIDs[aNum]) {
-    do_throw("Found duplicate of plugin " + aNum);
-  }
-  gPluginIDs[aNum] = aId;
-}
-
-// Test that the plugins were coalesced and all appear in the returned list
-async function run_test_1() {
-  let aAddons = await AddonManager.getAddonsByTypes(["plugin"]);
-  Assert.equal(aAddons.length, 5);
-  aAddons.forEach(function(aAddon) {
-    if (aAddon.name == "Duplicate Plugin 1") {
-      found_plugin(0, aAddon.id);
-      Assert.equal(aAddon.description, "A duplicate plugin");
-    } else if (aAddon.name == "Duplicate Plugin 2") {
-      found_plugin(1, aAddon.id);
-      Assert.equal(aAddon.description, "Another duplicate plugin");
-    } else if (aAddon.name == "Another Non-duplicate Plugin") {
-      found_plugin(5, aAddon.id);
-      Assert.equal(aAddon.description, "Not a duplicate plugin");
-    } else if (aAddon.name == "Non-duplicate Plugin") {
-      if (aAddon.description == "Not a duplicate plugin") {
-        found_plugin(3, aAddon.id);
-      } else if (
-        aAddon.description ==
-        "Not a duplicate because the descriptions are different"
-      ) {
-        found_plugin(4, aAddon.id);
-      } else {
-        do_throw(
-          "Found unexpected plugin with description " + aAddon.description
-        );
-      }
-    } else {
-      do_throw("Found unexpected plugin " + aAddon.name);
-    }
-  });
-
-  run_test_2();
-}
-
-// Test that disabling a coalesced plugin disables all its tags
-async function run_test_2() {
-  let p = await AddonManager.getAddonByID(gPluginIDs[0]);
-  Assert.ok(!p.userDisabled);
-  await p.disable();
-  Assert.ok(PLUGINS[0].disabled);
-  Assert.ok(PLUGINS[1].disabled);
-
-  executeSoon(run_test_3);
-}
-
-// Test that IDs persist across restart
-async function run_test_3() {
-  await promiseRestartManager();
-
-  let p = await AddonManager.getAddonByID(gPluginIDs[0]);
-  Assert.notEqual(p, null);
-  Assert.equal(p.name, "Duplicate Plugin 1");
-  Assert.equal(p.description, "A duplicate plugin");
-
-  // Reorder the plugins and restart again
-  [PLUGINS[0], PLUGINS[1]] = [PLUGINS[1], PLUGINS[0]];
-  await promiseRestartManager();
-
-  let p_2 = await AddonManager.getAddonByID(gPluginIDs[0]);
-  Assert.notEqual(p_2, null);
-  Assert.equal(p_2.name, "Duplicate Plugin 1");
-  Assert.equal(p_2.description, "A duplicate plugin");
-
-  executeSoon(do_test_finished);
-}
--- a/toolkit/mozapps/extensions/test/xpcshell/test_general.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/test_general.js
@@ -7,26 +7,16 @@
 
 // We have to look up how many add-ons are present since there will be plugins
 // etc. detected
 var gCount;
 
 async function run_test() {
   do_test_pending();
   createAppInfo("xpcshell@tests.mozilla.org", "XPCShell", "1", "1.9.2");
-  // Otherwise the plugins get initialized async and throw off our
-  // counting.
-  Services.prefs.setBoolPref("plugin.load_flash_only", false);
-  // plugin.load_flash_only is only respected if xpc::IsInAutomation is true.
-  // This is not the case by default in xpcshell tests, unless the following
-  // pref is also set. Fixing this generically is bug 1598804
-  Services.prefs.setBoolPref(
-    "security.turn_off_all_security_so_that_viruses_can_take_over_this_computer",
-    true
-  );
 
   await promiseStartupManager();
   let list = await AddonManager.getAddonsByTypes(null);
   gCount = list.length;
 
   executeSoon(run_test_1);
 }
 
--- a/toolkit/mozapps/extensions/test/xpcshell/test_gmpProvider.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/test_gmpProvider.js
@@ -132,19 +132,16 @@ add_task(async function test_notInstalle
 
     Assert.equal(addon.updateDate, null);
 
     Assert.ok(addon.isCompatible);
     Assert.ok(addon.isPlatformCompatible);
     Assert.ok(addon.providesUpdatesSecurely);
     Assert.ok(!addon.foreignInstall);
 
-    let mimetypes = addon.pluginMimeTypes;
-    Assert.ok(mimetypes);
-    Assert.equal(mimetypes.length, 0);
     let libraries = addon.pluginLibraries;
     Assert.ok(libraries);
     Assert.equal(libraries.length, 0);
     Assert.equal(addon.pluginFullpath, "");
   }
 });
 
 add_task(async function test_installed() {
@@ -187,19 +184,16 @@ add_task(async function test_installed()
 
     Assert.equal(
       addon.permissions,
       AddonManager.PERM_CAN_UPGRADE | AddonManager.PERM_CAN_ENABLE
     );
 
     Assert.equal(addon.updateDate.getTime(), TEST_TIME_SEC * 1000);
 
-    let mimetypes = addon.pluginMimeTypes;
-    Assert.ok(mimetypes);
-    Assert.equal(mimetypes.length, 0);
     let libraries = addon.pluginLibraries;
     Assert.ok(libraries);
     Assert.equal(libraries.length, 1);
     Assert.equal(libraries[0], TEST_VERSION);
     let fullpath = addon.pluginFullpath;
     Assert.equal(fullpath.length, 1);
     Assert.equal(fullpath[0], file.path);
   }
deleted file mode 100644
--- a/toolkit/mozapps/extensions/test/xpcshell/test_pluginchange.js
+++ /dev/null
@@ -1,242 +0,0 @@
-/* Any copyright is dedicated to the Public Domain.
- * http://creativecommons.org/publicdomain/zero/1.0/
- */
-
-const LIST_UPDATED_TOPIC = "plugins-list-updated";
-
-class PluginTag extends MockPluginTag {
-  constructor(name, description) {
-    super({ name, description, version: "1.0" });
-    this.description = description;
-  }
-}
-
-const PLUGINS = [
-  // A standalone plugin
-  new PluginTag("Java", "A mock Java plugin"),
-
-  // A plugin made up of two plugin files
-  new PluginTag("Flash", "A mock Flash plugin"),
-  new PluginTag("Flash", "A mock Flash plugin"),
-];
-
-mockPluginHost(PLUGINS);
-
-// This verifies that when the list of plugins changes the add-ons manager
-// correctly updates
-async function run_test() {
-  do_test_pending();
-  createAppInfo("xpcshell@tests.mozilla.org", "XPCShell", "1", "1.9.2");
-
-  Services.prefs.setBoolPref("media.gmp-provider.enabled", false);
-
-  await promiseStartupManager();
-
-  run_test_1();
-}
-
-function end_test() {
-  executeSoon(do_test_finished);
-}
-
-function sortAddons(addons) {
-  addons.sort(function(a, b) {
-    return a.name.localeCompare(b.name);
-  });
-}
-
-// Basic check that the mock object works
-async function run_test_1() {
-  let addons = await AddonManager.getAddonsByTypes(["plugin"]);
-  sortAddons(addons);
-
-  Assert.equal(addons.length, 2);
-
-  Assert.equal(addons[0].name, "Flash");
-  Assert.ok(!addons[0].userDisabled);
-  Assert.equal(addons[1].name, "Java");
-  Assert.ok(!addons[1].userDisabled);
-
-  run_test_2();
-}
-
-// No change to the list should not trigger any events or changes in the API
-async function run_test_2() {
-  // Reorder the list a bit
-  let tag = PLUGINS[0];
-  PLUGINS[0] = PLUGINS[2];
-  PLUGINS[2] = PLUGINS[1];
-  PLUGINS[1] = tag;
-
-  Services.obs.notifyObservers(null, LIST_UPDATED_TOPIC);
-
-  let addons = await AddonManager.getAddonsByTypes(["plugin"]);
-  sortAddons(addons);
-
-  Assert.equal(addons.length, 2);
-
-  Assert.equal(addons[0].name, "Flash");
-  Assert.ok(!addons[0].userDisabled);
-  Assert.equal(addons[1].name, "Java");
-  Assert.ok(!addons[1].userDisabled);
-
-  run_test_3();
-}
-
-// Tests that a newly detected plugin shows up in the API and sends out events
-async function run_test_3() {
-  let tag = new PluginTag("Quicktime", "A mock Quicktime plugin");
-  PLUGINS.push(tag);
-  let id = tag.name + tag.description;
-
-  await expectEvents(
-    {
-      addonEvents: {
-        [id]: [{ event: "onInstalling" }, { event: "onInstalled" }],
-      },
-      installEvents: [{ event: "onExternalInstall" }],
-    },
-    async () => {
-      Services.obs.notifyObservers(null, LIST_UPDATED_TOPIC);
-    }
-  );
-
-  let addons = await AddonManager.getAddonsByTypes(["plugin"]);
-  sortAddons(addons);
-
-  Assert.equal(addons.length, 3);
-
-  Assert.equal(addons[0].name, "Flash");
-  Assert.ok(!addons[0].userDisabled);
-  Assert.equal(addons[1].name, "Java");
-  Assert.ok(!addons[1].userDisabled);
-  Assert.equal(addons[2].name, "Quicktime");
-  Assert.ok(!addons[2].userDisabled);
-
-  run_test_4();
-}
-
-// Tests that a removed plugin disappears from in the API and sends out events
-async function run_test_4() {
-  let tag = PLUGINS.splice(1, 1)[0];
-  let id = tag.name + tag.description;
-
-  await expectEvents(
-    {
-      addonEvents: {
-        [id]: [{ event: "onUninstalling" }, { event: "onUninstalled" }],
-      },
-    },
-    async () => {
-      Services.obs.notifyObservers(null, LIST_UPDATED_TOPIC);
-    }
-  );
-
-  let addons = await AddonManager.getAddonsByTypes(["plugin"]);
-  sortAddons(addons);
-
-  Assert.equal(addons.length, 2);
-
-  Assert.equal(addons[0].name, "Flash");
-  Assert.ok(!addons[0].userDisabled);
-  Assert.equal(addons[1].name, "Quicktime");
-  Assert.ok(!addons[1].userDisabled);
-
-  run_test_5();
-}
-
-// Removing part of the flash plugin should have no effect
-async function run_test_5() {
-  PLUGINS.splice(0, 1);
-
-  Services.obs.notifyObservers(null, LIST_UPDATED_TOPIC);
-
-  let addons = await AddonManager.getAddonsByTypes(["plugin"]);
-  sortAddons(addons);
-
-  Assert.equal(addons.length, 2);
-
-  Assert.equal(addons[0].name, "Flash");
-  Assert.ok(!addons[0].userDisabled);
-  Assert.equal(addons[1].name, "Quicktime");
-  Assert.ok(!addons[1].userDisabled);
-
-  run_test_6();
-}
-
-// Replacing flash should be detected
-async function run_test_6() {
-  let oldTag = PLUGINS.splice(0, 1)[0];
-  let newTag = new PluginTag("Flash 2", "A new crash-free Flash!");
-  newTag.disabled = true;
-  PLUGINS.push(newTag);
-
-  await expectEvents(
-    {
-      addonEvents: {
-        [oldTag.name + oldTag.description]: [
-          { event: "onUninstalling" },
-          { event: "onUninstalled" },
-        ],
-        [newTag.name + newTag.description]: [
-          { event: "onInstalling" },
-          { event: "onInstalled" },
-        ],
-      },
-      installEvents: [{ event: "onExternalInstall" }],
-    },
-    async () => {
-      Services.obs.notifyObservers(null, LIST_UPDATED_TOPIC);
-    }
-  );
-
-  let addons = await AddonManager.getAddonsByTypes(["plugin"]);
-  sortAddons(addons);
-
-  Assert.equal(addons.length, 2);
-
-  Assert.equal(addons[0].name, "Flash 2");
-  Assert.ok(addons[0].userDisabled);
-  Assert.equal(addons[1].name, "Quicktime");
-  Assert.ok(!addons[1].userDisabled);
-
-  run_test_7();
-}
-
-// If new tags are detected and the disabled state changes then we should send
-// out appropriate notifications
-async function run_test_7() {
-  PLUGINS[0] = new PluginTag("Quicktime", "A mock Quicktime plugin");
-  PLUGINS[0].disabled = true;
-  PLUGINS[1] = new PluginTag("Flash 2", "A new crash-free Flash!");
-
-  await expectEvents(
-    {
-      addonEvents: {
-        [PLUGINS[0].name + PLUGINS[0].description]: [
-          { event: "onDisabling" },
-          { event: "onDisabled" },
-        ],
-        [PLUGINS[1].name + PLUGINS[1].description]: [
-          { event: "onEnabling" },
-          { event: "onEnabled" },
-        ],
-      },
-    },
-    async () => {
-      Services.obs.notifyObservers(null, LIST_UPDATED_TOPIC);
-    }
-  );
-
-  let addons = await AddonManager.getAddonsByTypes(["plugin"]);
-  sortAddons(addons);
-
-  Assert.equal(addons.length, 2);
-
-  Assert.equal(addons[0].name, "Flash 2");
-  Assert.ok(!addons[0].userDisabled);
-  Assert.equal(addons[1].name, "Quicktime");
-  Assert.ok(addons[1].userDisabled);
-
-  end_test();
-}
--- a/toolkit/mozapps/extensions/test/xpcshell/test_temporary.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/test_temporary.js
@@ -1,24 +1,15 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/
  */
 
 const ID = "addon@tests.mozilla.org";
 
 createAppInfo("xpcshell@tests.mozilla.org", "XPCShell", "1", "42");
-// Force sync plugin loading to avoid spurious install events from plugins.
-Services.prefs.setBoolPref("plugin.load_flash_only", false);
-// plugin.load_flash_only is only respected if xpc::IsInAutomation is true.
-// This is not the case by default in xpcshell tests, unless the following
-// pref is also set. Fixing this generically is bug 1598804
-Services.prefs.setBoolPref(
-  "security.turn_off_all_security_so_that_viruses_can_take_over_this_computer",
-  true
-);
 
 function waitForBootstrapEvent(expectedEvent, addonId) {
   return new Promise(resolve => {
     function listener(msg, { method, params, reason }) {
       if (params.id === addonId && method === expectedEvent) {
         resolve({ params, method, reason });
         AddonTestUtils.off("bootstrap-method", listener);
       } else {
--- a/toolkit/mozapps/extensions/test/xpcshell/xpcshell.ini
+++ b/toolkit/mozapps/extensions/test/xpcshell/xpcshell.ini
@@ -29,19 +29,16 @@ support-files =
 [test_crash_annotation_quoting.js]
 [test_db_path.js]
 head =
 [test_delay_update_webextension.js]
 tags = webextensions
 [test_dependencies.js]
 [test_dictionary_webextension.js]
 [test_distribution.js]
-[test_duplicateplugins.js]
-run-if = appname == "firefox"
-reason = PluginProvider.jsm is only shipped with desktop Firefox
 [test_embedderDisabled.js]
 [test_error.js]
 # Bug 1508482
 skip-if = os == "win"
 [test_ext_management.js]
 tags = webextensions
 [test_general.js]
 [test_getInstallSourceFromHost.js]
@@ -59,19 +56,16 @@ skip-if = appname != "firefox" || (os ==
 skip-if = true
 [test_no_addons.js]
 [test_nodisable_hidden.js]
 [test_onPropertyChanged_appDisabled.js]
 head = head_addons.js head_compat.js
 skip-if = tsan # Times out, bug 1674773
 [test_permissions.js]
 [test_permissions_prefs.js]
-[test_pluginchange.js]
-run-if = appname == "firefox"
-reason = PluginProvider.jsm is only shipped with desktop Firefox
 [test_pref_properties.js]
 [test_provider_markSafe.js]
 [test_provider_shutdown.js]
 [test_provider_unsafe_access_shutdown.js]
 [test_provider_unsafe_access_startup.js]
 [test_proxies.js]
 skip-if = require_signing
 [test_recommendations.js]
--- a/widget/tests/chrome.ini
+++ b/widget/tests/chrome.ini
@@ -1,15 +1,14 @@
 [DEFAULT]
 prefs =
   plugin.load_flash_only=false
 skip-if = os == 'android'
 support-files =
   empty_window.xhtml
-  utils.js
 
 [test_alwaysontop_focus.xhtml]
 [test_bug343416.xhtml]
 skip-if = debug
 [test_bug429954.xhtml]
 support-files = window_bug429954.xhtml
 [test_bug444800.xhtml]
 [test_bug478536.xhtml]
--- a/widget/tests/mochitest.ini
+++ b/widget/tests/mochitest.ini
@@ -1,11 +1,8 @@
-[DEFAULT]
-support-files = utils.js
-
 [test_AltGr_key_events_in_web_content_on_windows.html]
 skip-if = toolkit != 'windows' || headless # headless: Bug 1410525
 [test_actionhint.html]
 [test_assign_event_data.html]
 skip-if = toolkit == "cocoa" || (toolkit == 'android' && debug) || android_version == '24' || (headless && os == "win") # Mac: Bug 933303, Android bug 1285414
 [test_autocapitalize.html]
 [test_keypress_event_with_alt_on_mac.html]
 skip-if = toolkit != "cocoa"
--- a/widget/tests/test_imestate.html
+++ b/widget/tests/test_imestate.html
@@ -1,14 +1,13 @@
 <html style="ime-mode: disabled;">
 <head>
   <title>Test for IME state controling</title>
   <script src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>
   <script src="chrome://mochikit/content/tests/SimpleTest/EventUtils.js"></script>
-  <script type="text/javascript" src="utils.js"></script>
   <link rel="stylesheet" type="text/css"
           href="chrome://mochikit/content/tests/SimpleTest/test.css" />
 </head>
 <body onload="setTimeout(runTests, 0);" style="ime-mode: disabled;">
 <div id="display" style="ime-mode: disabled;">
   <!-- input elements -->
   <input type="text"     id="text"/><br/>
   <input type="text"     id="text_readonly" readonly="readonly"/><br/>
deleted file mode 100644
--- a/widget/tests/test_plugin_scroll_consistency.html
+++ /dev/null
@@ -1,59 +0,0 @@
-<html>
-<head>
-  <title>Test for plugin child widgets not being messed up by scrolling</title>
-  <script src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>
-  <script type="text/javascript" src="utils.js"></script>
-  <link rel="stylesheet" type="text/css"
-          href="chrome://mochikit/content/tests/SimpleTest/test.css" />
-</head>
-<body onload="setTimeout(runTests, 0)">
-<script type="application/javascript">
-setTestPluginEnabledState(SpecialPowers.Ci.nsIPluginTag.STATE_ENABLED);
-</script>
-
-<p id="display">
-  <div style="overflow:hidden; height:100px;" id="scroll">
-    <embed type="application/x-test" wmode="window" width="100" height="800" id="plugin"></object>
-    <div style="height:1000px;"></div>
-  </div>
-</p>
-<div id="content" style="display: none">
-
-</div>
-<pre id="test">
-</pre>
-
-<script class="testbody" type="application/javascript">
-SimpleTest.waitForExplicitFinish();
-
-var plugin = document.getElementById("plugin");
-
-function consistencyCheck(state) {
-  var s = plugin.doInternalConsistencyCheck();
-  ok(s == "", "Consistency check: " + state + ": " + s);
-}
-
-function runTests() {
-  consistencyCheck("Initial state");
-
-  var scroll = document.getElementById("scroll");
-  scroll.scrollTop = 10;
-  consistencyCheck("Scrolled down a bit");
-
-  setTimeout(function() {
-    consistencyCheck("Before scrolling back to top");
-    scroll.scrollTop = 0;
-    consistencyCheck("Scrolled to top");
-
-    setTimeout(function() {
-      consistencyCheck("After scrolling to top");
-
-      SimpleTest.finish();
-    }, 0);
-  }, 0);
-}
-
-</script>
-</body>
-
-</html>
deleted file mode 100644
--- a/widget/tests/utils.js
+++ /dev/null
@@ -1,27 +0,0 @@
-function getTestPlugin(pluginName) {
-  var ph = SpecialPowers.Cc["@mozilla.org/plugin/host;1"].getService(
-    SpecialPowers.Ci.nsIPluginHost
-  );
-  var tags = ph.getPluginTags();
-  var name = pluginName || "Test Plug-in";
-  for (var tag of tags) {
-    if (tag.name == name) {
-      return tag;
-    }
-  }
-
-  ok(false, "Could not find plugin tag with plugin name '" + name + "'");
-  return null;
-}
-
-// call this to set the test plugin(s) initially expected enabled state.
-// it will automatically be reset to it's previous value after the test
-// ends
-function setTestPluginEnabledState(newEnabledState, pluginName) {
-  var plugin = getTestPlugin(pluginName);
-  var oldEnabledState = plugin.enabledState;
-  plugin.enabledState = newEnabledState;
-  SimpleTest.registerCleanupFunction(function() {
-    getTestPlugin(pluginName).enabledState = oldEnabledState;
-  });
-}