Commit Graph

2086 Commits

Author SHA1 Message Date
Georg Fritzsche
b7b61db01c Bug 1231055 - Fix tags usage in PluginProvider. r=dtownsend 2015-12-08 19:52:45 -05:00
Dave Townsend
300eb7f635 Bug 1227981: Test that referencing a DTD from the inline options of an add-on works. r=rhelmer 2015-11-25 10:18:53 -08:00
Robert Helmer
d4116628a4 bug 1228792 - remove leading 0, be explicit about octals r=mossop 2015-12-02 18:43:09 -08:00
Robert Helmer
0c356586c6 bug 1228792 - use function* for generators r=mossop 2015-12-02 18:42:50 -08:00
Robert Helmer
f33262df20 bug 1228792 - use standard version of catch r=mossop 2015-12-02 18:42:16 -08:00
Robert Helmer
07d070ab1d bug 1228792 - remove use of array comprehensions r=mossop 2015-12-02 18:40:59 -08:00
Carsten "Tomcat" Book
73fc6f987c Merge mozilla-central to fx-team 2015-12-01 15:28:12 +01:00
Carsten "Tomcat" Book
eb309737df merge mozilla-inbound to mozilla-central a=merge 2015-12-01 15:25:14 +01:00
Robert Helmer
d64a5b230f Bug 1195353 - leave extension proxy files that point to invalid manifests r=mossop 2015-11-25 23:28:30 -08:00
Dave Townsend
1f3c8fc441 Bug 1226386: Remove or fix many uses of Array.forEach. r=rhelmer 2015-11-20 15:31:17 -08:00
Dave Townsend
814c1d4668 Bug 1226386: Remove use of non-standard __defineGetter__ and __defineSetter__. r=rhelmer
Moved these mostly onto the prototype. We couldn't do this before without making
the target of the wrapper a property of the wrappers and we don't want to expose
that but now WeakMaps allow us to get the target without exposing it.

Once change with this approach is that when the test suite shuts down the
add-ons manager it kills the map and so wrappers cease to function. A couple of
tests were relying on accessing wrapper properties after that but that would
have likely been unsafe anyway.
2015-11-20 10:55:13 -08:00
Dave Townsend
8379791f19 Bug 1226386: Switch to fat arrow functions where it makes sense. r=rhelmer
Both for brevity and to remove the use of |self = this|.
2015-11-20 10:06:14 -08:00
Dave Townsend
ddde112dc1 Bug 1226386: Remove functions names where possible. r=rhelmer
We used to need explicit names for functions to make stack traces display
properly. The JS engine is smarter now so doesn't need them and they just
make the code messy and redundant.
2015-11-19 16:35:41 -08:00
Dave Townsend
fd3dac0195 Bug 1226386: Remove createWrapper function and replace with a memoized property. r=rhelmer 2015-11-19 14:19:33 -08:00
Dave Townsend
2d1f1a0303 Bug 1226386: Remove most of the preprocessing from the add-ons manager. r=gps
For build speed, for correct line numbers in errors, for faster development, for so many reasons.
Still a couple of cases left mostly in XUL files for different strings on Windows.

Bonus: The new lexical scope means ADDON_SIGNING and REQUIRE_SIGNING can just
be declared as regular constants and outside code can't get to them easily.
2015-11-19 15:30:47 -08:00
Dave Townsend
c4921d7819 Bug 1228359: Allow experiments to register chrome. r=felipe
Simple obvious fix. Adds tests by making BootstrapMonitor (which
test_experiments.js and others use for verifying bootstrap startup and shutdown)
verify the list of registered chrome manifests at various points. Without the
fix this makes test_experiment fail as expected.
2015-11-27 12:44:22 -08:00
Kris Maglione
2a06977fb4 Bug 1192435: Support updates for WebExtensions. r=Mossop 2015-11-17 16:23:15 -08:00
Johann Hofmann
35c769367c Bug 1200674 - Allow flexible icon sizes in ExtensionUtils. r=dtownsend 2015-11-24 18:20:26 +01:00
Christoph Kerschbaumer
053758c154 Bug 1225641 - Change default security flags within NetUtil.newChannel (r=sicking) 2015-11-17 17:35:30 -08:00
Robert Helmer
a2347b9b5b Bug 1209341 - allow loading unsigned restartless add-ons at runtime. r=mossop 2015-11-03 10:07:08 -08:00
Jim Chen
c752f09637 Bug 1221270 - Let AddonUpdateService use AddonManagerPrivate to check for updates; r=mfinkle
The Android-specific AddonUpdateService has a bit of redundant code
because AddonManagerPrivate has a backgroundUpdateCheck method that does
a lot of the same thing. This patch makes AddonUpdateService call that
method so there's less code and more consistency.

This requires flipping the "extensions.update.enabled" pref, which was
disabled in bug 528588 for showing the XUL addon update dialog. I don't
think this is relevant anymore in native Fennec and with the later
rewrite of AddonManager, so I'm fairly certain it's okay to flip that
pref.

The patch also disables the AddonManager update timer because we have
our own update timer on Android.
2015-11-23 23:31:49 -05:00
Christoph Kerschbaumer
835a7fd409 Bug 1182546 - Test update: make inlinesettings accessible from content (r=bz) 2015-11-20 10:56:55 -08:00
Gijs Kruitbosch
f65f3b2042 Bug 1191468 - always load app dir add-ons irrespective of enabledScopes, r=Mossop,froydnj 2015-11-17 13:55:31 +00:00
Carsten "Tomcat" Book
e4e47d652e merge mozilla-inbound to mozilla-central a=merge 2015-11-19 14:44:11 +01:00
Nigel Babu
d4001c301d Backed out changeset 9155ee3d42d8 (bug 1182546) for Android M(c) bustage 2015-11-19 14:26:20 +05:30
Dave Townsend
48683bccc4 Bug 1220911: Remove most of the special casing around experiments. r=rhelmer
Experiments should differ from normal add-ons in a few ways:

* They can always be enabled regardless of compatibility info
* They default to disabled when installed
* They cannot be checked for updates
* They only stay enabled for the lifetime of the current process
* The UI doesn't give users the ability to enable/disable

This makes a few changes to keep these differences but remove much of the special casing code for experiments.

Being able to use regardless of compatibility was mostly fixed by bug 1220198 but I've also removed the redundant override in isCompatible.

Previously the "enabled until restart" feature worked with by not updating the DBAddonInternal object and instead using a hack to make the wrapper still seem enabled. This seems likely to break other code that relies on the state of the DBAddonInternal object so instead we update that as normal and simply don't persist the enabled state to disk.

Also switch the DBAddonInteral.prototype code to use some newer JS features.

I've removed the hack from addon.permissions which was hiding the enable/disable buttons in the UI and instead just hidden them in the UI stylesheet. This makes the API make sense and means callers can use addon.permissions to verify that enabling will work.
2015-11-09 15:02:29 -08:00
Dave Townsend
4e30558ee7 Bug 1220911: Switch test_experiment.js to task style. r=rhelmer
Before changing the handling of experiments make the tests a bit more readable
and use BootstrapMonitor to verify things.
2015-11-09 15:02:05 -08:00
Dave Townsend
e75c629633 Bug 1225629: Always verify signatures for hotfixes and system add-on updates. r=rhelmer 2015-11-17 14:05:04 -08:00
Christoph Kerschbaumer
03280e6f92 Bug 1223435 - Use channel.asyncOpen2 in toolkit/mozapps/extensions/internal/XPIProvider.jsm (r=sicking) 2015-11-15 14:48:11 -08:00
Christoph Kerschbaumer
902dd90304 Bug 1182546 - Test update: make inlinesettings accessible from content (r=bz) 2015-11-18 19:25:03 -08:00
Mark Goodwin
18e5fc3212 Bug 1224467 - Add a preference for controlling whether oneCRL blocklists are updated via AMO. Also add a test. r=keeler,mossop 2015-11-18 11:53:54 +00:00
Nigel Babu
a2dfb0c947 Backed out changeset 46eadccf444d (bug 1223435) 2015-11-16 16:03:18 +05:30
Christoph Kerschbaumer
3dd09cf3d7 Bug 1223435 - Use channel.asyncOpen2 in toolkit/mozapps/extensions/internal/XPIProvider.jsm (r=sicking) 2015-11-15 14:48:11 -08:00
Bill McCloskey
9300fab4c2 Bug 967873 - Fix some recently enabled tests 2015-11-11 16:24:34 -08:00
Kris Maglione
5b0975034f Bug 1192433: Part 3 - Support localized names and descriptions in WebExtension manifests. r=Mossop 2015-11-02 16:50:42 -08:00
Carsten "Tomcat" Book
832402c105 Merge mozilla-central to fx-team 2015-11-05 12:17:28 +01:00
Andrew McCreight
95774ee030 Bug 1221185 - Enable more e10s tests in toolkit/mozapps/extensions/test/browser/. r=felipe 2015-11-03 09:12:00 +01:00
Carsten "Tomcat" Book
fcf25e1eba merge mozilla-inbound to mozilla-central a=merge 2015-11-04 11:59:46 +01:00
Kris Maglione
454a6399b9 Bug 1213632: Prevent WebExtensions from using versioned JavaScript. r=billm 2015-10-22 23:25:43 -07:00
Dave Townsend
19bbb28740 Bug 1220198: Never appDisable experiments if they don't have the right app compatibility information available. r=rhelmer 2015-11-02 11:15:12 -08:00
Kris Maglione
925c64fc5a Bug 1214058: Part 2 - Run add-on update tests against comparable JSON and RDF manifests. r=Mossop
I tried to keep the changes to existing tests as minimal as
possible. There were a few exceptions, though:

* test_update_ignorecompat.js was completely broken. I couldn't
  figure out why it was suddenly failing after I changed it to use
  `add_test`, and it turned out that it had been failing all along,
  but in a way that the harness didn't pick up.

* I changed most of the `do_throw` in update callbacks to `ok(false`
  because it took me about an hour to figure out where the test was
  failing when I hit one of them.

* I made some changes to sync `test_update.js` and `test_update_ignorecompat.js`
  where one appeared to have been changed without updating the
  other.

* I made `promiseFindAddonUpdates` a bit more generic, because I was
  planning to convert most of `test_update.js` to use it, rather
  than nested callbacks. I changed my mind a quarter of the way
  through, but decided to keep the changes, since they'll probably
  be useful elsewhere.
2015-10-19 09:18:42 -07:00
Kris Maglione
0ca0a616cf Bug 1214058: Part 1 - Add a simplified JSON-based add-on update protocol. r=Mossop 2015-11-03 14:49:46 -08:00
Wes Kocher
f9a7b6977b Backed out 2 changesets (bug 1214058) for xpcshell bustage
Backed out changeset 90e625ac70b2 (bug 1214058)
Backed out changeset a4d5d63a03ef (bug 1214058)
2015-11-03 16:06:23 -08:00
Kris Maglione
dc35780762 Bug 1214058: Part 2 - Run add-on update tests against comparable JSON and RDF manifests. r=Mossop
I tried to keep the changes to existing tests as minimal as
possible. There were a few exceptions, though:

* test_update_ignorecompat.js was completely broken. I couldn't
  figure out why it was suddenly failing after I changed it to use
  `add_test`, and it turned out that it had been failing all along,
  but in a way that the harness didn't pick up.

* I changed most of the `do_throw` in update callbacks to `ok(false`
  because it took me about an hour to figure out where the test was
  failing when I hit one of them.

* I made some changes to sync `test_update.js` and `test_update_ignorecompat.js`
  where one appeared to have been changed without updating the
  other.

* I made `promiseFindAddonUpdates` a bit more generic, because I was
  planning to convert most of `test_update.js` to use it, rather
  than nested callbacks. I changed my mind a quarter of the way
  through, but decided to keep the changes, since they'll probably
  be useful elsewhere.
2015-10-19 09:18:42 -07:00
Kris Maglione
e84fed1b96 Bug 1214058: Part 1 - Add a simplified JSON-based add-on update protocol. r=Mossop 2015-11-03 14:49:46 -08:00
Wes Kocher
e7c1ca70c2 Merge fx-team to central, a=merge 2015-10-29 17:07:41 -07:00
Fabrice Desré
8bfe7da329 Bug 1208242 - Part 1: hook up the blocklist service to b2g web extensions r=mossop,ferjm
* * *
Bug 1208242 - Part 3: don't ship things that should not ship r=me
2015-10-29 07:32:50 -07:00
Wes Kocher
1b29c63fda Backed out 3 changesets (bug 1208242) for emulator mochitest bustage
Backed out changeset d2f87bf3aced (bug 1208242)
Backed out changeset c38225ee4378 (bug 1208242)
Backed out changeset 6dff307959f2 (bug 1208242)
2015-10-29 12:17:25 -07:00
Tim Nguyen
effb7045a4 Bug 1169679 - browser_inlinesettings.js: Scroll button into view before clicking on it. r= Mossop 2015-10-29 12:00:36 +01:00
Fabrice Desré
082cb3dc7f Bug 1208242 - Part 1: hook up the blocklist service to b2g web extensions r=mossop,ferjm 2015-10-29 07:32:50 -07:00