Fixed a few more bugs and tests. Upgraded to new AddonManager API