How to test Chrome extension for auto-update feature?

萝らか妹 提交于 2020-01-29 09:58:09

问题


I am about to finish my Google Chrome extension. If I'm not mistaking all Chrome apps come with a capability of auto-updating. If so, is there a way for me to test it before I submit my app to the Chrome Web Store?

PS. Also do I need to account for any special conditions in my extension?


回答1:


To test the updating procedure, it's best to submit your extension to the Web Store in a non-public fashion.

As you publish an item, you have a choice of Public, Unlisted, and Trusted Testers publication.

  • Public means that the extension will be searchable and everyone can install
  • Unlisted means everyone can install, but they need the direct link to the extension listing; it will not be searchable in the Web Store and not indexable by search engines.
  • Trusted Testers is the same as above, but also restricts installs to a whitelist of Google Accounts.

Go with any non-Public option and you can test it as it would actually behave (including the unfortunate delay of automatic review checks).


The method described by kadaj is no longer valid for Windows, as Chrome will reject any CRX not hosted by the Web Store.

But previously, yes, you could test this with setting up your own hosting (i.e. Dropbox Public folder) of the CRX and its associated update XML, as described in the guide. This still works for non-Windows platforms, as well as Dev/Canary builds on Windows.




回答2:


All you need is to increment version number in your manifest file and the chrome app will automatically update itself. If you want to test this you can host your own extension and specify a update_url. Follow the guide at https://developer.chrome.com/extensions/autoupdate



来源:https://stackoverflow.com/questions/26272872/how-to-test-chrome-extension-for-auto-update-feature

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!