Extension Blocklisting:Testing: Difference between revisions

From MozillaWiki
Jump to navigation Jump to search
No edit summary
(Changed app.update.timer to app.update.interval (prior was obsolete info). Did not change value, since 60 secs still seemed reasonable.)
 
(11 intermediate revisions by 4 users not shown)
Line 1: Line 1:
Page to plan blocklist addition tests.  General goal: make sure we do not negatively affect users with new blocklist additions.
Page to plan blocklist addition tests.  General goal: make sure we do not negatively affect users with new blocklist additions.


= How to Test =
= The Blocklist File =
* Install extension, etc.
Paths can vary based on operating system.
* OSX: /Users/user/Library/Application Support/Firefox/Profiles/profile/blocklist.xml
* Linux: /home/user/.mozilla/firefox/profile/blocklist.xml
* Windows: %APPDATA%\Mozilla\Firefox\Profiles\profile\blocklist.xml


* Edit firefox.js:
= How to Test With a Remote Blocklist File=
* Install add-on, etc.
 
* Edit about:config:
   
   
  pref("extensions.blocklist.url", "http://morgamic.khan-vm.mozilla.org/amo/site/blocklist/1/%APP_ID%/%APP_VERSION%/");
  app.update.interval = 60
extensions.blocklist.interval = 60
app.update.lastUpdateTime.blocklist-background-update-timer (reset it)
extensions.blocklist.url = <url where blocklist is located>, e.g. http://morgamic.khan-vm.mozilla.org/amo/site/blocklist/1/%APP_ID%/%APP_VERSION%/
 
* Restart.
 
* In about 60s you should see the add-on in question disabled in the EM.


  app.update.timer = 60
== How to Test With a Local Blocklist File==
* Install add-on, etc.
 
* Edit about:config:
  app.update.interval = 60
  extensions.blocklist.interval = 60
  extensions.blocklist.interval = 60
app.update.lastUpdateTime.blocklist-background-update-timer (reset it)
extensions.blocklist.url = "" (so your locally modified blocklist.xml doesn't get overwritten when Firefox tries to update it)
* Edit the blocklist.xml file located in your profile directory, not the app. install directory (the file is downloaded into the profile directory and read from there; the file in the app. install directory is only used as a fallback if no blocklist.xml file exists in the profile directory)
* Restart.
== Testing by pointing to a testfile ==
* This blocklist performs the following blocks:
  Blocks Java and Acrobat on all platforms.
  Blocks QuickTime on OSX
  Blocks Flash 7 and Flash 9 on Windows.


* Edit about:config:
* Edit about:config:
  app.update.lastUpdateTime.blocklist-background-update-timer (reset it)
  app.update.interval = 60
extensions.blocklist.interval = 60
extensions.blocklist.url = https://bugzilla.mozilla.org/attachment.cgi?id=301878
 
* Restart.
 
== Blocklisting by severities ==
You can blocklist the severity of the plugin or extension.  To do so, edit your blocklist.xml file and add: <versionRange severity="x"/>


* Restart. 
  Example:
  <pluginItem>
    <match name ="name" exp="Silverlight"/>
    <versionRange severity="3"/>
  </pluginItem>


* In about 60s you should see the add-on in question disabled in the EM.
* Severity ratings:
** 0 = out of date
** 1 = soft blocked
** 2 = hard blocked
** 3 = default?


= Basic checks =
= Basic checks =
Line 25: Line 69:


= IDM Testing =
= IDM Testing =
Blocklist URL (need VPN):
* Download/install
http://morgamic.khan-vm.mozilla.org/amo/site/blocklist/1/%7Bec8030f7-c20a-464f-9b0e-13a3a9e97384%7D/3.0a1/
https://bugzilla.mozilla.org/show_bug.cgi?id=382356#c40 previous versions of IDM]
 
* See 'how to test' above. Follow the rest of the steps.
extensions.update.url
* Restart.
 
Resulting XML:
<?xml version="1.0"?>
<blocklist xmlns="http://www.mozilla.org/2006/addons-blocklist">
  <emItems>
    <emItem id="mozilla_cc@internetdownloadmanager.com">
      <versionRange minVersion="2.1" maxVersion="3.3">
        <targetApplication id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}">
            <versionRange minVersion="3.0a1" maxVersion="*"/>
        </targetApplication>
      </versionRange>
    </emItem>
  </emItems>
</blocklist>


Assertions:
Repeat these steps for the following cases/assertions:
# IDM extension disabled for all Firefox clients 3.0a1 and greater, having IDM extension versions between 2.1 and 3.3
# IDM extension disabled for all Firefox clients 3.0a1 and greater, having IDM extension versions between 2.1 and 3.3
# IDM extension is not affected for
# IDM extension is not affected for
## Extension versions outside this range, any app version
## Extension versions outside this range, any app version
## Applications less than 3.0a1, any extension version
## Applications less than 3.0a1, any extension version

Latest revision as of 00:47, 29 September 2011

Page to plan blocklist addition tests. General goal: make sure we do not negatively affect users with new blocklist additions.

The Blocklist File

Paths can vary based on operating system.

  • OSX: /Users/user/Library/Application Support/Firefox/Profiles/profile/blocklist.xml
  • Linux: /home/user/.mozilla/firefox/profile/blocklist.xml
  • Windows: %APPDATA%\Mozilla\Firefox\Profiles\profile\blocklist.xml

How to Test With a Remote Blocklist File

  • Install add-on, etc.
  • Edit about:config:
app.update.interval = 60
extensions.blocklist.interval = 60
app.update.lastUpdateTime.blocklist-background-update-timer (reset it)
extensions.blocklist.url = <url where blocklist is located>, e.g. http://morgamic.khan-vm.mozilla.org/amo/site/blocklist/1/%APP_ID%/%APP_VERSION%/
  • Restart.
  • In about 60s you should see the add-on in question disabled in the EM.

How to Test With a Local Blocklist File

  • Install add-on, etc.
  • Edit about:config:
app.update.interval = 60
extensions.blocklist.interval = 60
app.update.lastUpdateTime.blocklist-background-update-timer (reset it)
extensions.blocklist.url = "" (so your locally modified blocklist.xml doesn't get overwritten when Firefox tries to update it)
  • Edit the blocklist.xml file located in your profile directory, not the app. install directory (the file is downloaded into the profile directory and read from there; the file in the app. install directory is only used as a fallback if no blocklist.xml file exists in the profile directory)
  • Restart.

Testing by pointing to a testfile

  • This blocklist performs the following blocks:
 Blocks Java and Acrobat on all platforms.
 Blocks QuickTime on OSX
 Blocks Flash 7 and Flash 9 on Windows.
  • Edit about:config:
app.update.interval = 60
extensions.blocklist.interval = 60
extensions.blocklist.url = https://bugzilla.mozilla.org/attachment.cgi?id=301878
  • Restart.

Blocklisting by severities

You can blocklist the severity of the plugin or extension. To do so, edit your blocklist.xml file and add: <versionRange severity="x"/>

 Example:
 <pluginItem>
   <match name ="name" exp="Silverlight"/>
   <versionRange severity="3"/>
 </pluginItem>
  • Severity ratings:
    • 0 = out of date
    • 1 = soft blocked
    • 2 = hard blocked
    • 3 = default?

Basic checks

  1. Extensions are not disabled for application versions that aren't specified
  2. Extensions are not disabled for versions that aren't specified
  3. Extensions are disabled for versions that are specified
  4. Extensions are disabled for application versions that are specified

IDM Testing

  • Download/install

https://bugzilla.mozilla.org/show_bug.cgi?id=382356#c40 previous versions of IDM]

  • See 'how to test' above. Follow the rest of the steps.
  • Restart.

Repeat these steps for the following cases/assertions:

  1. IDM extension disabled for all Firefox clients 3.0a1 and greater, having IDM extension versions between 2.1 and 3.3
  2. IDM extension is not affected for
    1. Extension versions outside this range, any app version
    2. Applications less than 3.0a1, any extension version