You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by st...@apache.org on 2017/12/14 06:21:11 UTC

[cordova-lib] 05/06: CB-13056 : updated browser test files

This is an automated email from the ASF dual-hosted git repository.

steven pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cordova-lib.git

commit ebd44586617ff7e166900a8771cb14a47c8273fa
Author: Audrey So <au...@apache.org>
AuthorDate: Wed Dec 13 17:13:16 2017 -0800

    CB-13056 : updated browser test files
    
     This closes #588
---
 .../fixtures/platforms/cordova-browser/README.md   |   33 +-
 .../fixtures/platforms/cordova-browser/VERSION     |    2 +-
 .../fixtures/platforms/cordova-browser/bin/create  |   84 +-
 .../cordova-browser/bin/lib/check_reqs.js          |    8 +-
 .../platforms/cordova-browser/bin/lib/create.js    |   85 +-
 .../platforms/cordova-browser/bin/lib/update.js    |   27 +-
 .../RELEASENOTES.md => bin/template/config.xml}    |   18 +-
 .../cordova-browser/bin/template/cordova/Api.js    |  531 +++++++
 .../bin/template/cordova/browser_handler.js        |  131 ++
 .../bin/template/cordova/browser_parser.js         |  120 ++
 .../{templates/project => template}/cordova/build  |    0
 .../project => template}/cordova/build.bat         |    0
 .../{templates/project => template}/cordova/clean  |    3 +-
 .../build.bat => template/cordova/clean.bat}       |    4 +-
 .../project => template}/cordova/defaults.xml      |    0
 .../lib/clean.js => template/cordova/lib/build.js} |   35 +-
 .../project => template}/cordova/lib/clean.js      |   33 +-
 .../bin/template/cordova/lib/run.js                |   65 +
 .../cordova/version => template/cordova/log}       |    7 +-
 .../{templates/project => template}/cordova/run    |   27 +-
 .../project => template}/cordova/run.bat           |    0
 .../project => template}/cordova/version           |    2 +-
 .../project => template}/cordova/version.bat       |    0
 .../project => template}/www/css/index.css         |    0
 .../cordova-browser/bin/template/www/favicon.ico   |  Bin 0 -> 1150 bytes
 .../cordova-browser/bin/template/www/img/logo.png  |  Bin 0 -> 20554 bytes
 .../bin/template/www/img/splash.png                |  Bin 0 -> 37564 bytes
 .../{templates/project => template}/www/index.html |    3 +-
 .../project => template}/www/js/index.js           |    8 +-
 .../cordova-browser/bin/template/www/manifest.json |   21 +
 .../bin/templates/project/cordova/lib/build.js     |   65 -
 .../bin/templates/project/www/img/logo.png         |  Bin 21814 -> 0 bytes
 .../bin/templates/project/www/manifest.webapp      |   10 -
 .../project/www/res/icon/android/icon-36-ldpi.png  |  Bin 3096 -> 0 bytes
 .../project/www/res/icon/android/icon-48-mdpi.png  |  Bin 4090 -> 0 bytes
 .../project/www/res/icon/android/icon-72-hdpi.png  |  Bin 6080 -> 0 bytes
 .../project/www/res/icon/android/icon-96-xhdpi.png |  Bin 7685 -> 0 bytes
 .../www/res/icon/bada-wac/icon-48-type5.png        |  Bin 4111 -> 0 bytes
 .../www/res/icon/bada-wac/icon-50-type3.png        |  Bin 5758 -> 0 bytes
 .../www/res/icon/bada-wac/icon-80-type4.png        |  Bin 7287 -> 0 bytes
 .../project/www/res/icon/bada/icon-128.png         |  Bin 11401 -> 0 bytes
 .../project/www/res/icon/blackberry/icon-80.png    |  Bin 7287 -> 0 bytes
 .../project/www/res/icon/blackberry10/icon-80.png  |  Bin 7287 -> 0 bytes
 .../project/www/res/icon/ios/icon-57-2x.png        |  Bin 7869 -> 0 bytes
 .../templates/project/www/res/icon/ios/icon-57.png |  Bin 3908 -> 0 bytes
 .../project/www/res/icon/ios/icon-72-2x.png        |  Bin 11706 -> 0 bytes
 .../templates/project/www/res/icon/ios/icon-72.png |  Bin 4944 -> 0 bytes
 .../project/www/res/icon/tizen/icon-128.png        |  Bin 11401 -> 0 bytes
 .../project/www/res/icon/webos/icon-64.png         |  Bin 5463 -> 0 bytes
 .../www/res/icon/windows-phone/icon-173-tile.png   |  Bin 22878 -> 0 bytes
 .../project/www/res/icon/windows-phone/icon-48.png |  Bin 4111 -> 0 bytes
 .../www/res/icon/windows-phone/icon-62-tile.png    |  Bin 7324 -> 0 bytes
 .../cordova-browser/cordova-js-src/confighelper.js |   11 +-
 .../cordova-browser/cordova-js-src/platform.js     |   10 +-
 .../cordova-browser/cordova-lib/cordova.js         |  736 ++++-----
 .../cordova-browser/node_modules/abbrev/LICENSE    |   31 +
 .../cordova-browser/node_modules/abbrev/abbrev.js  |    1 -
 .../node_modules/abbrev/package.json               |   73 +-
 .../node_modules/accepts/HISTORY.md                |    6 +
 .../cordova-browser/node_modules/accepts/README.md |   20 +-
 .../cordova-browser/node_modules/accepts/index.js  |   29 +-
 .../node_modules/accepts/package.json              |   83 +-
 .../cordova-browser/node_modules/adm-zip/README.md |   64 -
 .../node_modules/adm-zip/adm-zip.js                |  475 ------
 .../node_modules/adm-zip/headers/entryHeader.js    |  261 ----
 .../node_modules/adm-zip/headers/index.js          |    2 -
 .../node_modules/adm-zip/headers/mainHeader.js     |   80 -
 .../node_modules/adm-zip/methods/deflater.js       | 1578 --------------------
 .../node_modules/adm-zip/methods/index.js          |    2 -
 .../node_modules/adm-zip/methods/inflater.js       |  448 ------
 .../node_modules/adm-zip/package.json              |  102 --
 .../node_modules/adm-zip/util/constants.js         |  115 --
 .../node_modules/adm-zip/util/errors.js            |   35 -
 .../node_modules/adm-zip/util/fattr.js             |   84 --
 .../node_modules/adm-zip/util/index.js             |    4 -
 .../node_modules/adm-zip/util/utils.js             |  199 ---
 .../node_modules/adm-zip/zipEntry.js               |  284 ----
 .../node_modules/adm-zip/zipFile.js                |  311 ----
 .../node_modules/ansi-regex/package.json           |   67 +-
 .../node_modules/ansi-styles/package.json          |   62 +-
 .../node_modules/array-flatten/package.json        |   52 +-
 .../cordova-browser/node_modules/bytes/History.md  |   17 +
 .../cordova-browser/node_modules/bytes/Readme.md   |   72 +-
 .../cordova-browser/node_modules/bytes/index.js    |   35 +-
 .../node_modules/bytes/package.json                |   93 +-
 .../node_modules/chalk/package.json                |   66 +-
 .../node_modules/compressible/HISTORY.md           |   15 +
 .../node_modules/compressible/README.md            |    6 +-
 .../node_modules/compressible/index.js             |    8 +-
 .../node_modules/compressible/package.json         |  119 +-
 .../node_modules/compression/HISTORY.md            |   30 +
 .../node_modules/compression/README.md             |   16 +-
 .../node_modules/compression/index.js              |    5 +-
 .../node_modules/compression/package.json          |   93 +-
 .../node_modules/content-disposition/package.json  |   56 +-
 .../node_modules/content-type/HISTORY.md           |   10 +
 .../node_modules/content-type/index.js             |  116 +-
 .../node_modules/content-type/package.json         |   82 +-
 .../node_modules/cookie-signature/package.json     |   57 +-
 .../node_modules/cookie/package.json               |   57 +-
 .../node_modules/cordova-serve/.jshintrc           |    0
 .../node_modules/cordova-serve/README.md           |   63 +-
 .../node_modules/cordova-serve/RELEASENOTES.md     |   22 +-
 .../node_modules/cordova-serve/package.json        |  114 +-
 .../node_modules/cordova-serve/serve.js            |   57 -
 .../node_modules/cordova-serve/src/browser.js      |  184 ++-
 .../node_modules/cordova-serve/src/exec.js         |   43 +-
 .../node_modules/cordova-serve/src/platform.js     |   36 +-
 .../node_modules/cordova-serve/src/server.js       |   97 +-
 .../node_modules/cordova-serve/src/util.js         |   16 +-
 .../cordova-browser/node_modules/debug/.jshintrc   |    3 -
 .../cordova-browser/node_modules/debug/.npmignore  |    3 +
 .../cordova-browser/node_modules/debug/History.md  |  195 ---
 .../cordova-browser/node_modules/debug/Makefile    |   42 +-
 .../cordova-browser/node_modules/debug/Readme.md   |  166 +-
 .../cordova-browser/node_modules/debug/bower.json  |   28 -
 .../cordova-browser/node_modules/debug/browser.js  |  168 ---
 .../node_modules/debug/component.json              |    8 +-
 .../cordova-browser/node_modules/debug/debug.js    |  197 ---
 .../cordova-browser/node_modules/debug/node.js     |  210 +--
 .../node_modules/debug/package.json                |  101 +-
 .../cordova-browser/node_modules/depd/History.md   |    6 +
 .../cordova-browser/node_modules/depd/LICENSE      |    2 +-
 .../cordova-browser/node_modules/depd/Readme.md    |    6 +-
 .../cordova-browser/node_modules/depd/index.js     |   89 +-
 .../node_modules/depd/lib/browser/index.js         |   10 +-
 .../node_modules/depd/lib/compat/buffer-concat.js  |   35 -
 .../depd/lib/compat/callsite-tostring.js           |    6 +-
 .../depd/lib/compat/event-listener-count.js        |    2 +-
 .../node_modules/depd/lib/compat/index.js          |   17 +-
 .../cordova-browser/node_modules/depd/package.json |   81 +-
 .../node_modules/destroy/package.json              |   59 +-
 .../node_modules/ee-first/package.json             |   57 +-
 .../node_modules/encodeurl/package.json            |   59 +-
 .../node_modules/escape-html/package.json          |   59 +-
 .../node_modules/escape-string-regexp/package.json |   64 +-
 .../cordova-browser/node_modules/etag/HISTORY.md   |   12 +
 .../cordova-browser/node_modules/etag/LICENSE      |    2 +-
 .../cordova-browser/node_modules/etag/README.md    |  102 +-
 .../cordova-browser/node_modules/etag/index.js     |   27 +-
 .../cordova-browser/node_modules/etag/package.json |   88 +-
 .../node_modules/express/History.md                |  212 +++
 .../cordova-browser/node_modules/express/Readme.md |   19 +-
 .../node_modules/express/lib/application.js        |   21 +-
 .../node_modules/express/lib/express.js            |   19 +-
 .../node_modules/express/lib/middleware/init.js    |   11 +-
 .../node_modules/express/lib/middleware/query.js   |    3 +-
 .../node_modules/express/lib/request.js            |   39 +-
 .../node_modules/express/lib/response.js           |  134 +-
 .../node_modules/express/lib/router/index.js       |   57 +-
 .../node_modules/express/lib/router/layer.js       |   47 +-
 .../node_modules/express/lib/router/route.js       |   14 +-
 .../node_modules/express/lib/utils.js              |   37 +-
 .../node_modules/express/lib/view.js               |   13 +-
 .../node_modules/express/package.json              |  139 +-
 .../node_modules/finalhandler/HISTORY.md           |   56 +
 .../node_modules/finalhandler/LICENSE              |    2 +-
 .../node_modules/finalhandler/README.md            |    4 +-
 .../node_modules/finalhandler/index.js             |   95 +-
 .../node_modules/finalhandler/package.json         |   91 +-
 .../node_modules/forwarded/HISTORY.md              |   12 +
 .../cordova-browser/node_modules/forwarded/LICENSE |    2 +-
 .../node_modules/forwarded/README.md               |   18 +-
 .../node_modules/forwarded/index.js                |   57 +-
 .../node_modules/forwarded/package.json            |   83 +-
 .../cordova-browser/node_modules/fresh/HISTORY.md  |   32 +
 .../cordova-browser/node_modules/fresh/LICENSE     |    1 +
 .../cordova-browser/node_modules/fresh/README.md   |   85 +-
 .../cordova-browser/node_modules/fresh/index.js    |  148 +-
 .../node_modules/fresh/package.json                |   94 +-
 .../node_modules/has-ansi/package.json             |   59 +-
 .../node_modules/http-errors/HISTORY.md            |   21 +
 .../node_modules/http-errors/README.md             |    7 +-
 .../node_modules/http-errors/index.js              |   55 +-
 .../node_modules/http-errors/package.json          |   97 +-
 .../node_modules/inherits/package.json             |   65 +-
 .../node_modules/ipaddr.js/Cakefile                |    6 +-
 .../cordova-browser/node_modules/ipaddr.js/LICENSE |    4 +-
 .../node_modules/ipaddr.js/README.md               |   30 +-
 .../node_modules/ipaddr.js/bower.json              |    2 +-
 .../node_modules/ipaddr.js/ipaddr.min.js           |    2 +-
 .../node_modules/ipaddr.js/lib/ipaddr.js           |  324 ++--
 .../node_modules/ipaddr.js/package.json            |   73 +-
 .../node_modules/ipaddr.js/src/ipaddr.coffee       |  165 +-
 .../node_modules/ipaddr.js/test/ipaddr.test.coffee |  139 ++
 .../node_modules/media-typer/package.json          |   53 +-
 .../node_modules/merge-descriptors/package.json    |  125 +-
 .../node_modules/methods/package.json              |   67 +-
 .../node_modules/mime-db/HISTORY.md                |  136 +-
 .../cordova-browser/node_modules/mime-db/README.md |   12 +
 .../cordova-browser/node_modules/mime-db/db.json   |  383 +++--
 .../node_modules/mime-db/package.json              |   98 +-
 .../node_modules/mime-types/HISTORY.md             |   31 +
 .../node_modules/mime-types/README.md              |   19 +-
 .../node_modules/mime-types/index.js               |   12 +-
 .../node_modules/mime-types/package.json           |   91 +-
 .../cordova-browser/node_modules/mime/.npmignore   |    0
 .../cordova-browser/node_modules/mime/LICENSE      |    2 +
 .../node_modules/mime/build/test.js                |    9 +-
 .../cordova-browser/node_modules/mime/mime.js      |   10 +-
 .../cordova-browser/node_modules/mime/package.json |   81 +-
 .../cordova-browser/node_modules/mime/types.json   |    2 +-
 .../cordova-browser/node_modules/ms/.npmignore     |    5 -
 .../cordova-browser/node_modules/ms/History.md     |   66 -
 .../cordova-browser/node_modules/ms/LICENSE        |   20 -
 .../cordova-browser/node_modules/ms/README.md      |   32 +-
 .../cordova-browser/node_modules/ms/index.js       |   73 +-
 .../cordova-browser/node_modules/ms/package.json   |  114 +-
 .../node_modules/negotiator/package.json           |   64 +-
 .../cordova-browser/node_modules/nopt/package.json |   61 +-
 .../node_modules/on-finished/package.json          |   59 +-
 .../node_modules/on-headers/package.json           |   58 +-
 .../node_modules/parseurl/HISTORY.md               |    6 +
 .../cordova-browser/node_modules/parseurl/LICENSE  |    2 +-
 .../node_modules/parseurl/README.md                |   60 +-
 .../cordova-browser/node_modules/parseurl/index.js |  100 +-
 .../node_modules/parseurl/package.json             |  113 +-
 .../node_modules/path-to-regexp/package.json       |  180 +--
 .../node_modules/proxy-addr/HISTORY.md             |   31 +
 .../node_modules/proxy-addr/README.md              |   28 +-
 .../node_modules/proxy-addr/index.js               |  216 +--
 .../node_modules/proxy-addr/package.json           |   95 +-
 .../cordova-browser/node_modules/q/CHANGES.md      |   14 +
 .../cordova-browser/node_modules/q/LICENSE         |    2 +-
 .../cordova-browser/node_modules/q/README.md       |   19 +-
 .../cordova-browser/node_modules/q/package.json    |   74 +-
 .../platforms/cordova-browser/node_modules/q/q.js  |   56 +-
 .../cordova-browser/node_modules/qs/.eslintrc      |   30 +-
 .../cordova-browser/node_modules/qs/.jscs.json     |  176 ---
 .../cordova-browser/node_modules/qs/CHANGELOG.md   |  101 ++
 .../node_modules/qs/CONTRIBUTING.md                |    1 -
 .../cordova-browser/node_modules/qs/dist/qs.js     |  418 ++++--
 .../cordova-browser/node_modules/qs/lib/index.js   |   10 +-
 .../cordova-browser/node_modules/qs/lib/parse.js   |  127 +-
 .../node_modules/qs/lib/stringify.js               |  121 +-
 .../cordova-browser/node_modules/qs/lib/utils.js   |  134 +-
 .../cordova-browser/node_modules/qs/package.json   |  101 +-
 .../cordova-browser/node_modules/qs/test/index.js  |    2 +
 .../cordova-browser/node_modules/qs/test/parse.js  |  250 +++-
 .../node_modules/qs/test/stringify.js              |  349 ++++-
 .../cordova-browser/node_modules/qs/test/utils.js  |   25 +
 .../node_modules/range-parser/package.json         |   71 +-
 .../cordova-browser/node_modules/send/HISTORY.md   |   96 ++
 .../cordova-browser/node_modules/send/README.md    |   84 +-
 .../cordova-browser/node_modules/send/index.js     |  278 +++-
 .../node_modules/send/node_modules/ms/LICENSE.md   |   21 -
 .../node_modules/send/node_modules/ms/README.md    |   52 -
 .../node_modules/send/node_modules/ms/index.js     |  149 --
 .../node_modules/send/node_modules/ms/package.json |  108 --
 .../cordova-browser/node_modules/send/package.json |  106 +-
 .../node_modules/serve-static/HISTORY.md           |   82 +
 .../node_modules/serve-static/README.md            |   22 +-
 .../node_modules/serve-static/index.js             |   33 +-
 .../node_modules/serve-static/package.json         |   88 +-
 .../node_modules/setprototypeof/README.md          |    5 +
 .../node_modules/setprototypeof/index.js           |    4 +-
 .../node_modules/setprototypeof/package.json       |   76 +-
 .../node_modules/shelljs/.npmignore                |    9 +-
 .../cordova-browser/node_modules/shelljs/LICENSE   |    2 +-
 .../node_modules/shelljs/MAINTAINERS               |    3 -
 .../cordova-browser/node_modules/shelljs/README.md |  211 +--
 .../cordova-browser/node_modules/shelljs/bin/shjs  |    8 +-
 .../cordova-browser/node_modules/shelljs/make.js   |    9 +-
 .../node_modules/shelljs/package.json              |  104 +-
 .../node_modules/shelljs/scripts/generate-docs.js  |    9 +-
 .../node_modules/shelljs/scripts/run-tests.js      |   13 +-
 .../cordova-browser/node_modules/shelljs/shell.js  |   29 +-
 .../node_modules/shelljs/src/cat.js                |    5 +-
 .../cordova-browser/node_modules/shelljs/src/cd.js |   15 +-
 .../node_modules/shelljs/src/chmod.js              |   23 +-
 .../node_modules/shelljs/src/common.js             |  108 +-
 .../cordova-browser/node_modules/shelljs/src/cp.js |   24 +-
 .../node_modules/shelljs/src/echo.js               |    4 +-
 .../node_modules/shelljs/src/error.js              |    2 +-
 .../node_modules/shelljs/src/exec.js               |  141 +-
 .../node_modules/shelljs/src/find.js               |    2 +-
 .../node_modules/shelljs/src/grep.js               |    4 +-
 .../cordova-browser/node_modules/shelljs/src/ln.js |   40 +-
 .../cordova-browser/node_modules/shelljs/src/ls.js |   64 +-
 .../node_modules/shelljs/src/mkdir.js              |    6 +-
 .../cordova-browser/node_modules/shelljs/src/mv.js |   16 +-
 .../node_modules/shelljs/src/pwd.js                |    2 +-
 .../cordova-browser/node_modules/shelljs/src/rm.js |    6 +-
 .../node_modules/shelljs/src/sed.js                |   43 +-
 .../node_modules/shelljs/src/set.js                |   49 -
 .../node_modules/shelljs/src/tempdir.js            |    3 +-
 .../node_modules/shelljs/src/test.js               |    2 +-
 .../cordova-browser/node_modules/shelljs/src/to.js |    1 -
 .../node_modules/shelljs/src/toEnd.js              |    1 -
 .../node_modules/shelljs/src/touch.js              |  109 --
 .../node_modules/shelljs/src/which.js              |   55 +-
 .../node_modules/statuses/package.json             |   80 +-
 .../node_modules/strip-ansi/package.json           |   68 +-
 .../node_modules/supports-color/package.json       |   60 +-
 .../node_modules/type-is/HISTORY.md                |    6 +
 .../cordova-browser/node_modules/type-is/README.md |   62 +-
 .../node_modules/type-is/package.json              |   90 +-
 .../node_modules/unpipe/package.json               |   64 +-
 .../node_modules/utils-merge/.travis.yml           |    6 -
 .../node_modules/utils-merge/LICENSE               |    4 +-
 .../node_modules/utils-merge/README.md             |   26 +-
 .../node_modules/utils-merge/package.json          |   71 +-
 .../cordova-browser/node_modules/vary/HISTORY.md   |   10 +
 .../cordova-browser/node_modules/vary/LICENSE      |    2 +-
 .../cordova-browser/node_modules/vary/README.md    |   14 +-
 .../cordova-browser/node_modules/vary/index.js     |   83 +-
 .../cordova-browser/node_modules/vary/package.json |   92 +-
 .../platforms/cordova-browser/package.json         |  111 +-
 308 files changed, 8276 insertions(+), 12124 deletions(-)

diff --git a/spec/cordova/fixtures/platforms/cordova-browser/README.md b/spec/cordova/fixtures/platforms/cordova-browser/README.md
index 186c2b7..42be8d0 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/README.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/README.md
@@ -19,29 +19,26 @@
 #
 -->
 
-[![Build Status](https://travis-ci.org/apache/cordova-browser.svg)](https://travis-ci.org/apache/cordova-browser)
+[![Build status](https://travis-ci.org/apache/cordova-browser.svg?branch=master )](https://travis-ci.org/apache/cordova-browser.svg?branch=master )
+[![Build Status](https://ci.appveyor.com/api/projects/status/4oan2jjn7nlgfay3/branch/master?svg=true)](https://ci.appveyor.com/api/projects/status/4oan2jjn7nlgfay3/branch/master?svg=true)
 
 # Cordova Browser
 
-Target modern web browsers to build Cordova based applications. 
+Target modern web browsers to build Apache Cordova based applications.
 
 # Goals
 
-- Browser targeted deployment 
+- Browser targeted deployment
 - Surfacing native platform incompatibilities from the open web platform
-- Simplest possible reference implementation for future platform targets
-- Optimizing cordova.js 
-
-# TODO
-
-`bin/create`
-`bin/update`
-`bin/check_reqs`
-`bin/templates/scripts/cordova/build`
-`bin/templates/scripts/cordova/clean`
-`bin/templates/scripts/cordova/log`
-`bin/templates/scripts/cordova/emulate`
-`bin/templates/scripts/cordova/run`
-`bin/templates/scripts/cordova/version`
-`bin/templates/www`
+
+# PWA support
+
+## cordova-browser now includes support for progressive web apps (PWAs)
+
+- if your project supplies a `manifest.json` in the `www/` dir, it will be used
+    - a `manifest.json` will be generated otherwise
+- if your js code registers a service worker, it will also be used
+    - a generic cordova service worker will be installed that simply caches all files in the `www` dir.
+    - cache version is autoincremented for every build
+
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/VERSION b/spec/cordova/fixtures/platforms/cordova-browser/VERSION
index 5fb11aa..f8ee15f 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/VERSION
+++ b/spec/cordova/fixtures/platforms/cordova-browser/VERSION
@@ -1 +1 @@
-4.2.0-dev
+5.1.0-dev
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/create b/spec/cordova/fixtures/platforms/cordova-browser/bin/create
index b035022..6d73745 100755
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/create
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/create
@@ -18,18 +18,76 @@
        specific language governing permissions and limitations
        under the License.
 */
+// var path = require('path');
+// var create = require('./lib/create');
+// var args = process.argv;
+
+// // Support basic help commands
+// if(args.length < 3 || (args[2] == '--help' || args[2] == '/?' || args[2] == '-h' ||
+//                     args[2] == 'help' || args[2] == '-help' || args[2] == '/help')) {
+//     console.log('Usage: ' + path.relative(process.cwd(), path.join(__dirname, 'create')) + ' <path_to_new_project> <package_name> <project_name>');
+//     console.log('    <path_to_new_project>: Path to your new Cordova Browser project');
+//     console.log('    <package_name>: Package name, following reverse-domain style convention');
+//     console.log('    <project_name>: Project name');
+//     process.exitCode = 1;
+// } else {
+//     create.createProject(args[2], args[3], args[4], args[5]);
+// }
+
+/*
+ * create a Cordova project
+ *
+ * USAGE
+ *   ./create <path_to_new_project> <package_name> <project_name>
+ *
+ * EXAMPLE
+ *  ./create ~/Desktop/radness org.apache.cordova.radness Radness
+ */
+
 var path = require('path');
-var create = require('./lib/create');
-var args = process.argv;
-
-// Support basic help commands
-if(args.length < 3 || (args[2] == '--help' || args[2] == '/?' || args[2] == '-h' ||
-                    args[2] == 'help' || args[2] == '-help' || args[2] == '/help')) {
-    console.log('Usage: ' + path.relative(process.cwd(), path.join(__dirname, 'create')) + ' <path_to_new_project> <package_name> <project_name>');
-    console.log('    <path_to_new_project>: Path to your new Cordova Browser project');
-    console.log('    <package_name>: Package name, following reverse-domain style convention');
-    console.log('    <project_name>: Project name');
-    process.exit(1);
-} else {
-    create.createProject(args[2], args[3], args[4], args[5]).done();
+var ConfigParser = require('cordova-common').ConfigParser;
+var Api = require('./template/cordova/Api');
+
+
+var argv = require('nopt')({
+    'help' : Boolean,
+    'cli' : Boolean,
+    'shared' : Boolean, // alias for --link
+    'link' : Boolean
+}, { 'd' : '--verbose' });
+
+
+var projectPath = argv.argv.remain[0];
+
+if (argv.help || !projectPath) {
+    console.log('Usage: $0 [--link] [--cli] <path_to_new_project> <package_name> <project_name> [<project_template_dir>]');
+    console.log('   --link (optional): Link directly against the shared copy of the CordovaLib instead of a copy of it.');
+    console.log('   --cli (optional): Use the CLI-project template.');
+    console.log('   <path_to_new_project>: Path to your new Cordova iOS project');
+    console.log('   <package_name>: Package name, following reverse-domain style convention');
+    console.log('   <project_name>: Project name');
+    console.log('   <project_template_dir>: Path to project template (override).');
+    process.exit(0);
 }
+else {
+    var configPath = path.resolve(__dirname, 'template/config.xml');
+    var config = new ConfigParser(configPath);
+
+    // apply overrides (package and project names
+    if (argv.argv.remain[1]) {
+        config.setPackageName(argv.argv.remain[1]);
+    }
+    if (argv.argv.remain[2]) {
+        config.setName(argv.argv.remain[2]);
+    }
+
+    var options = {
+        cli: argv.cli,
+        link: argv.link || argv.shared,
+        customTemplate: argv.argv.remain[3],
+    };
+
+    Api.createPlatform(projectPath, config, options);
+}
+
+
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/check_reqs.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/check_reqs.js
index 720d7aa..172aa38 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/check_reqs.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/check_reqs.js
@@ -19,10 +19,8 @@ specific language governing permissions and limitations
 under the License.
 */
 
-//add methods as we determine what are the requirements
+// add methods as we determine what are the requirements
 
-var Q = require('q');
-
-module.exports.run = function() {
-    return Q.resolve();
+module.exports.run = function () {
+    return Promise.resolve();
 };
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/create.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/create.js
index 2f77cc2..667d9ff 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/create.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/create.js
@@ -19,63 +19,70 @@
  * under the License.
  */
 
-var fs = require('fs'),
-    shjs = require('shelljs'),
-    Q = require ('q'),
-    args = process.argv,
-    path = require('path'),
-    ROOT    = path.join(__dirname, '..', '..'),
-    check_reqs = require('./check_reqs');
+var fs = require('fs');
+var shell = require('shelljs');
+var path = require('path');
+var ROOT = path.join(__dirname, '..', '..');
+var events = require('cordova-common').events;
+var check_reqs = require('./check_reqs');
 
-module.exports.createProject = function(project_path,package_name,project_name){
+// exported method to create a project, returns a promise that resolves with null
+module.exports.createProject = function (project_path, package_name, project_name) {
+/*
+    // create the dest and the standard place for our api to live
+    // platforms/platformName/cordova/Api.js
+*/
 
-    var VERSION = fs.readFileSync(path.join(ROOT, 'VERSION'), 'utf-8');
+    events.emit('log', 'Creating Cordova project for cordova-browser:');
+    events.emit('log', '\tPath: ' + project_path);
+    events.emit('log', '\tName: ' + project_name);
 
     // Set default values for path, package and name
-    project_path = typeof project_path !== 'undefined' ? project_path : "CordovaExample";
+    project_path = project_path || 'CordovaExample';
 
     // Check if project already exists
     if (fs.existsSync(project_path)) {
-        console.error('Project already exists! Delete and recreate');
-        process.exit(2);
+        events.emit('error', 'Oops, destination already exists! Delete it and try again');
     }
 
     // Check that requirements are met and proper targets are installed
     if (!check_reqs.run()) {
-        console.error('Please make sure you meet the software requirements in order to build a browser cordova project');
-        process.exit(2);
+        // TODO: use events.emit
+        events.emit('error', 'Please make sure you meet the software requirements in order to build a browser cordova project');
     }
 
-    //copy template directory
-    shjs.cp('-r', path.join(ROOT, 'bin', 'templates', 'project', 'www'), project_path);
+    // copy template/cordova directory ( recursive )
+    shell.cp('-r', path.join(ROOT, 'bin/template/cordova'), project_path);
 
-    //create cordova/lib if it does not exist yet
-    if (!fs.existsSync(path.join(project_path,'cordova', 'lib'))) {
-        shjs.mkdir('-p', path.join(project_path,'cordova', 'lib'));
-    }
+    // copy template/www directory ( recursive )
+    shell.cp('-r', path.join(ROOT, 'bin/template/www'), project_path);
+
+    // recreate our node_modules structure in the new project
+    shell.cp('-r', path.join(ROOT, 'node_modules'),
+        path.join(project_path, 'cordova'));
+
+    // copy check_reqs file
+    shell.cp(path.join(ROOT, 'bin/lib/check_reqs.js'),
+        path.join(project_path, 'cordova/lib'));
 
-    //copy required node_modules
-    shjs.cp('-r', path.join(ROOT, 'node_modules'), path.join(project_path,'cordova'));
+    var platform_www = path.join(project_path, 'platform_www');
 
-    //copy check_reqs file
-    shjs.cp( path.join(ROOT, 'bin', 'lib', 'check_reqs.js'), path.join(project_path,'cordova', 'lib'));
+    // copy cordova-js-src directory
+    shell.cp('-rf', path.join(ROOT, 'cordova-js-src'), platform_www);
 
-    //copy cordova js file
-    shjs.cp('-r', path.join(ROOT, 'cordova-lib', 'cordova.js'), path.join(project_path,'www'));
+    // copy cordova js file to platform_www
+    shell.cp(path.join(ROOT, 'cordova-lib', 'cordova.js'), platform_www);
 
-    //copy cordova-js-src directory
-    shjs.cp('-rf', path.join(ROOT, 'cordova-js-src'), path.join(project_path, 'platform_www'));
+    // copy favicon file to platform_www
+    shell.cp(path.join(ROOT, 'bin/template/www/favicon.ico'), platform_www);
 
-    //copy cordova directory
-    shjs.cp('-r', path.join(ROOT, 'bin', 'templates', 'project', 'cordova'), project_path);
-    [
-        'run',
-        'build',
-        'clean',
-        'version',
-    ].forEach(function(f) {
-         shjs.chmod(755, path.join(project_path, 'cordova', f));
-    });
+    // load manifest to write name/shortname
+    var manifest = require(path.join(ROOT, 'bin/template/www', 'manifest.json'));
+    manifest.name = project_name;
+    manifest.short_name = project_name;
+    // copy manifest file to platform_www
+    fs.writeFileSync(path.join(platform_www, 'manifest.json'),
+        JSON.stringify(manifest, null, 2), 'utf-8');
 
-    return Q.resolve();
+    return Promise.resolve();
 };
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/update.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/update.js
index 47b57d7..62e37e1 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/update.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/lib/update.js
@@ -17,40 +17,39 @@
        under the License.
 */
 
-var Q      = require('q'),
-    create = require('./create'),
-    fs     = require('fs'),
-    shell = require('shelljs');
+var Q = require('q');
+var create = require('./create');
+var fs = require('fs');
+var shell = require('shelljs');
 
 module.exports.help = function () {
-    console.log("WARNING : Make sure to back up your project before updating!");
-    console.log("Usage: update PathToProject ");
-    console.log("    PathToProject : The path the project you would like to update.");
-    console.log("examples:");
-    console.log("    update C:\\Users\\anonymous\\Desktop\\MyProject");
+    console.log('WARNING : Make sure to back up your project before updating!');
+    console.log('Usage: update PathToProject ');
+    console.log('    PathToProject : The path the project you would like to update.');
+    console.log('examples:');
+    console.log('    update C:\\Users\\anonymous\\Desktop\\MyProject');
 };
 
 module.exports.run = function (argv) {
     var projectPath = argv[2];
     if (!fs.existsSync(projectPath)) {
         // if specified project path is not valid then reject promise
-        Q.reject("Browser platform does not exist here: " + projectPath);
+        Q.reject('Browser platform does not exist here: ' + projectPath);
     }
     return Q().then(function () {
-        console.log("Removing existing browser platform.");
+        console.log('Removing existing browser platform.');
         shellfatal(shell.rm, '-rf', projectPath);
         create.createProject(projectPath);
     });
 };
 
-function shellfatal(shellFunc) {
+function shellfatal (shellFunc) {
     var slicedArgs = Array.prototype.slice.call(arguments, 1);
     var returnVal = null;
     try {
         shell.config.fatal = true;
         returnVal = shellFunc.apply(shell, slicedArgs);
-    }   
-    finally {
+    } finally {
         shell.config.fatal = false;
     }
     return returnVal;
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/cordova-serve/RELEASENOTES.md b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/config.xml
old mode 100755
new mode 100644
similarity index 61%
copy from spec/cordova/fixtures/platforms/cordova-browser/node_modules/cordova-serve/RELEASENOTES.md
copy to spec/cordova/fixtures/platforms/cordova-browser/bin/template/config.xml
index cf9eab4..a212661
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/cordova-serve/RELEASENOTES.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/config.xml
@@ -1,3 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
 <!--
 #
 # Licensed to the Apache Software Foundation (ASF) under one
@@ -18,19 +19,6 @@
 # under the License.
 #
 -->
-# Cordova-serve Release Notes
+<widget xmlns="http://www.w3.org/ns/widgets">
 
-### 1.0.1 (Dec 21, 2016)
-* CB-12284 Include project root as additional root for static router
-
-### 1.0.0 (Oct 05, 2015)
-* Refactor cordova-serve to use Express.
-
-### 0.1.3 (Aug 22, 2015)
-* Clean up cordova-serve console output.
-* CB-9546 cordova-serve.servePlatform() should provide project folders
-* CB-9545 Cordova-serve's 'noCache' option does not work in IE.
-* Add support for --target=edge to launch app in Edge browser.
-
-### 0.1.2 (June 15, 2015)
-Initial release
+</widget>
\ No newline at end of file
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/Api.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/Api.js
new file mode 100644
index 0000000..9752d24
--- /dev/null
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/Api.js
@@ -0,0 +1,531 @@
+/**
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+'License'); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+'AS IS' BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+*/
+
+/*
+    this file is found by cordova-lib when you attempt to
+    'cordova platform add PATH' where path is this repo.
+*/
+
+var shell = require('shelljs');
+var path = require('path');
+var fs = require('fs');
+
+var cdvcmn = require('cordova-common');
+var CordovaLogger = cdvcmn.CordovaLogger;
+var ConfigParser = cdvcmn.ConfigParser;
+var ActionStack = cdvcmn.ActionStack;
+var selfEvents = cdvcmn.events;
+var xmlHelpers = cdvcmn.xmlHelpers;
+var PlatformJson = cdvcmn.PlatformJson;
+var PlatformMunger = cdvcmn.ConfigChanges.PlatformMunger;
+var PluginInfoProvider = cdvcmn.PluginInfoProvider;
+
+var BrowserParser = require('./browser_parser');
+var PLATFORM_NAME = 'browser';
+
+function setupEvents (externalEventEmitter) {
+    if (externalEventEmitter) {
+        // This will make the platform internal events visible outside
+        selfEvents.forwardEventsTo(externalEventEmitter);
+        return externalEventEmitter;
+    }
+
+    // There is no logger if external emitter is not present,
+    // so attach a console logger
+    CordovaLogger.get().subscribe(selfEvents);
+    return selfEvents;
+}
+
+function Api (platform, platformRootDir, events) {
+
+    this.platform = platform || PLATFORM_NAME;
+
+    // MyApp/platforms/browser
+    this.root = path.resolve(__dirname, '..');
+    this.events = setupEvents(events);
+    this.parser = new BrowserParser(this.root);
+    this._handler = require('./browser_handler');
+
+    this.locations = {
+        platformRootDir: platformRootDir,
+        root: this.root,
+        www: path.join(this.root, 'www'),
+        res: path.join(this.root, 'res'),
+        platformWww: path.join(this.root, 'platform_www'),
+        configXml: path.join(this.root, 'config.xml'),
+        defaultConfigXml: path.join(this.root, 'cordova/defaults.xml'),
+        build: path.join(this.root, 'build'),
+        // NOTE: Due to platformApi spec we need to return relative paths here
+        cordovaJs: 'bin/templates/project/assets/www/cordova.js',
+        cordovaJsSrc: 'cordova-js-src'
+    };
+
+    this._platformJson = PlatformJson.load(this.root, platform);
+    this._pluginInfoProvider = new PluginInfoProvider();
+    this._munger = new PlatformMunger(platform, this.root, this._platformJson, this._pluginInfoProvider);
+}
+
+Api.createPlatform = function (dest, config, options, events) {
+
+    var creator = require('../../lib/create');
+    events = setupEvents(events);
+
+    var name = 'HelloCordova';
+    var id = 'io.cordova.hellocordova';
+    if (config) {
+        name = config.name();
+        id = config.packageName();
+    }
+
+    var result;
+    try {
+        // we create the project using our scripts in this platform
+        result = creator.createProject(dest, id, name, options)
+            .then(function () {
+                // after platform is created we return Api instance based on new Api.js location
+                // Api.js has been copied to the new project
+                // This is required to correctly resolve paths in the future api calls
+                var PlatformApi = require(path.resolve(dest, 'cordova/Api'));
+                return new PlatformApi('browser', dest, events);
+            });
+    } catch (e) {
+        events.emit('error', 'createPlatform is not callable from the browser project API.');
+        throw (e);
+    }
+    return result;
+};
+
+Api.updatePlatform = function (dest, options, events) {
+    // console.log("test-platform:Api:updatePlatform");
+    // todo?: create projectInstance and fulfill promise with it.
+    return Promise.resolve();
+};
+
+Api.prototype.getPlatformInfo = function () {
+    // console.log("browser-platform:Api:getPlatformInfo");
+    // return PlatformInfo object
+    return {
+        'locations': this.locations,
+        'root': this.root,
+        'name': this.platform,
+        'version': { 'version': '1.0.0' }, // um, todo!
+        'projectConfig': this.config
+    };
+};
+
+Api.prototype.prepare = function (cordovaProject, options) {
+
+    // First cleanup current config and merge project's one into own
+    var defaultConfigPath = path.join(this.locations.platformRootDir, 'cordova',
+        'defaults.xml');
+    var ownConfigPath = this.locations.configXml;
+    var sourceCfg = cordovaProject.projectConfig;
+
+    // If defaults.xml is present, overwrite platform config.xml with it.
+    // Otherwise save whatever is there as defaults so it can be
+    // restored or copy project config into platform if none exists.
+    if (fs.existsSync(defaultConfigPath)) {
+        this.events.emit('verbose', 'Generating config.xml from defaults for platform "' + this.platform + '"');
+        shell.cp('-f', defaultConfigPath, ownConfigPath);
+    } else if (fs.existsSync(ownConfigPath)) {
+        this.events.emit('verbose', 'Generating defaults.xml from own config.xml for platform "' + this.platform + '"');
+        shell.cp('-f', ownConfigPath, defaultConfigPath);
+    } else {
+        this.events.emit('verbose', 'case 3"' + this.platform + '"');
+        shell.cp('-f', sourceCfg.path, ownConfigPath);
+    }
+
+    // merge our configs
+    this.config = new ConfigParser(ownConfigPath);
+    xmlHelpers.mergeXml(cordovaProject.projectConfig.doc.getroot(),
+        this.config.doc.getroot(),
+        this.platform, true);
+    this.config.write();
+
+    // Update own www dir with project's www assets and plugins' assets and js-files
+    this.parser.update_www(cordovaProject, options);
+
+    // Copy or Create manifest.json
+    // todo: move this to a manifest helper module
+    // output path
+    var manifestPath = path.join(this.locations.www, 'manifest.json');
+    var srcManifestPath = path.join(cordovaProject.locations.www, 'manifest.json');
+    if (fs.existsSync(srcManifestPath)) {
+        // just blindly copy it to our output/www
+        // todo: validate it? ensure all properties we expect exist?
+        this.events.emit('verbose', 'copying ' + srcManifestPath + ' => ' + manifestPath);
+        shell.cp('-f', srcManifestPath, manifestPath);
+    } else {
+        var manifestJson = {
+            'background_color': '#FFF',
+            'display': 'standalone'
+        };
+        if (this.config) {
+            if (this.config.name()) {
+                manifestJson.name = this.config.name();
+            }
+            if (this.config.shortName()) {
+                manifestJson.short_name = this.config.shortName();
+            }
+            if (this.config.packageName()) {
+                manifestJson.version = this.config.packageName();
+            }
+            if (this.config.description()) {
+                manifestJson.description = this.config.description();
+            }
+            if (this.config.author()) {
+                manifestJson.author = this.config.author();
+            }
+            // icons
+            var icons = this.config.getStaticResources('browser', 'icon');
+            var manifestIcons = icons.map(function (icon) {
+                // given a tag like this :
+                // <icon src="res/ios/icon.png" width="57" height="57" density="mdpi" />
+                /* configParser returns icons that look like this :
+                {   src: 'res/ios/icon.png',
+                    target: undefined,
+                    density: 'mdpi',
+                    platform: null,
+                    width: 57,
+                    height: 57
+                } ******/
+                /* manifest expects them to be like this :
+                {   "src": "images/touch/icon-128x128.png",
+                    "type": "image/png",
+                    "sizes": "128x128"
+                } ******/
+                // ?Is it worth looking at file extentions?
+                return {'src': icon.src,
+                    'type': 'image/png',
+                    'sizes': (icon.width + 'x' + icon.height)};
+            });
+            manifestJson.icons = manifestIcons;
+
+            // orientation
+            // <preference name="Orientation" value="landscape" />
+            var oriPref = this.config.getGlobalPreference('Orientation');
+            if (oriPref) {
+                // if it's a supported value, use it
+                if (['landscape', 'portrait'].indexOf(oriPref) > -1) {
+                    manifestJson.orientation = oriPref;
+                } else { // anything else maps to 'any'
+                    manifestJson.orientation = 'any';
+                }
+            }
+
+            // get start_url
+            var contentNode = this.config.doc.find('content') || {'attrib': {'src': 'index.html'}}; // sensible default
+            manifestJson.start_url = contentNode.attrib.src;
+
+            // now we get some values from start_url page ...
+            var startUrlPath = path.join(cordovaProject.locations.www, manifestJson.start_url);
+            if (fs.existsSync(startUrlPath)) {
+                var contents = fs.readFileSync(startUrlPath, 'utf-8');
+                // matches <meta name="theme-color" content="#FF0044">
+                var themeColorRegex = /<meta(?=[^>]*name="theme-color")\s[^>]*content="([^>]*)"/i;
+                var result = themeColorRegex.exec(contents);
+                var themeColor;
+                if (result && result.length >= 2) {
+                    themeColor = result[1];
+                } else { // see if there is a preference in config.xml
+                    // <preference name="StatusBarBackgroundColor" value="#000000" />
+                    themeColor = this.config.getGlobalPreference('StatusBarBackgroundColor');
+                }
+                if (themeColor) {
+                    manifestJson.theme_color = themeColor;
+                }
+            }
+        }
+        fs.writeFileSync(manifestPath, JSON.stringify(manifestJson, null, 2), 'utf8');
+    }
+
+    // update project according to config.xml changes.
+    return this.parser.update_project(this.config, options);
+};
+
+Api.prototype.addPlugin = function (pluginInfo, installOptions) {
+
+    // console.log(new Error().stack);
+    if (!pluginInfo) {
+        return Promise.reject(new Error('The parameter is incorrect. The first parameter ' +
+            'should be valid PluginInfo instance'));
+    }
+
+    installOptions = installOptions || {};
+    installOptions.variables = installOptions.variables || {};
+    // CB-10108 platformVersion option is required for proper plugin installation
+    installOptions.platformVersion = installOptions.platformVersion ||
+        this.getPlatformInfo().version;
+
+    var self = this;
+    var actions = new ActionStack();
+    var projectFile = this._handler.parseProjectFile && this._handler.parseProjectFile(this.root);
+
+    // gather all files needs to be handled during install
+    pluginInfo.getFilesAndFrameworks(this.platform)
+        .concat(pluginInfo.getAssets(this.platform))
+        .concat(pluginInfo.getJsModules(this.platform))
+        .forEach(function (item) {
+            actions.push(actions.createAction(
+                self._getInstaller(item.itemType),
+                [item, pluginInfo.dir, pluginInfo.id, installOptions, projectFile],
+                self._getUninstaller(item.itemType),
+                [item, pluginInfo.dir, pluginInfo.id, installOptions, projectFile]));
+        });
+
+    // run through the action stack
+    return actions.process(this.platform, this.root)
+        .then(function () {
+            if (projectFile) {
+                projectFile.write();
+            }
+
+            // Add PACKAGE_NAME variable into vars
+            if (!installOptions.variables.PACKAGE_NAME) {
+                installOptions.variables.PACKAGE_NAME = self._handler.package_name(self.root);
+            }
+
+            self._munger
+                // Ignore passed `is_top_level` option since platform itself doesn't know
+                // anything about managing dependencies - it's responsibility of caller.
+                .add_plugin_changes(pluginInfo, installOptions.variables, /* is_top_level= */true, /* should_increment= */true)
+                .save_all();
+
+            var targetDir = installOptions.usePlatformWww ?
+                self.getPlatformInfo().locations.platformWww :
+                self.getPlatformInfo().locations.www;
+
+            self._addModulesInfo(pluginInfo, targetDir);
+        });
+};
+
+Api.prototype.removePlugin = function (plugin, uninstallOptions) {
+    // console.log("NotImplemented :: browser-platform:Api:removePlugin ",plugin, uninstallOptions);
+
+    uninstallOptions = uninstallOptions || {};
+    // CB-10108 platformVersion option is required for proper plugin installation
+    uninstallOptions.platformVersion = uninstallOptions.platformVersion ||
+        this.getPlatformInfo().version;
+
+    var self = this;
+    var actions = new ActionStack();
+    var projectFile = this._handler.parseProjectFile && this._handler.parseProjectFile(this.root);
+
+    // queue up plugin files
+    plugin.getFilesAndFrameworks(this.platform)
+        .concat(plugin.getAssets(this.platform))
+        .concat(plugin.getJsModules(this.platform))
+        .forEach(function (item) {
+            actions.push(actions.createAction(
+                self._getUninstaller(item.itemType), [item, plugin.dir, plugin.id, uninstallOptions, projectFile],
+                self._getInstaller(item.itemType), [item, plugin.dir, plugin.id, uninstallOptions, projectFile]));
+        });
+
+    // run through the action stack
+    return actions.process(this.platform, this.root)
+        .then(function () {
+            if (projectFile) {
+                projectFile.write();
+            }
+
+            self._munger
+                // Ignore passed `is_top_level` option since platform itself doesn't know
+                // anything about managing dependencies - it's responsibility of caller.
+                .remove_plugin_changes(plugin, /* is_top_level= */true)
+                .save_all();
+
+            var targetDir = uninstallOptions.usePlatformWww ?
+                self.getPlatformInfo().locations.platformWww :
+                self.getPlatformInfo().locations.www;
+
+            self._removeModulesInfo(plugin, targetDir);
+            // Remove stale plugin directory
+            // TODO: this should be done by plugin files uninstaller
+            shell.rm('-rf', path.resolve(self.root, 'Plugins', plugin.id));
+        });
+};
+
+Api.prototype._getInstaller = function (type) {
+    var self = this;
+    return function (item, plugin_dir, plugin_id, options, project) {
+        var installer = self._handler[type];
+
+        if (!installer) {
+            console.log('unrecognized type ' + type);
+
+        } else {
+            var wwwDest = options.usePlatformWww ?
+                self.getPlatformInfo().locations.platformWww :
+                self._handler.www_dir(self.root);
+
+            if (type === 'asset') {
+                installer.install(item, plugin_dir, wwwDest);
+            } else if (type === 'js-module') {
+                installer.install(item, plugin_dir, plugin_id, wwwDest);
+            } else {
+                installer.install(item, plugin_dir, self.root, plugin_id, options, project);
+            }
+        }
+    };
+};
+
+Api.prototype._getUninstaller = function (type) {
+    var self = this;
+    return function (item, plugin_dir, plugin_id, options, project) {
+        var installer = self._handler[type];
+
+        if (!installer) {
+            console.log('browser plugin uninstall: unrecognized type, skipping : ' + type);
+
+        } else {
+            var wwwDest = options.usePlatformWww ?
+                self.getPlatformInfo().locations.platformWww :
+                self._handler.www_dir(self.root);
+
+            if (['asset', 'js-module'].indexOf(type) > -1) {
+                return installer.uninstall(item, wwwDest, plugin_id);
+            } else {
+                return installer.uninstall(item, self.root, plugin_id, options, project);
+            }
+
+        }
+    };
+};
+
+/**
+ * Removes the specified modules from list of installed modules and updates
+ *   platform_json and cordova_plugins.js on disk.
+ *
+ * @param   {PluginInfo}  plugin  PluginInfo instance for plugin, which modules
+ *   needs to be added.
+ * @param   {String}  targetDir  The directory, where updated cordova_plugins.js
+ *   should be written to.
+ */
+Api.prototype._addModulesInfo = function (plugin, targetDir) {
+    var installedModules = this._platformJson.root.modules || [];
+
+    var installedPaths = installedModules.map(function (installedModule) {
+        return installedModule.file;
+    });
+
+    var modulesToInstall = plugin.getJsModules(this.platform)
+        .filter(function (moduleToInstall) {
+            return installedPaths.indexOf(moduleToInstall.file) === -1;
+        }).map(function (moduleToInstall) {
+            var moduleName = plugin.id + '.' + (moduleToInstall.name || moduleToInstall.src.match(/([^\/]+)\.js/)[1]);
+            var obj = {
+                file: ['plugins', plugin.id, moduleToInstall.src].join('/'), /* eslint no-useless-escape : 0 */
+                id: moduleName,
+                pluginId: plugin.id
+            };
+            if (moduleToInstall.clobbers.length > 0) {
+                obj.clobbers = moduleToInstall.clobbers.map(function (o) { return o.target; });
+            }
+            if (moduleToInstall.merges.length > 0) {
+                obj.merges = moduleToInstall.merges.map(function (o) { return o.target; });
+            }
+            if (moduleToInstall.runs) {
+                obj.runs = true;
+            }
+
+            return obj;
+        });
+
+    this._platformJson.root.modules = installedModules.concat(modulesToInstall);
+    if (!this._platformJson.root.plugin_metadata) {
+        this._platformJson.root.plugin_metadata = {};
+    }
+    this._platformJson.root.plugin_metadata[plugin.id] = plugin.version;
+
+    this._writePluginModules(targetDir);
+    this._platformJson.save();
+};
+/**
+ * Fetches all installed modules, generates cordova_plugins contents and writes
+ *   it to file.
+ *
+ * @param   {String}  targetDir  Directory, where write cordova_plugins.js to.
+ *   Ususally it is either <platform>/www or <platform>/platform_www
+ *   directories.
+ */
+Api.prototype._writePluginModules = function (targetDir) {
+    // Write out moduleObjects as JSON wrapped in a cordova module to cordova_plugins.js
+    var final_contents = 'cordova.define(\'cordova/plugin_list\', function(require, exports, module) {\n';
+    final_contents += 'module.exports = ' + JSON.stringify(this._platformJson.root.modules, null, '    ') + ';\n';
+    final_contents += 'module.exports.metadata = \n';
+    final_contents += '// TOP OF METADATA\n';
+    final_contents += JSON.stringify(this._platformJson.root.plugin_metadata || {}, null, '    ') + '\n';
+    final_contents += '// BOTTOM OF METADATA\n';
+    final_contents += '});'; // Close cordova.define.
+
+    shell.mkdir('-p', targetDir);
+    fs.writeFileSync(path.join(targetDir, 'cordova_plugins.js'), final_contents, 'utf-8');
+};
+
+/**
+ * Removes the specified modules from list of installed modules and updates
+ *   platform_json and cordova_plugins.js on disk.
+ *
+ * @param   {PluginInfo}  plugin  PluginInfo instance for plugin, which modules
+ *   needs to be removed.
+ * @param   {String}  targetDir  The directory, where updated cordova_plugins.js
+ *   should be written to.
+ */
+Api.prototype._removeModulesInfo = function (plugin, targetDir) {
+    var installedModules = this._platformJson.root.modules || [];
+    var modulesToRemove = plugin.getJsModules(this.platform)
+        .map(function (jsModule) {
+            return ['plugins', plugin.id, jsModule.src].join('/');
+        });
+
+    var updatedModules = installedModules
+        .filter(function (installedModule) {
+            return (modulesToRemove.indexOf(installedModule.file) === -1);
+        });
+
+    this._platformJson.root.modules = updatedModules;
+    if (this._platformJson.root.plugin_metadata) {
+        delete this._platformJson.root.plugin_metadata[plugin.id];
+    }
+
+    this._writePluginModules(targetDir);
+    this._platformJson.save();
+};
+
+Api.prototype.build = function (buildOptions) {
+    var self = this;
+    return require('./lib/check_reqs').run()
+        .then(function () {
+            return require('./lib/build').run.call(self, buildOptions);
+        });
+};
+
+Api.prototype.run = function (runOptions) {
+    return require('./lib/run').run(runOptions);
+};
+
+Api.prototype.clean = function (cleanOptions) {
+    return require('./lib/clean').run(cleanOptions);
+};
+
+Api.prototype.requirements = function () {
+    return require('./lib/check_reqs').run();
+};
+
+module.exports = Api;
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/browser_handler.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/browser_handler.js
new file mode 100644
index 0000000..3e12c25
--- /dev/null
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/browser_handler.js
@@ -0,0 +1,131 @@
+/**
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+*/
+
+var path = require('path');
+var fs = require('fs');
+var shell = require('shelljs');
+var events = require('cordova-common').events;
+
+module.exports = {
+    www_dir: function (project_dir) {
+        return path.join(project_dir, 'www');
+    },
+    package_name: function (project_dir) {
+        // this method should the id from root config.xml => <widget id=xxx
+        // return common.package_name(project_dir, this.www_dir(project_dir));
+        // console.log('package_name called with ' + project_dir);
+        var pkgName = 'io.cordova.hellocordova';
+        var widget_id_regex = /(?:<widget\s+id=['"])(\S+)(?:['"])/;
+
+        var configPath = path.join(project_dir, 'config.xml');
+        if (fs.existsSync(configPath)) {
+            var configStr = fs.readFileSync(configPath, 'utf8');
+            var res = configStr.match(widget_id_regex);
+            if (res && res.length > 1) {
+                pkgName = res[1];
+            }
+        }
+        return pkgName;
+    },
+    'js-module': {
+        install: function (jsModule, plugin_dir, plugin_id, www_dir) {
+            // Copy the plugin's files into the www directory.
+            var moduleSource = path.resolve(plugin_dir, jsModule.src);
+            // Get module name based on existing 'name' attribute or filename
+            // Must use path.extname/path.basename instead of path.parse due to CB-9981
+            var moduleName = plugin_id + '.' + (jsModule.name || path.basename(jsModule.src, path.extname(jsModule.src)));
+
+            // Read in the file, prepend the cordova.define, and write it back out.
+            var scriptContent = fs.readFileSync(moduleSource, 'utf-8').replace(/^\ufeff/, ''); // Window BOM
+            if (moduleSource.match(/.*\.json$/)) {
+                scriptContent = 'module.exports = ' + scriptContent;
+            }
+            scriptContent = 'cordova.define("' + moduleName + '", function(require, exports, module) { ' + scriptContent + '\n});\n';
+
+            var moduleDestination = path.resolve(www_dir, 'plugins', plugin_id, jsModule.src);
+            shell.mkdir('-p', path.dirname(moduleDestination));
+            fs.writeFileSync(moduleDestination, scriptContent, 'utf-8');
+        },
+        uninstall: function (jsModule, www_dir, plugin_id) {
+            var pluginRelativePath = path.join('plugins', plugin_id, jsModule.src);
+            // common.removeFileAndParents(www_dir, pluginRelativePath);
+            console.log('js-module uninstall called : ' + pluginRelativePath);
+        }
+    },
+    'source-file': {
+        install: function (obj, plugin_dir, project_dir, plugin_id, options) {
+            // var dest = path.join(obj.targetDir, path.basename(obj.src));
+            // common.copyFile(plugin_dir, obj.src, project_dir, dest);
+            console.log('install called');
+        },
+        uninstall: function (obj, project_dir, plugin_id, options) {
+            // var dest = path.join(obj.targetDir, path.basename(obj.src));
+            // common.removeFile(project_dir, dest);
+            console.log('uninstall called');
+        }
+    },
+    'header-file': {
+        install: function (obj, plugin_dir, project_dir, plugin_id, options) {
+            events.emit('verbose', 'header-fileinstall is not supported for browser');
+        },
+        uninstall: function (obj, project_dir, plugin_id, options) {
+            events.emit('verbose', 'header-file.uninstall is not supported for browser');
+        }
+    },
+    'resource-file': {
+        install: function (obj, plugin_dir, project_dir, plugin_id, options) {
+            events.emit('verbose', 'resource-file.install is not supported for browser');
+        },
+        uninstall: function (obj, project_dir, plugin_id, options) {
+            events.emit('verbose', 'resource-file.uninstall is not supported for browser');
+        }
+    },
+    'framework': {
+        install: function (obj, plugin_dir, project_dir, plugin_id, options) {
+            events.emit('verbose', 'framework.install is not supported for browser');
+        },
+        uninstall: function (obj, project_dir, plugin_id, options) {
+            events.emit('verbose', 'framework.uninstall is not supported for browser');
+        }
+    },
+    'lib-file': {
+        install: function (obj, plugin_dir, project_dir, plugin_id, options) {
+            events.emit('verbose', 'lib-file.install is not supported for browser');
+        },
+        uninstall: function (obj, project_dir, plugin_id, options) {
+            events.emit('verbose', 'lib-file.uninstall is not supported for browser');
+        }
+    },
+    asset: {
+        install: function (asset, plugin_dir, wwwDest) {
+            var src = path.join(plugin_dir, asset.src);
+            var dest = path.join(wwwDest, asset.target);
+
+            if (fs.statSync(src).isDirectory()) {
+                shell.cp('-Rf', src + '/*', dest);
+            } else {
+                shell.cp('-f', src, dest);
+            }
+        },
+        uninstall: function (asset, wwwDest, plugin_id) {
+            shell.rm('-rf', path.join(wwwDest, asset.target));
+            shell.rm('-rf', path.join(wwwDest, 'plugins', plugin_id));
+        }
+    }
+};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/browser_parser.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/browser_parser.js
new file mode 100644
index 0000000..99397c3
--- /dev/null
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/browser_parser.js
@@ -0,0 +1,120 @@
+/**
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+*/
+
+var fs = require('fs');
+var path = require('path');
+var shell = require('shelljs');
+var CordovaError = require('cordova-common').CordovaError;
+var events = require('cordova-common').events;
+var FileUpdater = require('cordova-common').FileUpdater;
+
+function dirExists (dir) {
+    return fs.existsSync(dir) && fs.statSync(dir).isDirectory();
+}
+
+function browser_parser (project) {
+    if (!dirExists(project) || !dirExists(path.join(project, 'cordova'))) {
+        throw new CordovaError('The provided path "' + project + '" is not a valid browser project.');
+    }
+    this.path = project;
+}
+
+module.exports = browser_parser;
+
+// Returns a promise.
+browser_parser.prototype.update_from_config = function () {
+    return Promise.resolve();
+};
+
+browser_parser.prototype.www_dir = function () {
+    return path.join(this.path, 'www');
+};
+
+// Used for creating platform_www in projects created by older versions.
+browser_parser.prototype.cordovajs_path = function (libDir) {
+    var jsPath = path.join(libDir, 'cordova-lib', 'cordova.js');
+    return path.resolve(jsPath);
+};
+
+browser_parser.prototype.cordovajs_src_path = function (libDir) {
+    // console.log("cordovajs_src_path");
+    var jsPath = path.join(libDir, 'cordova-js-src');
+    return path.resolve(jsPath);
+};
+
+/**
+ * Logs all file operations via the verbose event stream, indented.
+ */
+function logFileOp (message) {
+    events.emit('verbose', '  ' + message);
+}
+
+// Replace the www dir with contents of platform_www and app www.
+browser_parser.prototype.update_www = function (cordovaProject, opts) {
+    var platform_www = path.join(this.path, 'platform_www');
+    var my_www = this.www_dir();
+    // add cordova www and platform_www to sourceDirs
+    var sourceDirs = [
+        path.relative(cordovaProject.root, cordovaProject.locations.www),
+        path.relative(cordovaProject.root, platform_www)
+    ];
+
+    // If project contains 'merges' for our platform, use them as another overrides
+    var merges_path = path.join(cordovaProject.root, 'merges', 'browser');
+    if (fs.existsSync(merges_path)) {
+        events.emit('verbose', 'Found "merges/browser" folder. Copying its contents into the browser project.');
+        // add merges/browser to sourceDirs
+        sourceDirs.push(path.join('merges', 'browser'));
+    }
+
+    // targetDir points to browser/www
+    var targetDir = path.relative(cordovaProject.root, my_www);
+    events.emit('verbose', 'Merging and updating files from [' + sourceDirs.join(', ') + '] to ' + targetDir);
+    FileUpdater.mergeAndUpdateDir(sourceDirs, targetDir, { rootDir: cordovaProject.root }, logFileOp);
+};
+
+browser_parser.prototype.update_overrides = function () {
+    // console.log("update_overrides");
+
+    // TODO: ?
+    // var projectRoot = util.isCordova(this.path);
+    // var mergesPath = path.join(util.appDir(projectRoot), 'merges', 'browser');
+    // if(fs.existsSync(mergesPath)) {
+    //     var overrides = path.join(mergesPath, '*');
+    //     shell.cp('-rf', overrides, this.www_dir());
+    // }
+};
+
+browser_parser.prototype.config_xml = function () {
+    return path.join(this.path, 'config.xml');
+};
+
+// Returns a promise.
+browser_parser.prototype.update_project = function (cfg) {
+    // console.log("update_project ",cfg);
+    var defer = this.update_from_config();
+    var self = this;
+    var www_dir = self.www_dir();
+    defer.then(function () {
+        self.update_overrides();
+        // Copy munged config.xml to platform www dir
+        shell.cp('-rf', path.join(www_dir, '..', 'config.xml'), www_dir);
+    });
+    return defer;
+};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/build b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/build
similarity index 100%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/build
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/build
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/build.bat b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/build.bat
similarity index 100%
copy from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/build.bat
copy to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/build.bat
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/clean b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/clean
similarity index 95%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/clean
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/clean
index da21bc7..1852d66 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/clean
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/clean
@@ -22,7 +22,6 @@
 
 var path = require('path'),
     clean = require('./lib/clean'),
-    reqs  = require('./lib/check_reqs'),
     args  = process.argv;
 
 // Support basic help commands
@@ -32,6 +31,6 @@ if ( args.length > 2
     console.log('Usage: ' + path.relative(process.cwd(), path.join(__dirname, 'clean')) );
     process.exit(0);
 } else {
-    clean.cleanProject();
+    clean.run();
 }
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/build.bat b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/clean.bat
similarity index 90%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/build.bat
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/clean.bat
index 02641bc..5c572aa 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/build.bat
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/clean.bat
@@ -16,11 +16,11 @@
 :: under the License.
 
 @ECHO OFF
-SET script_path="%~dp0build"
+SET script_path="%~dp0clean"
 IF EXIST %script_path% (
         node %script_path% %*
 ) ELSE (
     ECHO.
-    ECHO ERROR: Could not find 'build' script in 'cordova' folder, aborting...>&2
+    ECHO ERROR: Could not find 'clean' script in 'cordova' folder, aborting...>&2
     EXIT /B 1
 )
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/defaults.xml b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/defaults.xml
similarity index 100%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/defaults.xml
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/defaults.xml
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/clean.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/build.js
similarity index 53%
copy from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/clean.js
copy to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/build.js
index 2e4367d..01f3fb1 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/clean.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/build.js
@@ -18,29 +18,20 @@
  * specific language governing permissions and limitations
  * under the License.
  */
- 
-var fs = require('fs'),
-    shjs = require('shelljs'),
-    path = require('path'),
-    check_reqs = require('./check_reqs'),
-    platformBuildDir = path.join('platforms', 'browser', 'build');
 
-exports.cleanProject = function(){
+var path = require('path');
+var check_reqs = require('./check_reqs');
 
-    // Check that requirements are (stil) met
-    if (!check_reqs.run()) {
-        console.error('Please make sure you meet the software requirements in order to clean an browser cordova project');
-        process.exit(2);
-    }
-    
-    console.log('Cleaning Browser project');
-    try {
-        if (fs.existsSync(platformBuildDir)) {
-            shjs.rm('-r', platformBuildDir);
-        }
-    }
-    catch(err) {
-        console.log('could not remove '+platformBuildDir+' : '+err.message);
-    }
+/**
+ * run
+ *   Creates a zip file int platform/build folder
+ */
+module.exports.run = function () {
+    return check_reqs.run();
 };
 
+module.exports.help = function () {
+    console.log('Usage: cordova build browser');
+    var wwwPath = path.resolve(path.join(__dirname, '../../www'));
+    console.log("Build will create the packaged app in '" + wwwPath + "'.");
+};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/clean.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/clean.js
similarity index 58%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/clean.js
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/clean.js
index 2e4367d..6ee7675 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/clean.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/clean.js
@@ -18,29 +18,34 @@
  * specific language governing permissions and limitations
  * under the License.
  */
- 
-var fs = require('fs'),
-    shjs = require('shelljs'),
-    path = require('path'),
-    check_reqs = require('./check_reqs'),
-    platformBuildDir = path.join('platforms', 'browser', 'build');
 
-exports.cleanProject = function(){
+var fs = require('fs');
+var shell = require('shelljs');
+var path = require('path');
+var check_reqs = require('./check_reqs');
+var platformBuildDir = path.join('platforms', 'browser', 'www');
 
-    // Check that requirements are (stil) met
+var run = function () {
+
+    // TODO: everything calls check_reqs ... why?
+    // Check that requirements are (still) met
     if (!check_reqs.run()) {
         console.error('Please make sure you meet the software requirements in order to clean an browser cordova project');
         process.exit(2);
     }
-    
-    console.log('Cleaning Browser project');
+
     try {
         if (fs.existsSync(platformBuildDir)) {
-            shjs.rm('-r', platformBuildDir);
+            shell.rm('-r', platformBuildDir);
         }
-    }
-    catch(err) {
-        console.log('could not remove '+platformBuildDir+' : '+err.message);
+    } catch (err) {
+        console.log('could not remove ' + platformBuildDir + ' : ' + err.message);
     }
 };
 
+module.exports.run = run;
+// just on the off chance something is still calling cleanProject, we will leave this here for a while
+module.exports.cleanProject = function () {
+    console.log('lib/clean will soon only export a `run` command, please update to not call `cleanProject`.');
+    return run();
+};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/run.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/run.js
new file mode 100644
index 0000000..fc58630
--- /dev/null
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/lib/run.js
@@ -0,0 +1,65 @@
+#!/usr/bin/env node
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+var fs = require('fs');
+var path = require('path');
+var url = require('url');
+var cordovaServe = require('cordova-serve');
+
+module.exports.run = function (args) {
+    // defaults
+    args.port = args.port || 8000;
+    args.target = args.target || 'default'; // make default the system browser
+
+    var wwwPath = path.join(__dirname, '../../www');
+    var manifestFilePath = path.resolve(path.join(wwwPath, 'manifest.json'));
+
+    var startPage;
+
+    // get start page from manifest
+    if (fs.existsSync(manifestFilePath)) {
+        try {
+            var manifest = require(manifestFilePath);
+            startPage = manifest.start_url;
+        } catch (err) {
+            console.log('failed to require manifest ... ' + err);
+        }
+    }
+
+    var server = cordovaServe();
+    server.servePlatform('browser', {port: args.port, noServerInfo: true})
+        .then(function () {
+            if (!startPage) {
+                // failing all else, set the default
+                startPage = 'index.html';
+            }
+            var projectUrl = url.resolve('http://localhost:' + server.port + '/', startPage);
+            console.log('startPage = ' + startPage);
+            console.log('Static file server running @ ' + projectUrl + '\nCTRL + C to shut down');
+            return server.launchBrowser({'target': args.target, 'url': projectUrl});
+        })
+        .catch(function (error) {
+            console.log(error.message || error.toString());
+            if (server.server) {
+                server.server.close();
+            }
+        });
+};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/version b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/log
similarity index 91%
copy from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/version
copy to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/log
index 8acf18f..bb6fb8c 100755
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/version
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/log
@@ -8,9 +8,7 @@
        to you under the Apache License, Version 2.0 (the
        "License"); you may not use this file except in compliance
        with the License.  You may obtain a copy of the License at
-
          http://www.apache.org/licenses/LICENSE-2.0
-
        Unless required by applicable law or agreed to in writing,
        software distributed under the License is distributed on an
        "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -19,7 +17,4 @@
        under the License.
 */
 
-// Coho updates this line:
-var VERSION = "4.2.0-dev";
-
-console.log(VERSION);
+console.log("cordova/log");
\ No newline at end of file
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/run b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/run
similarity index 65%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/run
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/run
index d4c690b..b41e299 100755
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/run
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/run
@@ -10,7 +10,7 @@
        with the License.  You may obtain a copy of the License at
 
          http://www.apache.org/licenses/LICENSE-2.0
-    
+
        Unless required by applicable law or agreed to in writing,
        software distributed under the License is distributed on an
        "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -23,6 +23,7 @@ var fs = require('fs'),
     path = require('path'),
     nopt  = require('nopt'),
     url = require('url'),
+    runForrest = require('./lib/run'),
     cordovaServe = require('cordova-serve');
 
 var args = process.argv;
@@ -34,27 +35,9 @@ function start(argv) {
     if(args.help) {
         help();
     }
-
-    // defaults
-    args.port = args.port || 8000;
-    args.target = args.target || "chrome";
-
-    var root = path.join(__dirname, '../'),
-        configFile = path.resolve(path.join(root, 'config.xml')),
-        configXML = fs.readFileSync(configFile, 'utf8'),
-        sourceFile = /<content[\s]+?src\s*=\s*"(.*?)"/i.exec(configXML);
-
-    var server = cordovaServe();
-    server.servePlatform('browser', {port: args.port, noServerInfo: true}).then(function () {
-        var projectUrl = url.resolve('http://localhost:' + server.port + '/', sourceFile ? sourceFile[1] : 'index.html');
-        console.log('Static file server running @ ' + projectUrl + '\nCTRL + C to shut down');
-        return cordovaServe.launchBrowser({target: args.target, url: projectUrl});
-    }).catch(function (error) {
-        console.log(error.message || error.toString());
-        if (server.server) {
-            server.server.close();
-        }
-    });
+    else {
+        return runForrest.run(args);
+    }
 }
 
 function help() {
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/run.bat b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/run.bat
similarity index 100%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/run.bat
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/run.bat
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/version b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/version
similarity index 97%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/version
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/version
index 8acf18f..bde86e6 100755
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/version
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/version
@@ -20,6 +20,6 @@
 */
 
 // Coho updates this line:
-var VERSION = "4.2.0-dev";
+var VERSION = "5.1.0-dev";
 
 console.log(VERSION);
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/version.bat b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/version.bat
similarity index 100%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/version.bat
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/cordova/version.bat
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/css/index.css b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/css/index.css
similarity index 100%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/css/index.css
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/css/index.css
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/favicon.ico b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/favicon.ico
new file mode 100644
index 0000000..fa7a758
Binary files /dev/null and b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/favicon.ico differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/img/logo.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/img/logo.png
new file mode 100644
index 0000000..4453279
Binary files /dev/null and b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/img/logo.png differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/img/splash.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/img/splash.png
new file mode 100644
index 0000000..38acd8f
Binary files /dev/null and b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/img/splash.png differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/index.html b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/index.html
similarity index 92%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/index.html
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/index.html
index bde5741..42eb422 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/index.html
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/index.html
@@ -21,9 +21,10 @@
     <head>
         <meta charset="utf-8" />
         <meta name="format-detection" content="telephone=no" />
-        <!-- WARNING: for iOS 7, remove the width=device-width and height=device-height attributes. See https://issues.apache.org/jira/browse/CB-4323 -->
+        <meta name="theme-color" content="#2196F3"/>
         <meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=device-dpi" />
         <link rel="stylesheet" type="text/css" href="css/index.css" />
+        <link rel="manifest" href="manifest.json">
         <title>Hello World</title>
     </head>
     <body>
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/js/index.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/js/index.js
similarity index 93%
rename from spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/js/index.js
rename to spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/js/index.js
index 31d9064..1750a54 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/js/index.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/js/index.js
@@ -18,25 +18,25 @@
  */
 var app = {
     // Application Constructor
-    initialize: function() {
+    initialize: function () {
         this.bindEvents();
     },
     // Bind Event Listeners
     //
     // Bind any events that are required on startup. Common events are:
     // 'load', 'deviceready', 'offline', and 'online'.
-    bindEvents: function() {
+    bindEvents: function () {
         document.addEventListener('deviceready', this.onDeviceReady, false);
     },
     // deviceready Event Handler
     //
     // The scope of 'this' is the event. In order to call the 'receivedEvent'
     // function, we must explicity call 'app.receivedEvent(...);'
-    onDeviceReady: function() {
+    onDeviceReady: function () {
         app.receivedEvent('deviceready');
     },
     // Update DOM on a Received Event
-    receivedEvent: function(id) {
+    receivedEvent: function (id) {
         var parentElement = document.getElementById(id);
         var listeningElement = parentElement.querySelector('.listening');
         var receivedElement = parentElement.querySelector('.received');
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/manifest.json b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/manifest.json
new file mode 100644
index 0000000..b7e3981
--- /dev/null
+++ b/spec/cordova/fixtures/platforms/cordova-browser/bin/template/www/manifest.json
@@ -0,0 +1,21 @@
+{
+  "name": "My App",
+  "short_name":"My Ap",
+  "description": "Description of your app from template",
+  "start_url": "index.html",
+  "scope":"index.html",
+  "icons": [{
+    "src": "img/logo.png",
+    "sizes": "192x192",
+    "type": "image/png"
+  }, {
+    "src": "img/splash.png",
+    "sizes": "512x512",
+    "type": "image/png"
+  }],
+  "default_locale": "en",
+  "display": "standalone",
+  "background_color":"#FFF",
+  "theme_color":"#000",
+  "orientation": "landscape"
+}
\ No newline at end of file
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/build.js b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/build.js
deleted file mode 100644
index fde7519..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/cordova/lib/build.js
+++ /dev/null
@@ -1,65 +0,0 @@
-#!/usr/bin/env node
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
- 
-var path    = require('path'),
-    fs      = require('fs'),
-    shjs    = require('shelljs'),
-    zip     = require('adm-zip'),
-    Q       = require('q'),
-    clean   = require('./clean'),
-    check_reqs = require('./check_reqs'),
-    platformWwwDir          = path.join('platforms', 'browser', 'www'),
-    platformBuildDir        = path.join('platforms', 'browser', 'build'),
-    packageFile             = path.join(platformBuildDir, 'package.zip');
-
-/**
- * run
- *   Creates a zip file int platform/build folder
- */
-module.exports.run = function(){
-
-    return check_reqs.run()
-    .then(function(){
-            return clean.cleanProject();
-        },
-        function checkReqsError(err){
-            console.error('Please make sure you meet the software requirements in order to build a browser cordova project');
-    })
-    .then(function(){
-
-        if (!fs.existsSync(platformBuildDir)) {
-            fs.mkdirSync(platformBuildDir);
-        }
-
-        // add the project to a zipfile
-        var zipFile = zip();
-        zipFile.addLocalFolder(platformWwwDir, '.');
-        zipFile.writeZip(packageFile);
-
-        return Q.resolve();
-
-    });
-};
-
-module.exports.help = function() {
-    console.log('Usage: cordova build browser');
-    console.log('Build will create the packaged app in \''+platformBuildDir+'\'.');
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/img/logo.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/img/logo.png
deleted file mode 100644
index 9519e7d..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/img/logo.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/manifest.webapp b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/manifest.webapp
deleted file mode 100644
index f24deb8..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/manifest.webapp
+++ /dev/null
@@ -1,10 +0,0 @@
-{
-  "name": "My App",
-  "description": "Description of your app",
-  "launch_path": "/index.html",
-  "icons": {
-    "128": "/img/logo.png"
-  },
-  "default_locale": "en",
-  "type": "privileged"
-}
\ No newline at end of file
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-36-ldpi.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-36-ldpi.png
deleted file mode 100644
index cd5032a..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-36-ldpi.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-48-mdpi.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-48-mdpi.png
deleted file mode 100644
index e79c606..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-48-mdpi.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-72-hdpi.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-72-hdpi.png
deleted file mode 100644
index 4d27634..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-72-hdpi.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-96-xhdpi.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-96-xhdpi.png
deleted file mode 100644
index ec7ffbf..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/android/icon-96-xhdpi.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-48-type5.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-48-type5.png
deleted file mode 100644
index 8ad8bac..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-48-type5.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-50-type3.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-50-type3.png
deleted file mode 100644
index c6ddf84..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-50-type3.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-80-type4.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-80-type4.png
deleted file mode 100644
index f86a27a..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada-wac/icon-80-type4.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada/icon-128.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada/icon-128.png
deleted file mode 100644
index 3516df3..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/bada/icon-128.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/blackberry/icon-80.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/blackberry/icon-80.png
deleted file mode 100644
index f86a27a..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/blackberry/icon-80.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/blackberry10/icon-80.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/blackberry10/icon-80.png
deleted file mode 100644
index f86a27a..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/blackberry10/icon-80.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-57-2x.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-57-2x.png
deleted file mode 100644
index efd9c37..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-57-2x.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-57.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-57.png
deleted file mode 100644
index c795fc4..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-57.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-72-2x.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-72-2x.png
deleted file mode 100644
index dd819da..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-72-2x.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-72.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-72.png
deleted file mode 100644
index b1cfde7..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/ios/icon-72.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/tizen/icon-128.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/tizen/icon-128.png
deleted file mode 100644
index 3516df3..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/tizen/icon-128.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/webos/icon-64.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/webos/icon-64.png
deleted file mode 100644
index 03b3849..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/webos/icon-64.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-173-tile.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-173-tile.png
deleted file mode 100644
index 4f15e20..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-173-tile.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-48.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-48.png
deleted file mode 100644
index 8ad8bac..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-48.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-62-tile.png b/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-62-tile.png
deleted file mode 100644
index aab6061..0000000
Binary files a/spec/cordova/fixtures/platforms/cordova-browser/bin/templates/project/www/res/icon/windows-phone/icon-62-tile.png and /dev/null differ
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/cordova-js-src/confighelper.js b/spec/cordova/fixtures/platforms/cordova-browser/cordova-js-src/confighelper.js
index b6d606e..4d99959 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/cordova-js-src/confighelper.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/cordova-js-src/confighelper.js
@@ -61,14 +61,9 @@ function readConfig(success, error) {
         }
     };
 
-    if ("ActiveXObject" in window) {
-        // Needed for XHR-ing via file:// protocol in IE
-        xhr = new window.ActiveXObject("MSXML2.XMLHTTP");
-        xhr.onreadystatechange = xhrStatusChangeHandler;
-    } else {
-        xhr = new XMLHttpRequest();
-        xhr.addEventListener("load", xhrStatusChangeHandler);
-    }
+    xhr = new XMLHttpRequest();
+    xhr.addEventListener("load", xhrStatusChangeHandler);
+
 
     try {
         xhr.open("get", "/config.xml", true);
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/cordova-js-src/platform.js b/spec/cordova/fixtures/platforms/cordova-browser/cordova-js-src/platform.js
index 0514059..96eb943 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/cordova-js-src/platform.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/cordova-js-src/platform.js
@@ -21,7 +21,7 @@
 
 module.exports = {
     id: 'browser',
-    cordovaVersion: '3.4.0',
+    cordovaVersion: '4.2.0', // cordova-js
 
     bootstrap: function() {
 
@@ -32,16 +32,14 @@ module.exports = {
 
         channel.onNativeReady.fire();
 
-        // FIXME is this the right place to clobber pause/resume? I am guessing not
-        // FIXME pause/resume should be deprecated IN CORDOVA for pagevisiblity api
-        document.addEventListener('webkitvisibilitychange', function() {
-            if (document.webkitHidden) {
+        document.addEventListener("visibilitychange", function(){
+            if(document.hidden) {
                 channel.onPause.fire();
             }
             else {
                 channel.onResume.fire();
             }
-        }, false);
+        });
 
     // End of bootstrap
     }
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/cordova-lib/cordova.js b/spec/cordova/fixtures/platforms/cordova-browser/cordova-lib/cordova.js
index d2edd37..798dc6c 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/cordova-lib/cordova.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/cordova-lib/cordova.js
@@ -1,5 +1,5 @@
 // Platform: browser
-// c517ca811b4948b630e0b74dbae6c9637939da24
+// ff66178b108b93be36a1aafe341af17381a727a3
 /*
  Licensed to the Apache Software Foundation (ASF) under one
  or more contributor license agreements.  See the NOTICE file
@@ -19,35 +19,33 @@
  under the License.
 */
 ;(function() {
-var PLATFORM_VERSION_BUILD_LABEL = '4.2.0-dev';
+var PLATFORM_VERSION_BUILD_LABEL = '5.1.0-dev';
 // file: src/scripts/require.js
 
-/*jshint -W079 */
-/*jshint -W020 */
+/* jshint -W079 */
+/* jshint -W020 */
 
-var require,
-    define;
+var require;
+var define;
 
 (function () {
-    var modules = {},
+    var modules = {};
     // Stack of moduleIds currently being built.
-        requireStack = [],
+    var requireStack = [];
     // Map of module ID -> index into requireStack of modules currently being built.
-        inProgressModules = {},
-        SEPARATOR = ".";
-
-
-
-    function build(module) {
-        var factory = module.factory,
-            localRequire = function (id) {
-                var resultantId = id;
-                //Its a relative path, so lop off the last portion and add the id (minus "./")
-                if (id.charAt(0) === ".") {
-                    resultantId = module.id.slice(0, module.id.lastIndexOf(SEPARATOR)) + SEPARATOR + id.slice(2);
-                }
-                return require(resultantId);
-            };
+    var inProgressModules = {};
+    var SEPARATOR = '.';
+
+    function build (module) {
+        var factory = module.factory;
+        var localRequire = function (id) {
+            var resultantId = id;
+            // Its a relative path, so lop off the last portion and add the id (minus "./")
+            if (id.charAt(0) === '.') {
+                resultantId = module.id.slice(0, module.id.lastIndexOf(SEPARATOR)) + SEPARATOR + id.slice(2);
+            }
+            return require(resultantId);
+        };
         module.exports = {};
         delete module.factory;
         factory(localRequire, module.exports, module);
@@ -56,10 +54,10 @@ var require,
 
     require = function (id) {
         if (!modules[id]) {
-            throw "module " + id + " not found";
+            throw 'module ' + id + ' not found';
         } else if (id in inProgressModules) {
             var cycle = requireStack.slice(inProgressModules[id]).join('->') + '->' + id;
-            throw "Cycle in require graph: " + cycle;
+            throw 'Cycle in require graph: ' + cycle;
         }
         if (modules[id].factory) {
             try {
@@ -76,7 +74,7 @@ var require,
 
     define = function (id, factory) {
         if (modules[id]) {
-            throw "module " + id + " already defined";
+            throw 'module ' + id + ' already defined';
         }
 
         modules[id] = {
@@ -92,8 +90,8 @@ var require,
     define.moduleMap = modules;
 })();
 
-//Export for use in node
-if (typeof module === "object" && typeof require === "function") {
+// Export for use in node
+if (typeof module === 'object' && typeof require === 'function') {
     module.exports.require = require;
     module.exports.define = define;
 }
@@ -103,15 +101,13 @@ define("cordova", function(require, exports, module) {
 
 // Workaround for Windows 10 in hosted environment case
 // http://www.w3.org/html/wg/drafts/html/master/browsers.html#named-access-on-the-window-object
-if (window.cordova && !(window.cordova instanceof HTMLElement)) {
-    throw new Error("cordova already defined");
+if (window.cordova && !(window.cordova instanceof HTMLElement)) { // eslint-disable-line no-undef
+    throw new Error('cordova already defined');
 }
 
-
 var channel = require('cordova/channel');
 var platform = require('cordova/platform');
 
-
 /**
  * Intercept calls to addEventListener + removeEventListener and handle deviceready,
  * resume, and pause events.
@@ -124,48 +120,48 @@ var m_window_removeEventListener = window.removeEventListener;
 /**
  * Houses custom event handlers to intercept on document + window event listeners.
  */
-var documentEventHandlers = {},
-    windowEventHandlers = {};
+var documentEventHandlers = {};
+var windowEventHandlers = {};
 
-document.addEventListener = function(evt, handler, capture) {
+document.addEventListener = function (evt, handler, capture) {
     var e = evt.toLowerCase();
-    if (typeof documentEventHandlers[e] != 'undefined') {
+    if (typeof documentEventHandlers[e] !== 'undefined') {
         documentEventHandlers[e].subscribe(handler);
     } else {
         m_document_addEventListener.call(document, evt, handler, capture);
     }
 };
 
-window.addEventListener = function(evt, handler, capture) {
+window.addEventListener = function (evt, handler, capture) {
     var e = evt.toLowerCase();
-    if (typeof windowEventHandlers[e] != 'undefined') {
+    if (typeof windowEventHandlers[e] !== 'undefined') {
         windowEventHandlers[e].subscribe(handler);
     } else {
         m_window_addEventListener.call(window, evt, handler, capture);
     }
 };
 
-document.removeEventListener = function(evt, handler, capture) {
+document.removeEventListener = function (evt, handler, capture) {
     var e = evt.toLowerCase();
     // If unsubscribing from an event that is handled by a plugin
-    if (typeof documentEventHandlers[e] != "undefined") {
+    if (typeof documentEventHandlers[e] !== 'undefined') {
         documentEventHandlers[e].unsubscribe(handler);
     } else {
         m_document_removeEventListener.call(document, evt, handler, capture);
     }
 };
 
-window.removeEventListener = function(evt, handler, capture) {
+window.removeEventListener = function (evt, handler, capture) {
     var e = evt.toLowerCase();
     // If unsubscribing from an event that is handled by a plugin
-    if (typeof windowEventHandlers[e] != "undefined") {
+    if (typeof windowEventHandlers[e] !== 'undefined') {
         windowEventHandlers[e].unsubscribe(handler);
     } else {
         m_window_removeEventListener.call(window, evt, handler, capture);
     }
 };
 
-function createEvent(type, data) {
+function createEvent (type, data) {
     var event = document.createEvent('Events');
     event.initEvent(type, false, false);
     if (data) {
@@ -178,29 +174,32 @@ function createEvent(type, data) {
     return event;
 }
 
-
+/* eslint-disable no-undef */
 var cordova = {
-    define:define,
-    require:require,
-    version:PLATFORM_VERSION_BUILD_LABEL,
-    platformVersion:PLATFORM_VERSION_BUILD_LABEL,
-    platformId:platform.id,
+    define: define,
+    require: require,
+    version: PLATFORM_VERSION_BUILD_LABEL,
+    platformVersion: PLATFORM_VERSION_BUILD_LABEL,
+    platformId: platform.id,
+
+    /* eslint-enable no-undef */
+
     /**
      * Methods to add/remove your own addEventListener hijacking on document + window.
      */
-    addWindowEventHandler:function(event) {
+    addWindowEventHandler: function (event) {
         return (windowEventHandlers[event] = channel.create(event));
     },
-    addStickyDocumentEventHandler:function(event) {
+    addStickyDocumentEventHandler: function (event) {
         return (documentEventHandlers[event] = channel.createSticky(event));
     },
-    addDocumentEventHandler:function(event) {
+    addDocumentEventHandler: function (event) {
         return (documentEventHandlers[event] = channel.create(event));
     },
-    removeWindowEventHandler:function(event) {
+    removeWindowEventHandler: function (event) {
         delete windowEventHandlers[event];
     },
-    removeDocumentEventHandler:function(event) {
+    removeDocumentEventHandler: function (event) {
         delete documentEventHandlers[event];
     },
     /**
@@ -208,24 +207,23 @@ var cordova = {
      *
      * @return object
      */
-    getOriginalHandlers: function() {
+    getOriginalHandlers: function () {
         return {'document': {'addEventListener': m_document_addEventListener, 'removeEventListener': m_document_removeEventListener},
-        'window': {'addEventListener': m_window_addEventListener, 'removeEventListener': m_window_removeEventListener}};
+            'window': {'addEventListener': m_window_addEventListener, 'removeEventListener': m_window_removeEventListener}};
     },
     /**
      * Method to fire event from native code
      * bNoDetach is required for events which cause an exception which needs to be caught in native code
      */
-    fireDocumentEvent: function(type, data, bNoDetach) {
+    fireDocumentEvent: function (type, data, bNoDetach) {
         var evt = createEvent(type, data);
-        if (typeof documentEventHandlers[type] != 'undefined') {
-            if( bNoDetach ) {
+        if (typeof documentEventHandlers[type] !== 'undefined') {
+            if (bNoDetach) {
                 documentEventHandlers[type].fire(evt);
-            }
-            else {
-                setTimeout(function() {
+            } else {
+                setTimeout(function () {
                     // Fire deviceready on listeners that were registered before cordova.js was loaded.
-                    if (type == 'deviceready') {
+                    if (type === 'deviceready') {
                         document.dispatchEvent(evt);
                     }
                     documentEventHandlers[type].fire(evt);
@@ -235,10 +233,10 @@ var cordova = {
             document.dispatchEvent(evt);
         }
     },
-    fireWindowEvent: function(type, data) {
-        var evt = createEvent(type,data);
-        if (typeof windowEventHandlers[type] != 'undefined') {
-            setTimeout(function() {
+    fireWindowEvent: function (type, data) {
+        var evt = createEvent(type, data);
+        if (typeof windowEventHandlers[type] !== 'undefined') {
+            setTimeout(function () {
                 windowEventHandlers[type].fire(evt);
             }, 0);
         } else {
@@ -252,7 +250,7 @@ var cordova = {
     // Randomize the starting callbackId to avoid collisions after refreshing or navigating.
     // This way, it's very unlikely that any new callback would get the same callbackId as an old callback.
     callbackId: Math.floor(Math.random() * 2000000000),
-    callbacks:  {},
+    callbacks: {},
     callbackStatus: {
         NO_RESULT: 0,
         OK: 1,
@@ -269,14 +267,14 @@ var cordova = {
     /**
      * Called by native code when returning successful result from an action.
      */
-    callbackSuccess: function(callbackId, args) {
+    callbackSuccess: function (callbackId, args) {
         cordova.callbackFromNative(callbackId, true, args.status, [args.message], args.keepCallback);
     },
 
     /**
      * Called by native code when returning error result from an action.
      */
-    callbackError: function(callbackId, args) {
+    callbackError: function (callbackId, args) {
         // TODO: Deprecate callbackSuccess and callbackError in favour of callbackFromNative.
         // Derive success from status.
         cordova.callbackFromNative(callbackId, false, args.status, [args.message], args.keepCallback);
@@ -285,11 +283,11 @@ var cordova = {
     /**
      * Called by native code when returning the result from an action.
      */
-    callbackFromNative: function(callbackId, isSuccess, status, args, keepCallback) {
+    callbackFromNative: function (callbackId, isSuccess, status, args, keepCallback) {
         try {
             var callback = cordova.callbacks[callbackId];
             if (callback) {
-                if (isSuccess && status == cordova.callbackStatus.OK) {
+                if (isSuccess && status === cordova.callbackStatus.OK) {
                     callback.success && callback.success.apply(null, args);
                 } else if (!isSuccess) {
                     callback.fail && callback.fail.apply(null, args);
@@ -306,26 +304,24 @@ var cordova = {
                     delete cordova.callbacks[callbackId];
                 }
             }
-        }
-        catch (err) {
-            var msg = "Error in " + (isSuccess ? "Success" : "Error") + " callbackId: " + callbackId + " : " + err;
+        } catch (err) {
+            var msg = 'Error in ' + (isSuccess ? 'Success' : 'Error') + ' callbackId: ' + callbackId + ' : ' + err;
             console && console.log && console.log(msg);
-            cordova.fireWindowEvent("cordovacallbackerror", { 'message': msg });
+            cordova.fireWindowEvent('cordovacallbackerror', { 'message': msg });
             throw err;
         }
     },
-    addConstructor: function(func) {
-        channel.onCordovaReady.subscribe(function() {
+    addConstructor: function (func) {
+        channel.onCordovaReady.subscribe(function () {
             try {
                 func();
-            } catch(e) {
-                console.log("Failed to run constructor: " + e);
+            } catch (e) {
+                console.log('Failed to run constructor: ' + e);
             }
         });
     }
 };
 
-
 module.exports = cordova;
 
 });
@@ -346,29 +342,29 @@ var typeMap = {
     'O': 'Object'
 };
 
-function extractParamName(callee, argIndex) {
+function extractParamName (callee, argIndex) {
     return (/.*?\((.*?)\)/).exec(callee)[1].split(', ')[argIndex];
 }
 
-function checkArgs(spec, functionName, args, opt_callee) {
+function checkArgs (spec, functionName, args, opt_callee) {
     if (!moduleExports.enableChecks) {
         return;
     }
     var errMsg = null;
     var typeName;
     for (var i = 0; i < spec.length; ++i) {
-        var c = spec.charAt(i),
-            cUpper = c.toUpperCase(),
-            arg = args[i];
+        var c = spec.charAt(i);
+        var cUpper = c.toUpperCase();
+        var arg = args[i];
         // Asterix means allow anything.
-        if (c == '*') {
+        if (c === '*') {
             continue;
         }
         typeName = utils.typeName(arg);
-        if ((arg === null || arg === undefined) && c == cUpper) {
+        if ((arg === null || arg === undefined) && c === cUpper) {
             continue;
         }
-        if (typeName != typeMap[cUpper]) {
+        if (typeName !== typeMap[cUpper]) {
             errMsg = 'Expected ' + typeMap[cUpper];
             break;
         }
@@ -377,14 +373,14 @@ function checkArgs(spec, functionName, args, opt_callee) {
         errMsg += ', but got ' + typeName + '.';
         errMsg = 'Wrong type for parameter "' + extractParamName(opt_callee || args.callee, i) + '" of ' + functionName + ': ' + errMsg;
         // Don't log when running unit tests.
-        if (typeof jasmine == 'undefined') {
+        if (typeof jasmine === 'undefined') {
             console.error(errMsg);
         }
         throw TypeError(errMsg);
     }
 }
 
-function getValue(value, defaultValue) {
+function getValue (value, defaultValue) {
     return value === undefined ? defaultValue : value;
 }
 
@@ -392,7 +388,6 @@ moduleExports.checkArgs = checkArgs;
 moduleExports.getValue = getValue;
 moduleExports.enableChecks = true;
 
-
 });
 
 // file: src/common/base64.js
@@ -400,58 +395,58 @@ define("cordova/base64", function(require, exports, module) {
 
 var base64 = exports;
 
-base64.fromArrayBuffer = function(arrayBuffer) {
+base64.fromArrayBuffer = function (arrayBuffer) {
     var array = new Uint8Array(arrayBuffer);
     return uint8ToBase64(array);
 };
 
-base64.toArrayBuffer = function(str) {
-    var decodedStr = typeof atob != 'undefined' ? atob(str) : new Buffer(str,'base64').toString('binary');
+base64.toArrayBuffer = function (str) {
+    var decodedStr = typeof atob !== 'undefined' ? atob(str) : Buffer.from(str, 'base64').toString('binary'); // eslint-disable-line no-undef
     var arrayBuffer = new ArrayBuffer(decodedStr.length);
     var array = new Uint8Array(arrayBuffer);
-    for (var i=0, len=decodedStr.length; i < len; i++) {
+    for (var i = 0, len = decodedStr.length; i < len; i++) {
         array[i] = decodedStr.charCodeAt(i);
     }
     return arrayBuffer;
 };
 
-//------------------------------------------------------------------------------
+// ------------------------------------------------------------------------------
 
 /* This code is based on the performance tests at http://jsperf.com/b64tests
  * This 12-bit-at-a-time algorithm was the best performing version on all
  * platforms tested.
  */
 
-var b64_6bit = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
+var b64_6bit = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
 var b64_12bit;
 
-var b64_12bitTable = function() {
+var b64_12bitTable = function () {
     b64_12bit = [];
-    for (var i=0; i<64; i++) {
-        for (var j=0; j<64; j++) {
-            b64_12bit[i*64+j] = b64_6bit[i] + b64_6bit[j];
+    for (var i = 0; i < 64; i++) {
+        for (var j = 0; j < 64; j++) {
+            b64_12bit[i * 64 + j] = b64_6bit[i] + b64_6bit[j];
         }
     }
-    b64_12bitTable = function() { return b64_12bit; };
+    b64_12bitTable = function () { return b64_12bit; };
     return b64_12bit;
 };
 
-function uint8ToBase64(rawData) {
+function uint8ToBase64 (rawData) {
     var numBytes = rawData.byteLength;
-    var output="";
+    var output = '';
     var segment;
     var table = b64_12bitTable();
-    for (var i=0;i<numBytes-2;i+=3) {
-        segment = (rawData[i] << 16) + (rawData[i+1] << 8) + rawData[i+2];
+    for (var i = 0; i < numBytes - 2; i += 3) {
+        segment = (rawData[i] << 16) + (rawData[i + 1] << 8) + rawData[i + 2];
         output += table[segment >> 12];
         output += table[segment & 0xfff];
     }
-    if (numBytes - i == 2) {
-        segment = (rawData[i] << 16) + (rawData[i+1] << 8);
+    if (numBytes - i === 2) {
+        segment = (rawData[i] << 16) + (rawData[i + 1] << 8);
         output += table[segment >> 12];
         output += b64_6bit[(segment & 0xfff) >> 6];
         output += '=';
-    } else if (numBytes - i == 1) {
+    } else if (numBytes - i === 1) {
         segment = (rawData[i] << 16);
         output += table[segment >> 12];
         output += '==';
@@ -466,7 +461,7 @@ define("cordova/builder", function(require, exports, module) {
 
 var utils = require('cordova/utils');
 
-function each(objects, func, context) {
+function each (objects, func, context) {
     for (var prop in objects) {
         if (objects.hasOwnProperty(prop)) {
             func.apply(context, [objects[prop], prop]);
@@ -474,7 +469,7 @@ function each(objects, func, context) {
     }
 }
 
-function clobber(obj, key, value) {
+function clobber (obj, key, value) {
     exports.replaceHookForTesting(obj, key);
     var needsProperty = false;
     try {
@@ -484,15 +479,15 @@ function clobber(obj, key, value) {
     }
     // Getters can only be overridden by getters.
     if (needsProperty || obj[key] !== value) {
-        utils.defineGetter(obj, key, function() {
+        utils.defineGetter(obj, key, function () {
             return value;
         });
     }
 }
 
-function assignOrWrapInDeprecateGetter(obj, key, value, message) {
+function assignOrWrapInDeprecateGetter (obj, key, value, message) {
     if (message) {
-        utils.defineGetter(obj, key, function() {
+        utils.defineGetter(obj, key, function () {
             console.log(message);
             delete obj[key];
             clobber(obj, key, value);
@@ -503,7 +498,7 @@ function assignOrWrapInDeprecateGetter(obj, key, value, message) {
     }
 }
 
-function include(parent, objects, clobber, merge) {
+function include (parent, objects, clobber, merge) {
     each(objects, function (obj, key) {
         try {
             var result = obj.path ? require(obj.path) : {};
@@ -523,7 +518,7 @@ function include(parent, objects, clobber, merge) {
                 result = parent[key];
             } else {
                 // Overwrite if not currently defined.
-                if (typeof parent[key] == 'undefined') {
+                if (typeof parent[key] === 'undefined') {
                     assignOrWrapInDeprecateGetter(parent, key, result, obj.deprecated);
                 } else {
                     // Set result to what already exists, so we can build children into it if they exist.
@@ -534,7 +529,7 @@ function include(parent, objects, clobber, merge) {
             if (obj.children) {
                 include(result, obj.children, clobber, merge);
             }
-        } catch(e) {
+        } catch (e) {
             utils.alert('Exception building Cordova JS globals: ' + e + ' for key "' + key + '"');
         }
     });
@@ -547,7 +542,7 @@ function include(parent, objects, clobber, merge) {
  * @param target Object to merge properties into.
  * @param src Object to merge properties from.
  */
-function recursiveMerge(target, src) {
+function recursiveMerge (target, src) {
     for (var prop in src) {
         if (src.hasOwnProperty(prop)) {
             if (target.prototype && target.prototype.constructor === target) {
@@ -564,26 +559,26 @@ function recursiveMerge(target, src) {
     }
 }
 
-exports.buildIntoButDoNotClobber = function(objects, target) {
+exports.buildIntoButDoNotClobber = function (objects, target) {
     include(target, objects, false, false);
 };
-exports.buildIntoAndClobber = function(objects, target) {
+exports.buildIntoAndClobber = function (objects, target) {
     include(target, objects, true, false);
 };
-exports.buildIntoAndMerge = function(objects, target) {
+exports.buildIntoAndMerge = function (objects, target) {
     include(target, objects, true, true);
 };
 exports.recursiveMerge = recursiveMerge;
 exports.assignOrWrapInDeprecateGetter = assignOrWrapInDeprecateGetter;
-exports.replaceHookForTesting = function() {};
+exports.replaceHookForTesting = function () {};
 
 });
 
 // file: src/common/channel.js
 define("cordova/channel", function(require, exports, module) {
 
-var utils = require('cordova/utils'),
-    nextGuid = 1;
+var utils = require('cordova/utils');
+var nextGuid = 1;
 
 /**
  * Custom pub-sub "channel" that can have functions subscribed to it
@@ -623,7 +618,7 @@ var utils = require('cordova/utils'),
  * @constructor
  * @param type  String the channel name
  */
-var Channel = function(type, sticky) {
+var Channel = function (type, sticky) {
     this.type = type;
     // Map of guid -> function.
     this.handlers = {};
@@ -636,69 +631,75 @@ var Channel = function(type, sticky) {
     // Function that is called when the first listener is subscribed, or when
     // the last listener is unsubscribed.
     this.onHasSubscribersChange = null;
-},
-    channel = {
-        /**
-         * Calls the provided function only after all of the channels specified
-         * have been fired. All channels must be sticky channels.
-         */
-        join: function(h, c) {
-            var len = c.length,
-                i = len,
-                f = function() {
-                    if (!(--i)) h();
-                };
-            for (var j=0; j<len; j++) {
-                if (c[j].state === 0) {
-                    throw Error('Can only use join with sticky channels.');
-                }
-                c[j].subscribe(f);
-            }
-            if (!len) h();
-        },
-        create: function(type) {
-            return channel[type] = new Channel(type, false);
-        },
-        createSticky: function(type) {
-            return channel[type] = new Channel(type, true);
-        },
-
-        /**
-         * cordova Channels that must fire before "deviceready" is fired.
-         */
-        deviceReadyChannelsArray: [],
-        deviceReadyChannelsMap: {},
-
-        /**
-         * Indicate that a feature needs to be initialized before it is ready to be used.
-         * This holds up Cordova's "deviceready" event until the feature has been initialized
-         * and Cordova.initComplete(feature) is called.
-         *
-         * @param feature {String}     The unique feature name
-         */
-        waitForInitialization: function(feature) {
-            if (feature) {
-                var c = channel[feature] || this.createSticky(feature);
-                this.deviceReadyChannelsMap[feature] = c;
-                this.deviceReadyChannelsArray.push(c);
-            }
-        },
-
-        /**
-         * Indicate that initialization code has completed and the feature is ready to be used.
-         *
-         * @param feature {String}     The unique feature name
-         */
-        initializationComplete: function(feature) {
-            var c = this.deviceReadyChannelsMap[feature];
-            if (c) {
-                c.fire();
+};
+var channel = {
+    /**
+     * Calls the provided function only after all of the channels specified
+     * have been fired. All channels must be sticky channels.
+     */
+    join: function (h, c) {
+        var len = c.length;
+        var i = len;
+        var f = function () {
+            if (!(--i)) h();
+        };
+        for (var j = 0; j < len; j++) {
+            if (c[j].state === 0) {
+                throw Error('Can only use join with sticky channels.');
             }
+            c[j].subscribe(f);
         }
-    };
+        if (!len) h();
+    },
+    /* eslint-disable no-return-assign */
+    create: function (type) {
+        return channel[type] = new Channel(type, false);
+    },
+    createSticky: function (type) {
+        return channel[type] = new Channel(type, true);
+    },
+    /* eslint-enable no-return-assign */
+    /**
+     * cordova Channels that must fire before "deviceready" is fired.
+     */
+    deviceReadyChannelsArray: [],
+    deviceReadyChannelsMap: {},
+
+    /**
+     * Indicate that a feature needs to be initialized before it is ready to be used.
+     * This holds up Cordova's "deviceready" event until the feature has been initialized
+     * and Cordova.initComplete(feature) is called.
+     *
+     * @param feature {String}     The unique feature name
+     */
+    waitForInitialization: function (feature) {
+        if (feature) {
+            var c = channel[feature] || this.createSticky(feature);
+            this.deviceReadyChannelsMap[feature] = c;
+            this.deviceReadyChannelsArray.push(c);
+        }
+    },
 
-function forceFunction(f) {
-    if (typeof f != 'function') throw "Function required as first argument!";
+    /**
+     * Indicate that initialization code has completed and the feature is ready to be used.
+     *
+     * @param feature {String}     The unique feature name
+     */
+    initializationComplete: function (feature) {
+        var c = this.deviceReadyChannelsMap[feature];
+        if (c) {
+            c.fire();
+        }
+    }
+};
+
+function checkSubscriptionArgument (argument) {
+    if (typeof argument !== 'function' && typeof argument.handleEvent !== 'function') {
+        throw new Error(
+            'Must provide a function or an EventListener object ' +
+                'implementing the handleEvent interface.'
+        );
+    }
 }
 
 /**
@@ -708,30 +709,41 @@ function forceFunction(f) {
  * and a guid that can be used to stop subscribing to the channel.
  * Returns the guid.
  */
-Channel.prototype.subscribe = function(f, c) {
-    // need a function to call
-    forceFunction(f);
-    if (this.state == 2) {
-        f.apply(c || this, this.fireArgs);
+Channel.prototype.subscribe = function (eventListenerOrFunction, eventListener) {
+    checkSubscriptionArgument(eventListenerOrFunction);
+    var handleEvent, guid;
+
+    if (eventListenerOrFunction && typeof eventListenerOrFunction === 'object') {
+        // Received an EventListener object implementing the handleEvent interface
+        handleEvent = eventListenerOrFunction.handleEvent;
+        eventListener = eventListenerOrFunction;
+    } else {
+        // Received a function to handle event
+        handleEvent = eventListenerOrFunction;
+    }
+
+    if (this.state === 2) {
+        handleEvent.apply(eventListener || this, this.fireArgs);
         return;
     }
 
-    var func = f,
-        guid = f.observer_guid;
-    if (typeof c == "object") { func = utils.close(c, f); }
+    guid = eventListenerOrFunction.observer_guid;
+    if (typeof eventListener === 'object') {
+        handleEvent = utils.close(eventListener, handleEvent);
+    }
 
     if (!guid) {
-        // first time any channel has seen this subscriber
+        // First time any channel has seen this subscriber
         guid = '' + nextGuid++;
     }
-    func.observer_guid = guid;
-    f.observer_guid = guid;
+    handleEvent.observer_guid = guid;
+    eventListenerOrFunction.observer_guid = guid;
 
     // Don't add the same handler more than once.
     if (!this.handlers[guid]) {
-        this.handlers[guid] = func;
+        this.handlers[guid] = handleEvent;
         this.numHandlers++;
-        if (this.numHandlers == 1) {
+        if (this.numHandlers === 1) {
             this.onHasSubscribersChange && this.onHasSubscribersChange();
         }
     }
@@ -740,12 +752,20 @@ Channel.prototype.subscribe = function(f, c) {
 /**
  * Unsubscribes the function with the given guid from the channel.
  */
-Channel.prototype.unsubscribe = function(f) {
-    // need a function to unsubscribe
-    forceFunction(f);
+Channel.prototype.unsubscribe = function (eventListenerOrFunction) {
+    checkSubscriptionArgument(eventListenerOrFunction);
+    var handleEvent, guid, handler;
+
+    if (eventListenerOrFunction && typeof eventListenerOrFunction === 'object') {
+        // Received an EventListener object implementing the handleEvent interface
+        handleEvent = eventListenerOrFunction.handleEvent;
+    } else {
+        // Received a function to handle event
+        handleEvent = eventListenerOrFunction;
+    }
 
-    var guid = f.observer_guid,
-        handler = this.handlers[guid];
+    guid = handleEvent.observer_guid;
+    handler = this.handlers[guid];
     if (handler) {
         delete this.handlers[guid];
         this.numHandlers--;
@@ -758,11 +778,11 @@ Channel.prototype.unsubscribe = function(f) {
 /**
  * Calls all functions subscribed to this channel.
  */
-Channel.prototype.fire = function(e) {
-    var fail = false,
-        fireArgs = Array.prototype.slice.call(arguments);
+Channel.prototype.fire = function (e) {
+    var fail = false; // eslint-disable-line no-unused-vars
+    var fireArgs = Array.prototype.slice.call(arguments);
     // Apply stickiness.
-    if (this.state == 1) {
+    if (this.state === 1) {
         this.state = 2;
         this.fireArgs = fireArgs;
     }
@@ -776,7 +796,7 @@ Channel.prototype.fire = function(e) {
         for (var i = 0; i < toCall.length; ++i) {
             toCall[i].apply(this, fireArgs);
         }
-        if (this.state == 2 && this.numHandlers) {
+        if (this.state === 2 && this.numHandlers) {
             this.numHandlers = 0;
             this.handlers = {};
             this.onHasSubscribersChange && this.onHasSubscribersChange();
@@ -784,7 +804,6 @@ Channel.prototype.fire = function(e) {
     }
 };
 
-
 // defining them here so they are ready super fast!
 // DOM event that is received when the web page is loaded and parsed.
 channel.createSticky('onDOMContentLoaded');
@@ -817,7 +836,7 @@ module.exports = channel;
 
 });
 
-// file: e:/cordova/cordova-browser/cordova-js-src/confighelper.js
+// file: /Users/steveng/repo/cordova/cordova-browser/cordova-js-src/confighelper.js
 define("cordova/confighelper", function(require, exports, module) {
 
 var config;
@@ -862,14 +881,9 @@ function readConfig(success, error) {
         }
     };
 
-    if ("ActiveXObject" in window) {
-        // Needed for XHR-ing via file:// protocol in IE
-        xhr = new window.ActiveXObject("MSXML2.XMLHTTP");
-        xhr.onreadystatechange = xhrStatusChangeHandler;
-    } else {
-        xhr = new XMLHttpRequest();
-        xhr.addEventListener("load", xhrStatusChangeHandler);
-    }
+    xhr = new XMLHttpRequest();
+    xhr.addEventListener("load", xhrStatusChangeHandler);
+
 
     try {
         xhr.open("get", "/config.xml", true);
@@ -897,7 +911,7 @@ exports.readConfig = readConfig;
 
 });
 
-// file: e:/cordova/cordova-browser/cordova-js-src/exec.js
+// file: /Users/steveng/repo/cordova/cordova-browser/cordova-js-src/exec.js
 define("cordova/exec", function(require, exports, module) {
 
 /*jslint sloppy:true, plusplus:true*/
@@ -999,31 +1013,31 @@ module.exports = function (success, fail, service, action, args) {
 // file: src/common/exec/proxy.js
 define("cordova/exec/proxy", function(require, exports, module) {
 
-
 // internal map of proxy function
 var CommandProxyMap = {};
 
 module.exports = {
 
     // example: cordova.commandProxy.add("Accelerometer",{getCurrentAcceleration: function(successCallback, errorCallback, options) {...},...);
-    add:function(id,proxyObj) {
-        console.log("adding proxy for " + id);
+    add: function (id, proxyObj) {
+        console.log('adding proxy for ' + id);
         CommandProxyMap[id] = proxyObj;
         return proxyObj;
     },
 
     // cordova.commandProxy.remove("Accelerometer");
-    remove:function(id) {
+    remove: function (id) {
         var proxy = CommandProxyMap[id];
         delete CommandProxyMap[id];
         CommandProxyMap[id] = null;
         return proxy;
     },
 
-    get:function(service,action) {
-        return ( CommandProxyMap[service] ? CommandProxyMap[service][action] : null );
+    get: function (service, action) {
+        return (CommandProxyMap[service] ? CommandProxyMap[service][action] : null);
     }
 };
+
 });
 
 // file: src/common/init.js
@@ -1038,16 +1052,16 @@ var utils = require('cordova/utils');
 
 var platformInitChannelsArray = [channel.onNativeReady, channel.onPluginsReady];
 
-function logUnfiredChannels(arr) {
+function logUnfiredChannels (arr) {
     for (var i = 0; i < arr.length; ++i) {
-        if (arr[i].state != 2) {
+        if (arr[i].state !== 2) {
             console.log('Channel not fired: ' + arr[i].type);
         }
     }
 }
 
-window.setTimeout(function() {
-    if (channel.onDeviceReady.state != 2) {
+window.setTimeout(function () {
+    if (channel.onDeviceReady.state !== 2) {
         console.log('deviceready has not fired after 5 seconds.');
         logUnfiredChannels(platformInitChannelsArray);
         logUnfiredChannels(channel.deviceReadyChannelsArray);
@@ -1056,20 +1070,19 @@ window.setTimeout(function() {
 
 // Replace navigator before any modules are required(), to ensure it happens as soon as possible.
 // We replace it so that properties that can't be clobbered can instead be overridden.
-function replaceNavigator(origNavigator) {
-    var CordovaNavigator = function() {};
+function replaceNavigator (origNavigator) {
+    var CordovaNavigator = function () {};
     CordovaNavigator.prototype = origNavigator;
     var newNavigator = new CordovaNavigator();
     // This work-around really only applies to new APIs that are newer than Function.bind.
     // Without it, APIs such as getGamepads() break.
     if (CordovaNavigator.bind) {
         for (var key in origNavigator) {
-            if (typeof origNavigator[key] == 'function') {
+            if (typeof origNavigator[key] === 'function') {
                 newNavigator[key] = origNavigator[key].bind(origNavigator);
-            }
-            else {
-                (function(k) {
-                    utils.defineGetterSetter(newNavigator,key,function() {
+            } else {
+                (function (k) {
+                    utils.defineGetterSetter(newNavigator, key, function () {
                         return origNavigator[k];
                     });
                 })(key);
@@ -1085,12 +1098,12 @@ if (window.navigator) {
 
 if (!window.console) {
     window.console = {
-        log: function(){}
+        log: function () {}
     };
 }
 if (!window.console.warn) {
-    window.console.warn = function(msg) {
-        this.log("warn: " + msg);
+    window.console.warn = function (msg) {
+        this.log('warn: ' + msg);
     };
 }
 
@@ -1101,10 +1114,10 @@ channel.onActivated = cordova.addDocumentEventHandler('activated');
 channel.onDeviceReady = cordova.addStickyDocumentEventHandler('deviceready');
 
 // Listen for DOMContentLoaded and notify our channel subscribers.
-if (document.readyState == 'complete' || document.readyState == 'interactive') {
+if (document.readyState === 'complete' || document.readyState === 'interactive') {
     channel.onDOMContentLoaded.fire();
 } else {
-    document.addEventListener('DOMContentLoaded', function() {
+    document.addEventListener('DOMContentLoaded', function () {
         channel.onDOMContentLoaded.fire();
     }, false);
 }
@@ -1125,8 +1138,8 @@ platform.bootstrap && platform.bootstrap();
 
 // Wrap in a setTimeout to support the use-case of having plugin JS appended to cordova.js.
 // The delay allows the attached modules to be defined before the plugin loader looks for them.
-setTimeout(function() {
-    pluginloader.load(function() {
+setTimeout(function () {
+    pluginloader.load(function () {
         channel.onPluginsReady.fire();
     });
 }, 0);
@@ -1134,7 +1147,7 @@ setTimeout(function() {
 /**
  * Create all cordova objects once native side is ready.
  */
-channel.join(function() {
+channel.join(function () {
     modulemapper.mapModules(window);
 
     platform.initialize && platform.initialize();
@@ -1145,13 +1158,12 @@ channel.join(function() {
     // Fire onDeviceReady event once page has fully loaded, all
     // constructors have run and cordova info has been received from native
     // side.
-    channel.join(function() {
+    channel.join(function () {
         require('cordova').fireDocumentEvent('deviceready');
     }, channel.deviceReadyChannelsArray);
 
 }, platformInitChannelsArray);
 
-
 });
 
 // file: src/common/init_b.js
@@ -1169,16 +1181,16 @@ var platformInitChannelsArray = [channel.onDOMContentLoaded, channel.onNativeRea
 // setting exec
 cordova.exec = require('cordova/exec');
 
-function logUnfiredChannels(arr) {
+function logUnfiredChannels (arr) {
     for (var i = 0; i < arr.length; ++i) {
-        if (arr[i].state != 2) {
+        if (arr[i].state !== 2) {
             console.log('Channel not fired: ' + arr[i].type);
         }
     }
 }
 
-window.setTimeout(function() {
-    if (channel.onDeviceReady.state != 2) {
+window.setTimeout(function () {
+    if (channel.onDeviceReady.state !== 2) {
         console.log('deviceready has not fired after 5 seconds.');
         logUnfiredChannels(platformInitChannelsArray);
         logUnfiredChannels(channel.deviceReadyChannelsArray);
@@ -1187,20 +1199,19 @@ window.setTimeout(function() {
 
 // Replace navigator before any modules are required(), to ensure it happens as soon as possible.
 // We replace it so that properties that can't be clobbered can instead be overridden.
-function replaceNavigator(origNavigator) {
-    var CordovaNavigator = function() {};
+function replaceNavigator (origNavigator) {
+    var CordovaNavigator = function () {};
     CordovaNavigator.prototype = origNavigator;
     var newNavigator = new CordovaNavigator();
     // This work-around really only applies to new APIs that are newer than Function.bind.
     // Without it, APIs such as getGamepads() break.
     if (CordovaNavigator.bind) {
         for (var key in origNavigator) {
-            if (typeof origNavigator[key] == 'function') {
+            if (typeof origNavigator[key] === 'function') {
                 newNavigator[key] = origNavigator[key].bind(origNavigator);
-            }
-            else {
-                (function(k) {
-                    utils.defineGetterSetter(newNavigator,key,function() {
+            } else {
+                (function (k) {
+                    utils.defineGetterSetter(newNavigator, key, function () {
                         return origNavigator[k];
                     });
                 })(key);
@@ -1215,12 +1226,12 @@ if (window.navigator) {
 
 if (!window.console) {
     window.console = {
-        log: function(){}
+        log: function () {}
     };
 }
 if (!window.console.warn) {
-    window.console.warn = function(msg) {
-        this.log("warn: " + msg);
+    window.console.warn = function (msg) {
+        this.log('warn: ' + msg);
     };
 }
 
@@ -1231,10 +1242,10 @@ channel.onActivated = cordova.addDocumentEventHandler('activated');
 channel.onDeviceReady = cordova.addStickyDocumentEventHandler('deviceready');
 
 // Listen for DOMContentLoaded and notify our channel subscribers.
-if (document.readyState == 'complete' || document.readyState == 'interactive') {
+if (document.readyState === 'complete' || document.readyState === 'interactive') {
     channel.onDOMContentLoaded.fire();
 } else {
-    document.addEventListener('DOMContentLoaded', function() {
+    document.addEventListener('DOMContentLoaded', function () {
         channel.onDOMContentLoaded.fire();
     }, false);
 }
@@ -1251,8 +1262,8 @@ platform.bootstrap && platform.bootstrap();
 
 // Wrap in a setTimeout to support the use-case of having plugin JS appended to cordova.js.
 // The delay allows the attached modules to be defined before the plugin loader looks for them.
-setTimeout(function() {
-    pluginloader.load(function() {
+setTimeout(function () {
+    pluginloader.load(function () {
         channel.onPluginsReady.fire();
     });
 }, 0);
@@ -1260,7 +1271,7 @@ setTimeout(function() {
 /**
  * Create all cordova objects once native side is ready.
  */
-channel.join(function() {
+channel.join(function () {
     modulemapper.mapModules(window);
 
     platform.initialize && platform.initialize();
@@ -1271,7 +1282,7 @@ channel.join(function() {
     // Fire onDeviceReady event once page has fully loaded, all
     // constructors have run and cordova info has been received from native
     // side.
-    channel.join(function() {
+    channel.join(function () {
         require('cordova').fireDocumentEvent('deviceready');
     }, channel.deviceReadyChannelsArray);
 
@@ -1282,17 +1293,17 @@ channel.join(function() {
 // file: src/common/modulemapper.js
 define("cordova/modulemapper", function(require, exports, module) {
 
-var builder = require('cordova/builder'),
-    moduleMap = define.moduleMap,
-    symbolList,
-    deprecationMap;
+var builder = require('cordova/builder');
+var moduleMap = define.moduleMap; // eslint-disable-line no-undef
+var symbolList;
+var deprecationMap;
 
-exports.reset = function() {
+exports.reset = function () {
     symbolList = [];
     deprecationMap = {};
 };
 
-function addEntry(strategy, moduleName, symbolPath, opt_deprecationMessage) {
+function addEntry (strategy, moduleName, symbolPath, opt_deprecationMessage) {
     if (!(moduleName in moduleMap)) {
         throw new Error('Module ' + moduleName + ' does not exist.');
     }
@@ -1303,35 +1314,35 @@ function addEntry(strategy, moduleName, symbolPath, opt_deprecationMessage) {
 }
 
 // Note: Android 2.3 does have Function.bind().
-exports.clobbers = function(moduleName, symbolPath, opt_deprecationMessage) {
+exports.clobbers = function (moduleName, symbolPath, opt_deprecationMessage) {
     addEntry('c', moduleName, symbolPath, opt_deprecationMessage);
 };
 
-exports.merges = function(moduleName, symbolPath, opt_deprecationMessage) {
+exports.merges = function (moduleName, symbolPath, opt_deprecationMessage) {
     addEntry('m', moduleName, symbolPath, opt_deprecationMessage);
 };
 
-exports.defaults = function(moduleName, symbolPath, opt_deprecationMessage) {
+exports.defaults = function (moduleName, symbolPath, opt_deprecationMessage) {
     addEntry('d', moduleName, symbolPath, opt_deprecationMessage);
 };
 
-exports.runs = function(moduleName) {
+exports.runs = function (moduleName) {
     addEntry('r', moduleName, null);
 };
 
-function prepareNamespace(symbolPath, context) {
+function prepareNamespace (symbolPath, context) {
     if (!symbolPath) {
         return context;
     }
     var parts = symbolPath.split('.');
     var cur = context;
-    for (var i = 0, part; part = parts[i]; ++i) {
+    for (var i = 0, part; part = parts[i]; ++i) { // eslint-disable-line no-cond-assign
         cur = cur[part] = cur[part] || {};
     }
     return cur;
 }
 
-exports.mapModules = function(context) {
+exports.mapModules = function (context) {
     var origSymbols = {};
     context.CDV_origSymbols = origSymbols;
     for (var i = 0, len = symbolList.length; i < len; i += 3) {
@@ -1339,7 +1350,7 @@ exports.mapModules = function(context) {
         var moduleName = symbolList[i + 1];
         var module = require(moduleName);
         // <runs/>
-        if (strategy == 'r') {
+        if (strategy === 'r') {
             continue;
         }
         var symbolPath = symbolList[i + 2];
@@ -1351,9 +1362,9 @@ exports.mapModules = function(context) {
         var parentObj = prepareNamespace(namespace, context);
         var target = parentObj[lastName];
 
-        if (strategy == 'm' && target) {
+        if (strategy === 'm' && target) {
             builder.recursiveMerge(target, module);
-        } else if ((strategy == 'd' && !target) || (strategy != 'd')) {
+        } else if ((strategy === 'd' && !target) || (strategy !== 'd')) {
             if (!(symbolPath in origSymbols)) {
                 origSymbols[symbolPath] = target;
             }
@@ -1362,7 +1373,7 @@ exports.mapModules = function(context) {
     }
 };
 
-exports.getOriginalSymbol = function(context, symbolPath) {
+exports.getOriginalSymbol = function (context, symbolPath) {
     var origSymbols = context.CDV_origSymbols;
     if (origSymbols && (symbolPath in origSymbols)) {
         return origSymbols[symbolPath];
@@ -1377,22 +1388,21 @@ exports.getOriginalSymbol = function(context, symbolPath) {
 
 exports.reset();
 
-
 });
 
 // file: src/common/modulemapper_b.js
 define("cordova/modulemapper_b", function(require, exports, module) {
 
-var builder = require('cordova/builder'),
-    symbolList = [],
-    deprecationMap;
+var builder = require('cordova/builder');
+var symbolList = [];
+var deprecationMap;
 
-exports.reset = function() {
+exports.reset = function () {
     symbolList = [];
     deprecationMap = {};
 };
 
-function addEntry(strategy, moduleName, symbolPath, opt_deprecationMessage) {
+function addEntry (strategy, moduleName, symbolPath, opt_deprecationMessage) {
     symbolList.push(strategy, moduleName, symbolPath);
     if (opt_deprecationMessage) {
         deprecationMap[symbolPath] = opt_deprecationMessage;
@@ -1400,35 +1410,35 @@ function addEntry(strategy, moduleName, symbolPath, opt_deprecationMessage) {
 }
 
 // Note: Android 2.3 does have Function.bind().
-exports.clobbers = function(moduleName, symbolPath, opt_deprecationMessage) {
+exports.clobbers = function (moduleName, symbolPath, opt_deprecationMessage) {
     addEntry('c', moduleName, symbolPath, opt_deprecationMessage);
 };
 
-exports.merges = function(moduleName, symbolPath, opt_deprecationMessage) {
+exports.merges = function (moduleName, symbolPath, opt_deprecationMessage) {
     addEntry('m', moduleName, symbolPath, opt_deprecationMessage);
 };
 
-exports.defaults = function(moduleName, symbolPath, opt_deprecationMessage) {
+exports.defaults = function (moduleName, symbolPath, opt_deprecationMessage) {
     addEntry('d', moduleName, symbolPath, opt_deprecationMessage);
 };
 
-exports.runs = function(moduleName) {
+exports.runs = function (moduleName) {
     addEntry('r', moduleName, null);
 };
 
-function prepareNamespace(symbolPath, context) {
+function prepareNamespace (symbolPath, context) {
     if (!symbolPath) {
         return context;
     }
     var parts = symbolPath.split('.');
     var cur = context;
-    for (var i = 0, part; part = parts[i]; ++i) {
+    for (var i = 0, part; part = parts[i]; ++i) { // eslint-disable-line no-cond-assign
         cur = cur[part] = cur[part] || {};
     }
     return cur;
 }
 
-exports.mapModules = function(context) {
+exports.mapModules = function (context) {
     var origSymbols = {};
     context.CDV_origSymbols = origSymbols;
     for (var i = 0, len = symbolList.length; i < len; i += 3) {
@@ -1436,7 +1446,7 @@ exports.mapModules = function(context) {
         var moduleName = symbolList[i + 1];
         var module = require(moduleName);
         // <runs/>
-        if (strategy == 'r') {
+        if (strategy === 'r') {
             continue;
         }
         var symbolPath = symbolList[i + 2];
@@ -1448,9 +1458,9 @@ exports.mapModules = function(context) {
         var parentObj = prepareNamespace(namespace, context);
         var target = parentObj[lastName];
 
-        if (strategy == 'm' && target) {
+        if (strategy === 'm' && target) {
             builder.recursiveMerge(target, module);
-        } else if ((strategy == 'd' && !target) || (strategy != 'd')) {
+        } else if ((strategy === 'd' && !target) || (strategy !== 'd')) {
             if (!(symbolPath in origSymbols)) {
                 origSymbols[symbolPath] = target;
             }
@@ -1459,7 +1469,7 @@ exports.mapModules = function(context) {
     }
 };
 
-exports.getOriginalSymbol = function(context, symbolPath) {
+exports.getOriginalSymbol = function (context, symbolPath) {
     var origSymbols = context.CDV_origSymbols;
     if (origSymbols && (symbolPath in origSymbols)) {
         return origSymbols[symbolPath];
@@ -1474,15 +1484,14 @@ exports.getOriginalSymbol = function(context, symbolPath) {
 
 exports.reset();
 
-
 });
 
-// file: e:/cordova/cordova-browser/cordova-js-src/platform.js
+// file: /Users/steveng/repo/cordova/cordova-browser/cordova-js-src/platform.js
 define("cordova/platform", function(require, exports, module) {
 
 module.exports = {
     id: 'browser',
-    cordovaVersion: '3.4.0',
+    cordovaVersion: '4.2.0', // cordova-js
 
     bootstrap: function() {
 
@@ -1493,16 +1502,14 @@ module.exports = {
 
         channel.onNativeReady.fire();
 
-        // FIXME is this the right place to clobber pause/resume? I am guessing not
-        // FIXME pause/resume should be deprecated IN CORDOVA for pagevisiblity api
-        document.addEventListener('webkitvisibilitychange', function() {
-            if (document.webkitHidden) {
+        document.addEventListener("visibilitychange", function(){
+            if(document.hidden) {
                 channel.onPause.fire();
             }
             else {
                 channel.onResume.fire();
             }
-        }, false);
+        });
 
     // End of bootstrap
     }
@@ -1514,12 +1521,11 @@ module.exports = {
 define("cordova/pluginloader", function(require, exports, module) {
 
 var modulemapper = require('cordova/modulemapper');
-var urlutil = require('cordova/urlutil');
 
 // Helper function to inject a <script> tag.
 // Exported for testing.
-exports.injectScript = function(url, onload, onerror) {
-    var script = document.createElement("script");
+exports.injectScript = function (url, onload, onerror) {
+    var script = document.createElement('script');
     // onload fires even when script fails loads with an error.
     script.onload = onload;
     // onerror fires for malformed URLs.
@@ -1528,13 +1534,13 @@ exports.injectScript = function(url, onload, onerror) {
     document.head.appendChild(script);
 };
 
-function injectIfNecessary(id, url, onload, onerror) {
+function injectIfNecessary (id, url, onload, onerror) {
     onerror = onerror || onload;
-    if (id in define.moduleMap) {
+    if (id in define.moduleMap) { // eslint-disable-line no-undef
         onload();
     } else {
-        exports.injectScript(url, function() {
-            if (id in define.moduleMap) {
+        exports.injectScript(url, function () {
+            if (id in define.moduleMap) { // eslint-disable-line no-undef
                 onload();
             } else {
                 onerror();
@@ -1543,9 +1549,9 @@ function injectIfNecessary(id, url, onload, onerror) {
     }
 }
 
-function onScriptLoadingComplete(moduleList, finishPluginLoading) {
+function onScriptLoadingComplete (moduleList, finishPluginLoading) {
     // Loop through all the plugins and then through their clobbers and merges.
-    for (var i = 0, module; module = moduleList[i]; i++) {
+    for (var i = 0, module; module = moduleList[i]; i++) { // eslint-disable-line no-cond-assign
         if (module.clobbers && module.clobbers.length) {
             for (var j = 0; j < module.clobbers.length; j++) {
                 modulemapper.clobbers(module.id, module.clobbers[j]);
@@ -1571,7 +1577,7 @@ function onScriptLoadingComplete(moduleList, finishPluginLoading) {
 // See plugman's plugin_loader.js for the details of this object.
 // This function is only called if the really is a plugins array that isn't empty.
 // Otherwise the onerror response handler will just call finishPluginLoading().
-function handlePluginsObject(path, moduleList, finishPluginLoading) {
+function handlePluginsObject (path, moduleList, finishPluginLoading) {
     // Now inject the scripts.
     var scriptCounter = moduleList.length;
 
@@ -1579,7 +1585,7 @@ function handlePluginsObject(path, moduleList, finishPluginLoading) {
         finishPluginLoading();
         return;
     }
-    function scriptLoadedCallback() {
+    function scriptLoadedCallback () {
         if (!--scriptCounter) {
             onScriptLoadingComplete(moduleList, finishPluginLoading);
         }
@@ -1590,13 +1596,13 @@ function handlePluginsObject(path, moduleList, finishPluginLoading) {
     }
 }
 
-function findCordovaPath() {
+function findCordovaPath () {
     var path = null;
     var scripts = document.getElementsByTagName('script');
     var term = '/cordova.js';
-    for (var n = scripts.length-1; n>-1; n--) {
+    for (var n = scripts.length - 1; n > -1; n--) {
         var src = scripts[n].src.replace(/\?.*$/, ''); // Strip any query param (CB-6007).
-        if (src.indexOf(term) == (src.length - term.length)) {
+        if (src.indexOf(term) === (src.length - term.length)) {
             path = src.substring(0, src.length - term.length) + '/';
             break;
         }
@@ -1607,19 +1613,18 @@ function findCordovaPath() {
 // Tries to load all plugins' js-modules.
 // This is an async process, but onDeviceReady is blocked on onPluginsReady.
 // onPluginsReady is fired when there are no plugins to load, or they are all done.
-exports.load = function(callback) {
+exports.load = function (callback) {
     var pathPrefix = findCordovaPath();
     if (pathPrefix === null) {
         console.log('Could not find cordova.js script tag. Plugin loading may fail.');
         pathPrefix = '';
     }
-    injectIfNecessary('cordova/plugin_list', pathPrefix + 'cordova_plugins.js', function() {
-        var moduleList = require("cordova/plugin_list");
+    injectIfNecessary('cordova/plugin_list', pathPrefix + 'cordova_plugins.js', function () {
+        var moduleList = require('cordova/plugin_list');
         handlePluginsObject(pathPrefix, moduleList, callback);
     }, callback);
 };
 
-
 });
 
 // file: src/common/pluginloader_b.js
@@ -1629,14 +1634,14 @@ var modulemapper = require('cordova/modulemapper');
 
 // Handler for the cordova_plugins.js content.
 // See plugman's plugin_loader.js for the details of this object.
-function handlePluginsObject(moduleList) {
+function handlePluginsObject (moduleList) {
     // if moduleList is not defined or empty, we've nothing to do
     if (!moduleList || !moduleList.length) {
         return;
     }
 
     // Loop through all the modules and then through their clobbers and merges.
-    for (var i = 0, module; module = moduleList[i]; i++) {
+    for (var i = 0, module; module = moduleList[i]; i++) { // eslint-disable-line no-cond-assign
         if (module.clobbers && module.clobbers.length) {
             for (var j = 0; j < module.clobbers.length; j++) {
                 modulemapper.clobbers(module.id, module.clobbers[j]);
@@ -1660,31 +1665,28 @@ function handlePluginsObject(moduleList) {
 // but the method accepts callback to be compatible with non-browserify flow.
 // onDeviceReady is blocked on onPluginsReady. onPluginsReady is fired when there are
 // no plugins to load, or they are all done.
-exports.load = function(callback) {
-    var moduleList = require("cordova/plugin_list");
+exports.load = function (callback) {
+    var moduleList = require('cordova/plugin_list');
     handlePluginsObject(moduleList);
 
     callback();
 };
 
-
 });
 
 // file: src/common/urlutil.js
 define("cordova/urlutil", function(require, exports, module) {
 
-
 /**
  * For already absolute URLs, returns what is passed in.
  * For relative URLs, converts them to absolute ones.
  */
-exports.makeAbsolute = function makeAbsolute(url) {
+exports.makeAbsolute = function makeAbsolute (url) {
     var anchorEl = document.createElement('a');
     anchorEl.href = url;
     return anchorEl.href;
 };
 
-
 });
 
 // file: src/common/utils.js
@@ -1695,7 +1697,7 @@ var utils = exports;
 /**
  * Defines a property getter / setter for obj[key].
  */
-utils.defineGetterSetter = function(obj, key, getFunc, opt_setFunc) {
+utils.defineGetterSetter = function (obj, key, getFunc, opt_setFunc) {
     if (Object.defineProperty) {
         var desc = {
             get: getFunc,
@@ -1718,13 +1720,13 @@ utils.defineGetterSetter = function(obj, key, getFunc, opt_setFunc) {
  */
 utils.defineGetter = utils.defineGetterSetter;
 
-utils.arrayIndexOf = function(a, item) {
+utils.arrayIndexOf = function (a, item) {
     if (a.indexOf) {
         return a.indexOf(item);
     }
     var len = a.length;
     for (var i = 0; i < len; ++i) {
-        if (a[i] == item) {
+        if (a[i] === item) {
             return i;
         }
     }
@@ -1734,15 +1736,15 @@ utils.arrayIndexOf = function(a, item) {
 /**
  * Returns whether the item was found in the array.
  */
-utils.arrayRemove = function(a, item) {
+utils.arrayRemove = function (a, item) {
     var index = utils.arrayIndexOf(a, item);
-    if (index != -1) {
+    if (index !== -1) {
         a.splice(index, 1);
     }
-    return index != -1;
+    return index !== -1;
 };
 
-utils.typeName = function(val) {
+utils.typeName = function (val) {
     return Object.prototype.toString.call(val).slice(8, -1);
 };
 
@@ -1750,36 +1752,39 @@ utils.typeName = function(val) {
  * Returns an indication of whether the argument is an array or not
  */
 utils.isArray = Array.isArray ||
-                function(a) {return utils.typeName(a) == 'Array';};
+                function (a) { return utils.typeName(a) === 'Array'; };
 
 /**
  * Returns an indication of whether the argument is a Date or not
  */
-utils.isDate = function(d) {
+utils.isDate = function (d) {
     return (d instanceof Date);
 };
 
 /**
  * Does a deep clone of the object.
  */
-utils.clone = function(obj) {
-    if(!obj || typeof obj == 'function' || utils.isDate(obj) || typeof obj != 'object') {
+utils.clone = function (obj) {
+    if (!obj || typeof obj === 'function' || utils.isDate(obj) || typeof obj !== 'object') {
         return obj;
     }
 
     var retVal, i;
 
-    if(utils.isArray(obj)){
+    if (utils.isArray(obj)) {
         retVal = [];
-        for(i = 0; i < obj.length; ++i){
+        for (i = 0; i < obj.length; ++i) {
             retVal.push(utils.clone(obj[i]));
         }
         return retVal;
     }
 
     retVal = {};
-    for(i in obj){
-        if(!(i in retVal) || retVal[i] != obj[i]) {
+    for (i in obj) {
+        // https://issues.apache.org/jira/browse/CB-11522 'unknown' type may be returned in
+        // custom protocol activation case on Windows Phone 8.1 causing "No such interface supported" exception
+        // on cloning.
+        if ((!(i in retVal) || retVal[i] !== obj[i]) && typeof obj[i] !== 'undefined' && typeof obj[i] !== 'unknown') { // eslint-disable-line valid-typeof
             retVal[i] = utils.clone(obj[i]);
         }
     }
@@ -1789,20 +1794,20 @@ utils.clone = function(obj) {
 /**
  * Returns a wrapped version of the function
  */
-utils.close = function(context, func, params) {
-    return function() {
+utils.close = function (context, func, params) {
+    return function () {
         var args = params || arguments;
         return func.apply(context, args);
     };
 };
 
-//------------------------------------------------------------------------------
-function UUIDcreatePart(length) {
-    var uuidpart = "";
-    for (var i=0; i<length; i++) {
+// ------------------------------------------------------------------------------
+function UUIDcreatePart (length) {
+    var uuidpart = '';
+    for (var i = 0; i < length; i++) {
         var uuidchar = parseInt((Math.random() * 256), 10).toString(16);
-        if (uuidchar.length == 1) {
-            uuidchar = "0" + uuidchar;
+        if (uuidchar.length === 1) {
+            uuidchar = '0' + uuidchar;
         }
         uuidpart += uuidchar;
     }
@@ -1812,7 +1817,7 @@ function UUIDcreatePart(length) {
 /**
  * Create a UUID
  */
-utils.createUUID = function() {
+utils.createUUID = function () {
     return UUIDcreatePart(4) + '-' +
         UUIDcreatePart(2) + '-' +
         UUIDcreatePart(2) + '-' +
@@ -1820,16 +1825,15 @@ utils.createUUID = function() {
         UUIDcreatePart(6);
 };
 
-
 /**
  * Extends a child object from a parent object using classical inheritance
  * pattern.
  */
-utils.extend = (function() {
+utils.extend = (function () {
     // proxy used to establish prototype chain
-    var F = function() {};
+    var F = function () {};
     // extend Child from Parent
-    return function(Child, Parent) {
+    return function (Child, Parent) {
 
         F.prototype = Parent.prototype;
         Child.prototype = new F();
@@ -1841,7 +1845,7 @@ utils.extend = (function() {
 /**
  * Alerts a message in any available way: alert or console.log.
  */
-utils.alert = function(msg) {
+utils.alert = function (msg) {
     if (window.alert) {
         window.alert(msg);
     } else if (console && console.log) {
@@ -1849,10 +1853,6 @@ utils.alert = function(msg) {
     }
 };
 
-
-
-
-
 });
 
 window.cordova = require('cordova');
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/LICENSE b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/LICENSE
index 19129e3..9bcfa9d 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/LICENSE
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/LICENSE
@@ -1,3 +1,8 @@
+This software is dual-licensed under the ISC and MIT licenses.
+You may use this software under EITHER of the following licenses.
+
+----------
+
 The ISC License
 
 Copyright (c) Isaac Z. Schlueter and Contributors
@@ -13,3 +18,29 @@ ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
 WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
 ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
 IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+
+----------
+
+Copyright Isaac Z. Schlueter and Contributors
+All rights reserved.
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/abbrev.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/abbrev.js
index 69cfeac..7b1dc5d 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/abbrev.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/abbrev.js
@@ -1,4 +1,3 @@
-
 module.exports = exports = abbrev.abbrev = abbrev
 
 abbrev.monkeyPatch = monkeyPatch
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/package.json
index 7a066cc..886ab39 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/abbrev/package.json
@@ -1,50 +1,27 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "abbrev@1",
-        "scope": null,
-        "escapedName": "abbrev",
-        "name": "abbrev",
-        "rawSpec": "1",
-        "spec": ">=1.0.0 <2.0.0",
-        "type": "range"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/nopt"
-    ]
-  ],
-  "_from": "abbrev@>=1.0.0 <2.0.0",
-  "_id": "abbrev@1.0.9",
-  "_inCache": true,
+  "_from": "abbrev@1",
+  "_id": "abbrev@1.1.1",
+  "_inBundle": false,
+  "_integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==",
   "_location": "/abbrev",
-  "_nodeVersion": "4.4.4",
-  "_npmOperationalInternal": {
-    "host": "packages-16-east.internal.npmjs.com",
-    "tmp": "tmp/abbrev-1.0.9.tgz_1466016055839_0.7825860097073019"
-  },
-  "_npmUser": {
-    "name": "isaacs",
-    "email": "i@izs.me"
-  },
-  "_npmVersion": "3.9.1",
   "_phantomChildren": {},
   "_requested": {
+    "type": "range",
+    "registry": true,
     "raw": "abbrev@1",
-    "scope": null,
-    "escapedName": "abbrev",
     "name": "abbrev",
+    "escapedName": "abbrev",
     "rawSpec": "1",
-    "spec": ">=1.0.0 <2.0.0",
-    "type": "range"
+    "saveSpec": null,
+    "fetchSpec": "1"
   },
   "_requiredBy": [
     "/nopt"
   ],
-  "_resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz",
-  "_shasum": "91b4792588a7738c25f35dd6f63752a2f8776135",
-  "_shrinkwrap": null,
+  "_resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz",
+  "_shasum": "f8f2c887ad10bf67f634f005b6987fed3179aac8",
   "_spec": "abbrev@1",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/nopt",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/nopt",
   "author": {
     "name": "Isaac Z. Schlueter",
     "email": "i@izs.me"
@@ -52,38 +29,28 @@
   "bugs": {
     "url": "https://github.com/isaacs/abbrev-js/issues"
   },
-  "dependencies": {},
+  "bundleDependencies": false,
+  "deprecated": false,
   "description": "Like ruby's abbrev module, but in js",
   "devDependencies": {
-    "tap": "^5.7.2"
-  },
-  "directories": {},
-  "dist": {
-    "shasum": "91b4792588a7738c25f35dd6f63752a2f8776135",
-    "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz"
+    "tap": "^10.1"
   },
   "files": [
     "abbrev.js"
   ],
-  "gitHead": "c386cd9dbb1d8d7581718c54d4ba944cc9298d6f",
   "homepage": "https://github.com/isaacs/abbrev-js#readme",
   "license": "ISC",
   "main": "abbrev.js",
-  "maintainers": [
-    {
-      "name": "isaacs",
-      "email": "i@izs.me"
-    }
-  ],
   "name": "abbrev",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+ssh://git@github.com/isaacs/abbrev-js.git"
   },
   "scripts": {
-    "test": "tap test.js --cov"
+    "postpublish": "git push origin --all; git push origin --tags",
+    "postversion": "npm publish",
+    "preversion": "npm test",
+    "test": "tap test.js --100"
   },
-  "version": "1.0.9"
+  "version": "1.1.1"
 }
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/HISTORY.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/HISTORY.md
index 0477ed7..aaf5281 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/HISTORY.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/HISTORY.md
@@ -1,3 +1,9 @@
+1.3.4 / 2017-08-22
+==================
+
+  * deps: mime-types@~2.1.16
+    - deps: mime-db@~1.29.0
+
 1.3.3 / 2016-05-02
 ==================
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/README.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/README.md
index ae36676..6a2749a 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/README.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/README.md
@@ -6,23 +6,31 @@
 [![Build Status][travis-image]][travis-url]
 [![Test Coverage][coveralls-image]][coveralls-url]
 
-Higher level content negotiation based on [negotiator](https://www.npmjs.com/package/negotiator). Extracted from [koa](https://www.npmjs.com/package/koa) for general use.
+Higher level content negotiation based on [negotiator](https://www.npmjs.com/package/negotiator).
+Extracted from [koa](https://www.npmjs.com/package/koa) for general use.
 
 In addition to negotiator, it allows:
 
-- Allows types as an array or arguments list, ie `(['text/html', 'application/json'])` as well as `('text/html', 'application/json')`.
+- Allows types as an array or arguments list, ie `(['text/html', 'application/json'])`
+  as well as `('text/html', 'application/json')`.
 - Allows type shorthands such as `json`.
 - Returns `false` when no types match
 - Treats non-existent headers as `*`
 
 ## Installation
 
+This is a [Node.js](https://nodejs.org/en/) module available through the
+[npm registry](https://www.npmjs.com/). Installation is done using the
+[`npm install` command](https://docs.npmjs.com/getting-started/installing-npm-packages-locally):
+
 ```sh
-npm install accepts
+$ npm install accepts
 ```
 
 ## API
 
+<!-- eslint-disable no-unused-vars -->
+
 ```js
 var accepts = require('accepts')
 ```
@@ -88,11 +96,11 @@ server.
 var accepts = require('accepts')
 var http = require('http')
 
-function app(req, res) {
+function app (req, res) {
   var accept = accepts(req)
 
   // the order of this list is significant; should be server preferred order
-  switch(accept.type(['json', 'html'])) {
+  switch (accept.type(['json', 'html'])) {
     case 'json':
       res.setHeader('Content-Type', 'application/json')
       res.write('{"hello":"world!"}')
@@ -126,7 +134,7 @@ curl -I -H'Accept: text/html' http://localhost:3000/
 [npm-image]: https://img.shields.io/npm/v/accepts.svg
 [npm-url]: https://npmjs.org/package/accepts
 [node-version-image]: https://img.shields.io/node/v/accepts.svg
-[node-version-url]: http://nodejs.org/download/
+[node-version-url]: https://nodejs.org/en/download/
 [travis-image]: https://img.shields.io/travis/jshttp/accepts/master.svg
 [travis-url]: https://travis-ci.org/jshttp/accepts
 [coveralls-image]: https://img.shields.io/coveralls/jshttp/accepts/master.svg
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/index.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/index.js
index e80192a..e9b2f63 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/index.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/index.js
@@ -29,9 +29,10 @@ module.exports = Accepts
  * @public
  */
 
-function Accepts(req) {
-  if (!(this instanceof Accepts))
+function Accepts (req) {
+  if (!(this instanceof Accepts)) {
     return new Accepts(req)
+  }
 
   this.headers = req.headers
   this.negotiator = new Negotiator(req)
@@ -95,12 +96,18 @@ Accepts.prototype.types = function (types_) {
     return this.negotiator.mediaTypes()
   }
 
-  if (!this.headers.accept) return types[0];
-  var mimes = types.map(extToMime);
-  var accepts = this.negotiator.mediaTypes(mimes.filter(validMime));
-  var first = accepts[0];
-  if (!first) return false;
-  return types[mimes.indexOf(first)];
+  // no accept header, return first given type
+  if (!this.headers.accept) {
+    return types[0]
+  }
+
+  var mimes = types.map(extToMime)
+  var accepts = this.negotiator.mediaTypes(mimes.filter(validMime))
+  var first = accepts[0]
+
+  return first
+    ? types[mimes.indexOf(first)]
+    : false
 }
 
 /**
@@ -212,7 +219,7 @@ Accepts.prototype.languages = function (languages_) {
  * @private
  */
 
-function extToMime(type) {
+function extToMime (type) {
   return type.indexOf('/') === -1
     ? mime.lookup(type)
     : type
@@ -226,6 +233,6 @@ function extToMime(type) {
  * @private
  */
 
-function validMime(type) {
-  return typeof type === 'string';
+function validMime (type) {
+  return typeof type === 'string'
 }
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/package.json
index 1d3c106..98f4793 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/accepts/package.json
@@ -1,54 +1,32 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "accepts@~1.3.3",
-        "scope": null,
-        "escapedName": "accepts",
-        "name": "accepts",
-        "rawSpec": "~1.3.3",
-        "spec": ">=1.3.3 <1.4.0",
-        "type": "range"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/compression"
-    ]
-  ],
-  "_from": "accepts@>=1.3.3 <1.4.0",
-  "_id": "accepts@1.3.3",
-  "_inCache": true,
+  "_from": "accepts@~1.3.4",
+  "_id": "accepts@1.3.4",
+  "_inBundle": false,
+  "_integrity": "sha1-hiRnWMfdbSGmR0/whKR0DsBesh8=",
   "_location": "/accepts",
-  "_nodeVersion": "4.4.3",
-  "_npmOperationalInternal": {
-    "host": "packages-16-east.internal.npmjs.com",
-    "tmp": "tmp/accepts-1.3.3.tgz_1462251932032_0.7092335098423064"
-  },
-  "_npmUser": {
-    "name": "dougwilson",
-    "email": "doug@somethingdoug.com"
-  },
-  "_npmVersion": "2.15.1",
   "_phantomChildren": {},
   "_requested": {
-    "raw": "accepts@~1.3.3",
-    "scope": null,
-    "escapedName": "accepts",
+    "type": "range",
+    "registry": true,
+    "raw": "accepts@~1.3.4",
     "name": "accepts",
-    "rawSpec": "~1.3.3",
-    "spec": ">=1.3.3 <1.4.0",
-    "type": "range"
+    "escapedName": "accepts",
+    "rawSpec": "~1.3.4",
+    "saveSpec": null,
+    "fetchSpec": "~1.3.4"
   },
   "_requiredBy": [
     "/compression",
     "/express"
   ],
-  "_resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.3.tgz",
-  "_shasum": "c3ca7434938648c3e0d9c1e328dd68b622c284ca",
-  "_shrinkwrap": null,
-  "_spec": "accepts@~1.3.3",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/compression",
+  "_resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.4.tgz",
+  "_shasum": "86246758c7dd6d21a6474ff084a4740ec05eb21f",
+  "_spec": "accepts@~1.3.4",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/compression",
   "bugs": {
     "url": "https://github.com/jshttp/accepts/issues"
   },
+  "bundleDependencies": false,
   "contributors": [
     {
       "name": "Douglas Christopher Wilson",
@@ -61,19 +39,22 @@
     }
   ],
   "dependencies": {
-    "mime-types": "~2.1.11",
+    "mime-types": "~2.1.16",
     "negotiator": "0.6.1"
   },
+  "deprecated": false,
   "description": "Higher-level content negotiation",
   "devDependencies": {
-    "istanbul": "0.4.3",
+    "eslint": "3.19.0",
+    "eslint-config-standard": "10.2.1",
+    "eslint-plugin-import": "2.7.0",
+    "eslint-plugin-markdown": "1.0.0-beta.6",
+    "eslint-plugin-node": "5.1.1",
+    "eslint-plugin-promise": "3.5.0",
+    "eslint-plugin-standard": "3.0.1",
+    "istanbul": "0.4.5",
     "mocha": "~1.21.5"
   },
-  "directories": {},
-  "dist": {
-    "shasum": "c3ca7434938648c3e0d9c1e328dd68b622c284ca",
-    "tarball": "https://registry.npmjs.org/accepts/-/accepts-1.3.3.tgz"
-  },
   "engines": {
     "node": ">= 0.6"
   },
@@ -82,7 +63,6 @@
     "HISTORY.md",
     "index.js"
   ],
-  "gitHead": "3e925b1e65ed7da2798849683d49814680dfa426",
   "homepage": "https://github.com/jshttp/accepts#readme",
   "keywords": [
     "content",
@@ -91,23 +71,16 @@
     "accepts"
   ],
   "license": "MIT",
-  "maintainers": [
-    {
-      "name": "dougwilson",
-      "email": "doug@somethingdoug.com"
-    }
-  ],
   "name": "accepts",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+https://github.com/jshttp/accepts.git"
   },
   "scripts": {
+    "lint": "eslint --plugin markdown --ext js,md .",
     "test": "mocha --reporter spec --check-leaks --bail test/",
     "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
     "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
   },
-  "version": "1.3.3"
+  "version": "1.3.4"
 }
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/README.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/README.md
deleted file mode 100644
index dd94d47..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/README.md
+++ /dev/null
@@ -1,64 +0,0 @@
-# ADM-ZIP for NodeJS
-
-ADM-ZIP is a pure JavaScript implementation for zip data compression for [NodeJS](http://nodejs.org/). 
-
-# Installation
-
-With [npm](http://npmjs.org) do:
-
-    $ npm install adm-zip
-	
-## What is it good for?
-The library allows you to:
-
-* decompress zip files directly to disk or in memory buffers
-* compress files and store them to disk in .zip format or in compressed buffers
-* update content of/add new/delete files from an existing .zip
-
-# Dependencies
-There are no other nodeJS libraries that ADM-ZIP is dependent of
-
-# Examples
-
-## Basic usage
-```javascript
-
-	var AdmZip = require('adm-zip');
-
-	// reading archives
-	var zip = new AdmZip("./my_file.zip");
-	var zipEntries = zip.getEntries(); // an array of ZipEntry records
-
-	zipEntries.forEach(function(zipEntry) {
-	    console.log(zipEntry.toString()); // outputs zip entries information
-		if (zipEntry.entryName == "my_file.txt") {
-		     console.log(zipEntry.data.toString('utf8')); 
-		}
-	});
-	// outputs the content of some_folder/my_file.txt
-	console.log(zip.readAsText("some_folder/my_file.txt")); 
-	// extracts the specified file to the specified location
-	zip.extractEntryTo(/*entry name*/"some_folder/my_file.txt", /*target path*/"/home/me/tempfolder", /*maintainEntryPath*/false, /*overwrite*/true);
-	// extracts everything
-	zip.extractAllTo(/*target path*/"/home/me/zipcontent/", /*overwrite*/true);
-	
-	
-	// creating archives
-	var zip = new AdmZip();
-	
-	// add file directly
-	zip.addFile("test.txt", new Buffer("inner content of the file"), "entry comment goes here");
-	// add local file
-	zip.addLocalFile("/home/me/some_picture.png");
-	// get everything as a buffer
-	var willSendthis = zip.toBuffer();
-	// or write everything to disk
-	zip.writeZip(/*target file name*/"/home/me/files.zip");
-	
-	
-	// ... more examples in the wiki
-```
-
-For more detailed information please check out the [wiki](https://github.com/cthackers/adm-zip/wiki).
-
-[![build status](https://secure.travis-ci.org/cthackers/adm-zip.png)](http://travis-ci.org/cthackers/adm-zip)
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/adm-zip.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/adm-zip.js
deleted file mode 100644
index 9ba4bd0..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/adm-zip.js
+++ /dev/null
@@ -1,475 +0,0 @@
-var fs = require("fs"),
-    pth = require("path");
-
-fs.existsSync = fs.existsSync || pth.existsSync;
-
-var ZipEntry = require("./zipEntry"),
-    ZipFile =  require("./zipFile"),
-    Utils = require("./util");
-
-module.exports = function(/*String*/input) {
-    var _zip = undefined,
-        _filename = "";
-
-    if (input && typeof input === "string") { // load zip file
-        if (fs.existsSync(input)) {
-            _filename = input;
-            _zip = new ZipFile(input, Utils.Constants.FILE);
-        } else {
-           throw Utils.Errors.INVALID_FILENAME;
-        }
-    } else if(input && Buffer.isBuffer(input)) { // load buffer
-        _zip = new ZipFile(input, Utils.Constants.BUFFER);
-    } else { // create new zip file
-        _zip = new ZipFile(null, Utils.Constants.NONE);
-    }
-
-    function getEntry(/*Object*/entry) {
-        if (entry && _zip) {
-            var item;
-            // If entry was given as a file name
-            if (typeof entry === "string")
-                item = _zip.getEntry(entry);
-            // if entry was given as a ZipEntry object
-            if (typeof entry === "object" && entry.entryName != undefined && entry.header != undefined)
-                item =  _zip.getEntry(entry.entryName);
-
-            if (item) {
-                return item;
-            }
-        }
-        return null;
-    }
-
-    return {
-        /**
-         * Extracts the given entry from the archive and returns the content as a Buffer object
-         * @param entry ZipEntry object or String with the full path of the entry
-         *
-         * @return Buffer or Null in case of error
-         */
-        readFile : function(/*Object*/entry) {
-            var item = getEntry(entry);
-            return item && item.getData() || null;
-        },
-
-        /**
-         * Asynchronous readFile
-         * @param entry ZipEntry object or String with the full path of the entry
-         * @param callback
-         *
-         * @return Buffer or Null in case of error
-         */
-        readFileAsync : function(/*Object*/entry, /*Function*/callback) {
-            var item = getEntry(entry);
-            if (item) {
-                item.getDataAsync(callback);
-            } else {
-                callback(null,"getEntry failed for:" + entry)
-            }
-        },
-
-        /**
-         * Extracts the given entry from the archive and returns the content as plain text in the given encoding
-         * @param entry ZipEntry object or String with the full path of the entry
-         * @param encoding Optional. If no encoding is specified utf8 is used
-         *
-         * @return String
-         */
-        readAsText : function(/*Object*/entry, /*String - Optional*/encoding) {
-            var item = getEntry(entry);
-            if (item) {
-                var data = item.getData();
-                if (data && data.length) {
-                    return data.toString(encoding || "utf8");
-                }
-            }
-            return "";
-        },
-
-        /**
-         * Asynchronous readAsText
-         * @param entry ZipEntry object or String with the full path of the entry
-         * @param callback
-         * @param encoding Optional. If no encoding is specified utf8 is used
-         *
-         * @return String
-         */
-        readAsTextAsync : function(/*Object*/entry, /*Function*/callback, /*String - Optional*/encoding) {
-            var item = getEntry(entry);
-            if (item) {
-                item.getDataAsync(function(data) {
-                    if (data && data.length) {
-                        callback(data.toString(encoding || "utf8"));
-                    } else {
-                        callback("");
-                    }
-                })
-            } else {
-                callback("");
-            }
-        },
-
-        /**
-         * Remove the entry from the file or the entry and all it's nested directories and files if the given entry is a directory
-         *
-         * @param entry
-         */
-        deleteFile : function(/*Object*/entry) { // @TODO: test deleteFile
-            var item = getEntry(entry);
-            if (item) {
-                _zip.deleteEntry(item.entryName);
-            }
-        },
-
-        /**
-         * Adds a comment to the zip. The zip must be rewritten after adding the comment.
-         *
-         * @param comment
-         */
-        addZipComment : function(/*String*/comment) { // @TODO: test addZipComment
-            _zip.comment = comment;
-        },
-
-        /**
-         * Returns the zip comment
-         *
-         * @return String
-         */
-        getZipComment : function() {
-            return _zip.comment || '';
-        },
-
-        /**
-         * Adds a comment to a specified zipEntry. The zip must be rewritten after adding the comment
-         * The comment cannot exceed 65535 characters in length
-         *
-         * @param entry
-         * @param comment
-         */
-        addZipEntryComment : function(/*Object*/entry,/*String*/comment) {
-            var item = getEntry(entry);
-            if (item) {
-                item.comment = comment;
-            }
-        },
-
-        /**
-         * Returns the comment of the specified entry
-         *
-         * @param entry
-         * @return String
-         */
-        getZipEntryComment : function(/*Object*/entry) {
-            var item = getEntry(entry);
-            if (item) {
-                return item.comment || '';
-            }
-            return ''
-        },
-
-        /**
-         * Updates the content of an existing entry inside the archive. The zip must be rewritten after updating the content
-         *
-         * @param entry
-         * @param content
-         */
-        updateFile : function(/*Object*/entry, /*Buffer*/content) {
-            var item = getEntry(entry);
-            if (item) {
-                item.setData(content);
-            }
-        },
-
-        /**
-         * Adds a file from the disk to the archive
-         *
-         * @param localPath
-         */
-        addLocalFile : function(/*String*/localPath, /*String*/zipPath, /*String*/zipName) {
-             if (fs.existsSync(localPath)) {
-                if(zipPath){
-                    zipPath=zipPath.split("\\").join("/");
-                    if(zipPath.charAt(zipPath.length - 1) != "/"){
-                        zipPath += "/";
-                    }
-                }else{
-                    zipPath="";
-                }
-                 var p = localPath.split("\\").join("/").split("/").pop();
-                
-                 if(zipName){
-                    this.addFile(zipPath+zipName, fs.readFileSync(localPath), "", 0)
-                 }else{
-                    this.addFile(zipPath+p, fs.readFileSync(localPath), "", 0)
-                 }
-             } else {
-                 throw Utils.Errors.FILE_NOT_FOUND.replace("%s", localPath);
-             }
-        },
-
-        /**
-         * Adds a local directory and all its nested files and directories to the archive
-         *
-         * @param localPath
-         * @param zipPath optional path inside zip
-         * @param filter optional RegExp or Function if files match will
-         *               be included.
-         */
-        addLocalFolder : function(/*String*/localPath, /*String*/zipPath, /*RegExp|Function*/filter) {
-            if (filter === undefined) {
-              filter = function() { return true; };
-            } else if (filter instanceof RegExp) {
-              filter = function(filter) {
-                return function(filename) {
-                  return filter.test(filename);
-                }
-              }(filter);
-            }
-
-            if(zipPath){
-                zipPath=zipPath.split("\\").join("/");
-                if(zipPath.charAt(zipPath.length - 1) != "/"){
-                    zipPath += "/";
-                }
-            }else{
-                zipPath="";
-            }
-			localPath = localPath.split("\\").join("/"); //windows fix
-            localPath = pth.normalize(localPath);
-            if (localPath.charAt(localPath.length - 1) != "/")
-                localPath += "/";
-
-            if (fs.existsSync(localPath)) {
-
-                var items = Utils.findFiles(localPath),
-                    self = this;
-
-                if (items.length) {
-                    items.forEach(function(path) {
-						var p = path.split("\\").join("/").replace( new RegExp(localPath, 'i'), ""); //windows fix
-                        if (filter(p)) {
-                            if (p.charAt(p.length - 1) !== "/") {
-                                self.addFile(zipPath+p, fs.readFileSync(path), "", 0)
-                            } else {
-                                self.addFile(zipPath+p, new Buffer(0), "", 0)
-                            }
-                        }
-                    });
-                }
-            } else {
-                throw Utils.Errors.FILE_NOT_FOUND.replace("%s", localPath);
-            }
-        },
-
-        /**
-         * Allows you to create a entry (file or directory) in the zip file.
-         * If you want to create a directory the entryName must end in / and a null buffer should be provided.
-         * Comment and attributes are optional
-         *
-         * @param entryName
-         * @param content
-         * @param comment
-         * @param attr
-         */
-        addFile : function(/*String*/entryName, /*Buffer*/content, /*String*/comment, /*Number*/attr) {
-            var entry = new ZipEntry();
-            entry.entryName = entryName;
-            entry.comment = comment || "";
-            entry.attr = attr || 438; //0666;
-            if (entry.isDirectory && content.length) {
-               // throw Utils.Errors.DIRECTORY_CONTENT_ERROR;
-            }
-            entry.setData(content);
-            _zip.setEntry(entry);
-        },
-
-        /**
-         * Returns an array of ZipEntry objects representing the files and folders inside the archive
-         *
-         * @return Array
-         */
-        getEntries : function() {
-            if (_zip) {
-               return _zip.entries;
-            } else {
-                return [];
-            }
-        },
-
-        /**
-         * Returns a ZipEntry object representing the file or folder specified by ``name``.
-         *
-         * @param name
-         * @return ZipEntry
-         */
-        getEntry : function(/*String*/name) {
-            return getEntry(name);
-        },
-
-        /**
-         * Extracts the given entry to the given targetPath
-         * If the entry is a directory inside the archive, the entire directory and it's subdirectories will be extracted
-         *
-         * @param entry ZipEntry object or String with the full path of the entry
-         * @param targetPath Target folder where to write the file
-         * @param maintainEntryPath If maintainEntryPath is true and the entry is inside a folder, the entry folder
-         *                          will be created in targetPath as well. Default is TRUE
-         * @param overwrite If the file already exists at the target path, the file will be overwriten if this is true.
-         *                  Default is FALSE
-         *
-         * @return Boolean
-         */
-        extractEntryTo : function(/*Object*/entry, /*String*/targetPath, /*Boolean*/maintainEntryPath, /*Boolean*/overwrite) {
-            overwrite = overwrite || false;
-            maintainEntryPath = typeof maintainEntryPath == "undefined" ? true : maintainEntryPath;
-
-            var item = getEntry(entry);
-            if (!item) {
-                throw Utils.Errors.NO_ENTRY;
-            }
-
-            var target = pth.resolve(targetPath, maintainEntryPath ? item.entryName : pth.basename(item.entryName));
-
-            if (item.isDirectory) {
-                target = pth.resolve(target, "..");
-                var children = _zip.getEntryChildren(item);
-                children.forEach(function(child) {
-                    if (child.isDirectory) return;
-                    var content = child.getData();
-                    if (!content) {
-                        throw Utils.Errors.CANT_EXTRACT_FILE;
-                    }
-                    Utils.writeFileTo(pth.resolve(targetPath, maintainEntryPath ? child.entryName : child.entryName.substr(item.entryName.length)), content, overwrite);
-                });
-                return true;
-            }
-
-            var content = item.getData();
-            if (!content) throw Utils.Errors.CANT_EXTRACT_FILE;
-
-            if (fs.existsSync(target) && !overwrite) {
-                throw Utils.Errors.CANT_OVERRIDE;
-            }
-            Utils.writeFileTo(target, content, overwrite);
-
-            return true;
-        },
-
-        /**
-         * Extracts the entire archive to the given location
-         *
-         * @param targetPath Target location
-         * @param overwrite If the file already exists at the target path, the file will be overwriten if this is true.
-         *                  Default is FALSE
-         */
-        extractAllTo : function(/*String*/targetPath, /*Boolean*/overwrite) {
-            overwrite = overwrite || false;
-            if (!_zip) {
-                throw Utils.Errors.NO_ZIP;
-            }
-
-            _zip.entries.forEach(function(entry) {
-                if (entry.isDirectory) {
-                    Utils.makeDir(pth.resolve(targetPath, entry.entryName.toString()));
-                    return;
-                }
-                var content = entry.getData();
-                if (!content) {
-                    throw Utils.Errors.CANT_EXTRACT_FILE + "2";
-                }
-                Utils.writeFileTo(pth.resolve(targetPath, entry.entryName.toString()), content, overwrite);
-            })
-        },
-
-        /**
-         * Asynchronous extractAllTo
-         *
-         * @param targetPath Target location
-         * @param overwrite If the file already exists at the target path, the file will be overwriten if this is true.
-         *                  Default is FALSE
-         * @param callback
-         */
-        extractAllToAsync : function(/*String*/targetPath, /*Boolean*/overwrite, /*Function*/callback) {
-            overwrite = overwrite || false;
-            if (!_zip) {
-                callback(new Error(Utils.Errors.NO_ZIP));
-                return;
-            }
-
-            var entries = _zip.entries;
-            var i = entries.length; 
-            entries.forEach(function(entry) {
-                if(i <= 0) return; // Had an error already
-
-                if (entry.isDirectory) {
-                    Utils.makeDir(pth.resolve(targetPath, entry.entryName.toString()));
-                    if(--i == 0)
-                        callback(undefined);
-                    return;
-                }
-                entry.getDataAsync(function(content) {
-                    if(i <= 0) return;
-                    if (!content) {
-                        i = 0;
-                        callback(new Error(Utils.Errors.CANT_EXTRACT_FILE + "2"));
-                        return;
-                    }
-                    Utils.writeFileToAsync(pth.resolve(targetPath, entry.entryName.toString()), content, overwrite, function(succ) {
-                        if(i <= 0) return;
-
-                        if(!succ) {
-                            i = 0;
-                            callback(new Error('Unable to write'));
-                            return;
-                        }
-
-                        if(--i == 0)
-                            callback(undefined);
-                    });
-                    
-                });
-            })
-        },
-
-        /**
-         * Writes the newly created zip file to disk at the specified location or if a zip was opened and no ``targetFileName`` is provided, it will overwrite the opened zip
-         *
-         * @param targetFileName
-         * @param callback
-         */
-        writeZip : function(/*String*/targetFileName, /*Function*/callback) {
-            if (arguments.length == 1) {
-                if (typeof targetFileName == "function") {
-                    callback = targetFileName;
-                    targetFileName = "";
-                }
-            }
-
-            if (!targetFileName && _filename) {
-                targetFileName = _filename;
-            }
-            if (!targetFileName) return;
-
-            var zipData = _zip.compressToBuffer();
-            if (zipData) {
-                var ok = Utils.writeFileTo(targetFileName, zipData, true);
-                if (typeof callback == 'function') callback(!ok? new Error("failed"): null, "");
-            }
-        },
-
-        /**
-         * Returns the content of the entire zip file as a Buffer object
-         *
-         * @return Buffer
-         */
-        toBuffer : function(/*Function*/onSuccess,/*Function*/onFail,/*Function*/onItemStart,/*Function*/onItemEnd) {
-            this.valueOf = 2;
-            if (typeof onSuccess == "function") {
-                _zip.toAsyncBuffer(onSuccess,onFail,onItemStart,onItemEnd);
-                return null;
-            }
-            return _zip.compressToBuffer()
-        }
-    }
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/entryHeader.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/entryHeader.js
deleted file mode 100644
index 9a0e1bd..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/entryHeader.js
+++ /dev/null
@@ -1,261 +0,0 @@
-var Utils = require("../util"),
-    Constants = Utils.Constants;
-
-/* The central directory file header */
-module.exports = function () {
-    var _verMade = 0x0A,
-        _version = 0x0A,
-        _flags = 0,
-        _method = 0,
-        _time = 0,
-        _crc = 0,
-        _compressedSize = 0,
-        _size = 0,
-        _fnameLen = 0,
-        _extraLen = 0,
-
-        _comLen = 0,
-        _diskStart = 0,
-        _inattr = 0,
-        _attr = 0,
-        _offset = 0;
-
-    var _dataHeader = {};
-
-    function setTime(val) {
-        var val = new Date(val);
-        _time = (val.getFullYear() - 1980 & 0x7f) << 25  // b09-16 years from 1980
-            | (val.getMonth() + 1) << 21                 // b05-08 month
-            | val.getDay() << 16                         // b00-04 hour
-
-            // 2 bytes time
-            | val.getHours() << 11    // b11-15 hour
-            | val.getMinutes() << 5   // b05-10 minute
-            | val.getSeconds() >> 1;  // b00-04 seconds divided by 2
-    }
-
-    setTime(+new Date());
-
-    return {
-        get made () { return _verMade; },
-        set made (val) { _verMade = val; },
-
-        get version () { return _version; },
-        set version (val) { _version = val },
-
-        get flags () { return _flags },
-        set flags (val) { _flags = val; },
-
-        get method () { return _method; },
-        set method (val) { _method = val; },
-
-        get time () { return new Date(
-            ((_time >> 25) & 0x7f) + 1980,
-            ((_time >> 21) & 0x0f) - 1,
-            (_time >> 16) & 0x1f,
-            (_time >> 11) & 0x1f,
-            (_time >> 5) & 0x3f,
-            (_time & 0x1f) << 1
-        );
-        },
-        set time (val) {
-            setTime(val);
-        },
-
-        get crc () { return _crc; },
-        set crc (val) { _crc = val; },
-
-        get compressedSize () { return _compressedSize; },
-        set compressedSize (val) { _compressedSize = val; },
-
-        get size () { return _size; },
-        set size (val) { _size = val; },
-
-        get fileNameLength () { return _fnameLen; },
-        set fileNameLength (val) { _fnameLen = val; },
-
-        get extraLength () { return _extraLen },
-        set extraLength (val) { _extraLen = val; },
-
-        get commentLength () { return _comLen },
-        set commentLength (val) { _comLen = val },
-
-        get diskNumStart () { return _diskStart },
-        set diskNumStart (val) { _diskStart = val },
-
-        get inAttr () { return _inattr },
-        set inAttr (val) { _inattr = val },
-
-        get attr () { return _attr },
-        set attr (val) { _attr = val },
-
-        get offset () { return _offset },
-        set offset (val) { _offset = val },
-
-        get encripted () { return (_flags & 1) == 1 },
-
-        get entryHeaderSize () {
-            return Constants.CENHDR + _fnameLen + _extraLen + _comLen;
-        },
-
-        get realDataOffset () {
-            return _offset + Constants.LOCHDR + _dataHeader.fnameLen + _dataHeader.extraLen;
-        },
-
-        get dataHeader () {
-            return _dataHeader;
-        },
-
-        loadDataHeaderFromBinary : function(/*Buffer*/input) {
-            var data = input.slice(_offset, _offset + Constants.LOCHDR);
-            // 30 bytes and should start with "PK\003\004"
-            if (data.readUInt32LE(0) != Constants.LOCSIG) {
-                throw Utils.Errors.INVALID_LOC;
-            }
-            _dataHeader = {
-                // version needed to extract
-                version : data.readUInt16LE(Constants.LOCVER),
-                // general purpose bit flag
-                flags : data.readUInt16LE(Constants.LOCFLG),
-                // compression method
-                method : data.readUInt16LE(Constants.LOCHOW),
-                // modification time (2 bytes time, 2 bytes date)
-                time : data.readUInt32LE(Constants.LOCTIM),
-                // uncompressed file crc-32 value
-                crc : data.readUInt32LE(Constants.LOCCRC),
-                // compressed size
-                compressedSize : data.readUInt32LE(Constants.LOCSIZ),
-                // uncompressed size
-                size : data.readUInt32LE(Constants.LOCLEN),
-                // filename length
-                fnameLen : data.readUInt16LE(Constants.LOCNAM),
-                // extra field length
-                extraLen : data.readUInt16LE(Constants.LOCEXT)
-            }
-        },
-
-        loadFromBinary : function(/*Buffer*/data) {
-            // data should be 46 bytes and start with "PK 01 02"
-            if (data.length != Constants.CENHDR || data.readUInt32LE(0) != Constants.CENSIG) {
-                throw Utils.Errors.INVALID_CEN;
-            }
-            // version made by
-            _verMade = data.readUInt16LE(Constants.CENVEM);
-            // version needed to extract
-            _version = data.readUInt16LE(Constants.CENVER);
-            // encrypt, decrypt flags
-            _flags = data.readUInt16LE(Constants.CENFLG);
-            // compression method
-            _method = data.readUInt16LE(Constants.CENHOW);
-            // modification time (2 bytes time, 2 bytes date)
-            _time = data.readUInt32LE(Constants.CENTIM);
-            // uncompressed file crc-32 value
-            _crc = data.readUInt32LE(Constants.CENCRC);
-            // compressed size
-            _compressedSize = data.readUInt32LE(Constants.CENSIZ);
-            // uncompressed size
-            _size = data.readUInt32LE(Constants.CENLEN);
-            // filename length
-            _fnameLen = data.readUInt16LE(Constants.CENNAM);
-            // extra field length
-            _extraLen = data.readUInt16LE(Constants.CENEXT);
-            // file comment length
-            _comLen = data.readUInt16LE(Constants.CENCOM);
-            // volume number start
-            _diskStart = data.readUInt16LE(Constants.CENDSK);
-            // internal file attributes
-            _inattr = data.readUInt16LE(Constants.CENATT);
-            // external file attributes
-            _attr = data.readUInt32LE(Constants.CENATX);
-            // LOC header offset
-            _offset = data.readUInt32LE(Constants.CENOFF);
-        },
-
-        dataHeaderToBinary : function() {
-            // LOC header size (30 bytes)
-            var data = new Buffer(Constants.LOCHDR);
-            // "PK\003\004"
-            data.writeUInt32LE(Constants.LOCSIG, 0);
-            // version needed to extract
-            data.writeUInt16LE(_version, Constants.LOCVER);
-            // general purpose bit flag
-            data.writeUInt16LE(_flags, Constants.LOCFLG);
-            // compression method
-            data.writeUInt16LE(_method, Constants.LOCHOW);
-            // modification time (2 bytes time, 2 bytes date)
-            data.writeUInt32LE(_time, Constants.LOCTIM);
-            // uncompressed file crc-32 value
-            data.writeUInt32LE(_crc, Constants.LOCCRC);
-            // compressed size
-            data.writeUInt32LE(_compressedSize, Constants.LOCSIZ);
-            // uncompressed size
-            data.writeUInt32LE(_size, Constants.LOCLEN);
-            // filename length
-            data.writeUInt16LE(_fnameLen, Constants.LOCNAM);
-            // extra field length
-            data.writeUInt16LE(_extraLen, Constants.LOCEXT);
-            return data;
-        },
-
-        entryHeaderToBinary : function() {
-            // CEN header size (46 bytes)
-            var data = new Buffer(Constants.CENHDR + _fnameLen + _extraLen + _comLen);
-            // "PK\001\002"
-            data.writeUInt32LE(Constants.CENSIG, 0);
-            // version made by
-            data.writeUInt16LE(_verMade, Constants.CENVEM);
-            // version needed to extract
-            data.writeUInt16LE(_version, Constants.CENVER);
-            // encrypt, decrypt flags
-            data.writeUInt16LE(_flags, Constants.CENFLG);
-            // compression method
-            data.writeUInt16LE(_method, Constants.CENHOW);
-            // modification time (2 bytes time, 2 bytes date)
-            data.writeUInt32LE(_time, Constants.CENTIM);
-            // uncompressed file crc-32 value
-            data.writeInt32LE(_crc, Constants.CENCRC, true);
-            // compressed size
-            data.writeUInt32LE(_compressedSize, Constants.CENSIZ);
-            // uncompressed size
-            data.writeUInt32LE(_size, Constants.CENLEN);
-            // filename length
-            data.writeUInt16LE(_fnameLen, Constants.CENNAM);
-            // extra field length
-            data.writeUInt16LE(_extraLen, Constants.CENEXT);
-            // file comment length
-            data.writeUInt16LE(_comLen, Constants.CENCOM);
-            // volume number start
-            data.writeUInt16LE(_diskStart, Constants.CENDSK);
-            // internal file attributes
-            data.writeUInt16LE(_inattr, Constants.CENATT);
-            // external file attributes
-            data.writeUInt32LE(_attr, Constants.CENATX);
-            // LOC header offset
-            data.writeUInt32LE(_offset, Constants.CENOFF);
-            // fill all with
-            data.fill(0x00, Constants.CENHDR);
-            return data;
-        },
-
-        toString : function() {
-            return '{\n' +
-                '\t"made" : ' + _verMade + ",\n" +
-                '\t"version" : ' + _version + ",\n" +
-                '\t"flags" : ' + _flags + ",\n" +
-                '\t"method" : ' + Utils.methodToString(_method) + ",\n" +
-                '\t"time" : ' + _time + ",\n" +
-                '\t"crc" : 0x' + _crc.toString(16).toUpperCase() + ",\n" +
-                '\t"compressedSize" : ' + _compressedSize + " bytes,\n" +
-                '\t"size" : ' + _size + " bytes,\n" +
-                '\t"fileNameLength" : ' + _fnameLen + ",\n" +
-                '\t"extraLength" : ' + _extraLen + " bytes,\n" +
-                '\t"commentLength" : ' + _comLen + " bytes,\n" +
-                '\t"diskNumStart" : ' + _diskStart + ",\n" +
-                '\t"inAttr" : ' + _inattr + ",\n" +
-                '\t"attr" : ' + _attr + ",\n" +
-                '\t"offset" : ' + _offset + ",\n" +
-                '\t"entryHeaderSize" : ' + (Constants.CENHDR + _fnameLen + _extraLen + _comLen) + " bytes\n" +
-                '}';
-        }
-    }
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/index.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/index.js
deleted file mode 100644
index b54a722..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/index.js
+++ /dev/null
@@ -1,2 +0,0 @@
-exports.EntryHeader = require("./entryHeader");
-exports.MainHeader = require("./mainHeader");
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/mainHeader.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/mainHeader.js
deleted file mode 100644
index de8ae1a..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/headers/mainHeader.js
+++ /dev/null
@@ -1,80 +0,0 @@
-var Utils = require("../util"),
-    Constants = Utils.Constants;
-
-/* The entries in the end of central directory */
-module.exports = function () {
-    var _volumeEntries = 0,
-        _totalEntries = 0,
-        _size = 0,
-        _offset = 0,
-        _commentLength = 0;
-
-    return {
-        get diskEntries () { return _volumeEntries },
-        set diskEntries (/*Number*/val) { _volumeEntries = _totalEntries = val; },
-
-        get totalEntries () { return _totalEntries },
-        set totalEntries (/*Number*/val) { _totalEntries = _volumeEntries = val; },
-
-        get size () { return _size },
-        set size (/*Number*/val) { _size = val; },
-
-        get offset () { return _offset },
-        set offset (/*Number*/val) { _offset = val; },
-
-        get commentLength () { return _commentLength },
-        set commentLength (/*Number*/val) { _commentLength = val; },
-
-        get mainHeaderSize () {
-            return Constants.ENDHDR + _commentLength;
-        },
-
-        loadFromBinary : function(/*Buffer*/data) {
-            // data should be 22 bytes and start with "PK 05 06"
-            if (data.length != Constants.ENDHDR || data.readUInt32LE(0) != Constants.ENDSIG)
-                throw Utils.Errors.INVALID_END;
-
-            // number of entries on this volume
-            _volumeEntries = data.readUInt16LE(Constants.ENDSUB);
-            // total number of entries
-            _totalEntries = data.readUInt16LE(Constants.ENDTOT);
-            // central directory size in bytes
-            _size = data.readUInt32LE(Constants.ENDSIZ);
-            // offset of first CEN header
-            _offset = data.readUInt32LE(Constants.ENDOFF);
-            // zip file comment length
-            _commentLength = data.readUInt16LE(Constants.ENDCOM);
-        },
-
-        toBinary : function() {
-           var b = new Buffer(Constants.ENDHDR + _commentLength);
-            // "PK 05 06" signature
-            b.writeUInt32LE(Constants.ENDSIG, 0);
-            b.writeUInt32LE(0, 4);
-            // number of entries on this volume
-            b.writeUInt16LE(_volumeEntries, Constants.ENDSUB);
-            // total number of entries
-            b.writeUInt16LE(_totalEntries, Constants.ENDTOT);
-            // central directory size in bytes
-            b.writeUInt32LE(_size, Constants.ENDSIZ);
-            // offset of first CEN header
-            b.writeUInt32LE(_offset, Constants.ENDOFF);
-            // zip file comment length
-            b.writeUInt16LE(_commentLength, Constants.ENDCOM);
-            // fill comment memory with spaces so no garbage is left there
-            b.fill(" ", Constants.ENDHDR);
-
-            return b;
-        },
-
-        toString : function() {
-            return '{\n' +
-                '\t"diskEntries" : ' + _volumeEntries + ",\n" +
-                '\t"totalEntries" : ' + _totalEntries + ",\n" +
-                '\t"size" : ' + _size + " bytes,\n" +
-                '\t"offset" : 0x' + _offset.toString(16).toUpperCase() + ",\n" +
-                '\t"commentLength" : 0x' + _commentLength + "\n" +
-            '}';
-        }
-    }
-};
\ No newline at end of file
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/deflater.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/deflater.js
deleted file mode 100644
index 34ef297..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/deflater.js
+++ /dev/null
@@ -1,1578 +0,0 @@
-/*
- * $Id: rawdeflate.js,v 0.5 2013/04/09 14:25:38 dankogai Exp dankogai $
- *
- * GNU General Public License, version 2 (GPL-2.0)
- *   http://opensource.org/licenses/GPL-2.0
- * Original:
- *  http://www.onicos.com/staff/iz/amuse/javascript/expert/deflate.txt
- */
-function JSDeflater(/*inbuff*/inbuf) {
-
-    /* Copyright (C) 1999 Masanao Izumo <iz...@onicos.co.jp>
-     * Version: 1.0.1
-     * LastModified: Dec 25 1999
-     */
-
-    var WSIZE = 32768,		// Sliding Window size
-        zip_STORED_BLOCK = 0,
-        zip_STATIC_TREES = 1,
-        zip_DYN_TREES = 2,
-        zip_DEFAULT_LEVEL = 6,
-        zip_FULL_SEARCH = true,
-        zip_INBUFSIZ = 32768,	// Input buffer size
-        zip_INBUF_EXTRA = 64,	// Extra buffer
-        zip_OUTBUFSIZ = 1024 * 8,
-        zip_window_size = 2 * WSIZE,
-        MIN_MATCH = 3,
-        MAX_MATCH = 258,
-        zip_BITS = 16,
-        LIT_BUFSIZE = 0x2000,
-        zip_HASH_BITS = 13,
-        zip_DIST_BUFSIZE = LIT_BUFSIZE,
-        zip_HASH_SIZE = 1 << zip_HASH_BITS,
-        zip_HASH_MASK = zip_HASH_SIZE - 1,
-        zip_WMASK = WSIZE - 1,
-        zip_NIL = 0, // Tail of hash chains
-        zip_TOO_FAR = 4096,
-        zip_MIN_LOOKAHEAD = MAX_MATCH + MIN_MATCH + 1,
-        zip_MAX_DIST = WSIZE - zip_MIN_LOOKAHEAD,
-        zip_SMALLEST = 1,
-        zip_MAX_BITS = 15,
-        zip_MAX_BL_BITS = 7,
-        zip_LENGTH_CODES = 29,
-        zip_LITERALS = 256,
-        zip_END_BLOCK = 256,
-        zip_L_CODES = zip_LITERALS + 1 + zip_LENGTH_CODES,
-        zip_D_CODES = 30,
-        zip_BL_CODES = 19,
-        zip_REP_3_6 = 16,
-        zip_REPZ_3_10 = 17,
-        zip_REPZ_11_138 = 18,
-        zip_HEAP_SIZE = 2 * zip_L_CODES + 1,
-        zip_H_SHIFT = parseInt((zip_HASH_BITS + MIN_MATCH - 1) / MIN_MATCH);
-
-    var zip_free_queue, zip_qhead, zip_qtail, zip_initflag, zip_outbuf = null, zip_outcnt, zip_outoff, zip_complete,
-        zip_window, zip_d_buf, zip_l_buf, zip_prev, zip_bi_buf, zip_bi_valid, zip_block_start, zip_ins_h, zip_hash_head,
-        zip_prev_match, zip_match_available, zip_match_length, zip_prev_length, zip_strstart, zip_match_start, zip_eofile,
-        zip_lookahead, zip_max_chain_length, zip_max_lazy_match, zip_compr_level, zip_good_match, zip_nice_match,
-        zip_dyn_ltree, zip_dyn_dtree, zip_static_ltree, zip_static_dtree, zip_bl_tree, zip_l_desc, zip_d_desc, zip_bl_desc,
-        zip_bl_count, zip_heap, zip_heap_len, zip_heap_max, zip_depth, zip_length_code, zip_dist_code, zip_base_length,
-        zip_base_dist, zip_flag_buf, zip_last_lit, zip_last_dist, zip_last_flags, zip_flags, zip_flag_bit, zip_opt_len,
-        zip_static_len, zip_deflate_data, zip_deflate_pos;
-
-    var zip_DeflateCT = function () {
-        this.fc = 0; // frequency count or bit string
-        this.dl = 0; // father node in Huffman tree or length of bit string
-    };
-
-    var zip_DeflateTreeDesc = function () {
-        this.dyn_tree = null;	// the dynamic tree
-        this.static_tree = null;	// corresponding static tree or NULL
-        this.extra_bits = null;	// extra bits for each code or NULL
-        this.extra_base = 0;	// base index for extra_bits
-        this.elems = 0;		// max number of elements in the tree
-        this.max_length = 0;	// max bit length for the codes
-        this.max_code = 0;		// largest code with non zero frequency
-    };
-
-    /* Values for max_lazy_match, good_match and max_chain_length, depending on
-     * the desired pack level (0..9). The values given below have been tuned to
-     * exclude worst case performance for pathological files. Better values may be
-     * found for specific files.
-     */
-    var zip_DeflateConfiguration = function (a, b, c, d) {
-        this.good_length = a; // reduce lazy search above this match length
-        this.max_lazy = b;    // do not perform lazy search above this match length
-        this.nice_length = c; // quit search above this match length
-        this.max_chain = d;
-    };
-
-    var zip_DeflateBuffer = function () {
-        this.next = null;
-        this.len = 0;
-        this.ptr = new Array(zip_OUTBUFSIZ);
-        this.off = 0;
-    };
-
-    /* constant tables */
-    var zip_extra_lbits = new Array(
-        0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0);
-    var zip_extra_dbits = new Array(
-        0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13);
-    var zip_extra_blbits = new Array(
-        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7);
-    var zip_bl_order = new Array(
-        16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15);
-    var zip_configuration_table = new Array(
-        new zip_DeflateConfiguration(0, 0, 0, 0),
-        new zip_DeflateConfiguration(4, 4, 8, 4),
-        new zip_DeflateConfiguration(4, 5, 16, 8),
-        new zip_DeflateConfiguration(4, 6, 32, 32),
-        new zip_DeflateConfiguration(4, 4, 16, 16),
-        new zip_DeflateConfiguration(8, 16, 32, 32),
-        new zip_DeflateConfiguration(8, 16, 128, 128),
-        new zip_DeflateConfiguration(8, 32, 128, 256),
-        new zip_DeflateConfiguration(32, 128, 258, 1024),
-        new zip_DeflateConfiguration(32, 258, 258, 4096));
-
-
-    /* routines (deflate) */
-
-    var zip_deflate_start = function (level) {
-        var i;
-
-        if (!level)
-            level = zip_DEFAULT_LEVEL;
-        else if (level < 1)
-            level = 1;
-        else if (level > 9)
-            level = 9;
-
-        zip_compr_level = level;
-        zip_initflag = false;
-        zip_eofile = false;
-        if (zip_outbuf != null)
-            return;
-
-        zip_free_queue = zip_qhead = zip_qtail = null;
-        zip_outbuf = new Array(zip_OUTBUFSIZ);
-        zip_window = new Array(zip_window_size);
-        zip_d_buf = new Array(zip_DIST_BUFSIZE);
-        zip_l_buf = new Array(zip_INBUFSIZ + zip_INBUF_EXTRA);
-        zip_prev = new Array(1 << zip_BITS);
-        zip_dyn_ltree = new Array(zip_HEAP_SIZE);
-        for (i = 0; i < zip_HEAP_SIZE; i++) zip_dyn_ltree[i] = new zip_DeflateCT();
-        zip_dyn_dtree = new Array(2 * zip_D_CODES + 1);
-        for (i = 0; i < 2 * zip_D_CODES + 1; i++) zip_dyn_dtree[i] = new zip_DeflateCT();
-        zip_static_ltree = new Array(zip_L_CODES + 2);
-        for (i = 0; i < zip_L_CODES + 2; i++) zip_static_ltree[i] = new zip_DeflateCT();
-        zip_static_dtree = new Array(zip_D_CODES);
-        for (i = 0; i < zip_D_CODES; i++) zip_static_dtree[i] = new zip_DeflateCT();
-        zip_bl_tree = new Array(2 * zip_BL_CODES + 1);
-        for (i = 0; i < 2 * zip_BL_CODES + 1; i++) zip_bl_tree[i] = new zip_DeflateCT();
-        zip_l_desc = new zip_DeflateTreeDesc();
-        zip_d_desc = new zip_DeflateTreeDesc();
-        zip_bl_desc = new zip_DeflateTreeDesc();
-        zip_bl_count = new Array(zip_MAX_BITS + 1);
-        zip_heap = new Array(2 * zip_L_CODES + 1);
-        zip_depth = new Array(2 * zip_L_CODES + 1);
-        zip_length_code = new Array(MAX_MATCH - MIN_MATCH + 1);
-        zip_dist_code = new Array(512);
-        zip_base_length = new Array(zip_LENGTH_CODES);
-        zip_base_dist = new Array(zip_D_CODES);
-        zip_flag_buf = new Array(parseInt(LIT_BUFSIZE / 8));
-    };
-
-    var zip_deflate_end = function () {
-        zip_free_queue = zip_qhead = zip_qtail = null;
-        zip_outbuf = null;
-        zip_window = null;
-        zip_d_buf = null;
-        zip_l_buf = null;
-        zip_prev = null;
-        zip_dyn_ltree = null;
-        zip_dyn_dtree = null;
-        zip_static_ltree = null;
-        zip_static_dtree = null;
-        zip_bl_tree = null;
-        zip_l_desc = null;
-        zip_d_desc = null;
-        zip_bl_desc = null;
-        zip_bl_count = null;
-        zip_heap = null;
-        zip_depth = null;
-        zip_length_code = null;
-        zip_dist_code = null;
-        zip_base_length = null;
-        zip_base_dist = null;
-        zip_flag_buf = null;
-    };
-
-    var zip_reuse_queue = function (p) {
-        p.next = zip_free_queue;
-        zip_free_queue = p;
-    };
-
-    var zip_new_queue = function () {
-        var p;
-
-        if (zip_free_queue != null) {
-            p = zip_free_queue;
-            zip_free_queue = zip_free_queue.next;
-        }
-        else
-            p = new zip_DeflateBuffer();
-        p.next = null;
-        p.len = p.off = 0;
-
-        return p;
-    };
-
-    var zip_head1 = function (i) {
-        return zip_prev[WSIZE + i];
-    };
-
-    var zip_head2 = function (i, val) {
-        return zip_prev[WSIZE + i] = val;
-    };
-
-    /* put_byte is used for the compressed output, put_ubyte for the
-     * uncompressed output. However unlzw() uses window for its
-     * suffix table instead of its output buffer, so it does not use put_ubyte
-     * (to be cleaned up).
-     */
-    var zip_put_byte = function (c) {
-        zip_outbuf[zip_outoff + zip_outcnt++] = c;
-        if (zip_outoff + zip_outcnt == zip_OUTBUFSIZ)
-            zip_qoutbuf();
-    };
-
-    /* Output a 16 bit value, lsb first */
-    var zip_put_short = function (w) {
-        w &= 0xffff;
-        if (zip_outoff + zip_outcnt < zip_OUTBUFSIZ - 2) {
-            zip_outbuf[zip_outoff + zip_outcnt++] = (w & 0xff);
-            zip_outbuf[zip_outoff + zip_outcnt++] = (w >>> 8);
-        } else {
-            zip_put_byte(w & 0xff);
-            zip_put_byte(w >>> 8);
-        }
-    };
-
-    /* ==========================================================================
-     * Insert string s in the dictionary and set match_head to the previous head
-     * of the hash chain (the most recent string with same hash key). Return
-     * the previous length of the hash chain.
-     * IN  assertion: all calls to to INSERT_STRING are made with consecutive
-     *    input characters and the first MIN_MATCH bytes of s are valid
-     *    (except for the last MIN_MATCH-1 bytes of the input file).
-     */
-    var zip_INSERT_STRING = function () {
-        zip_ins_h = ((zip_ins_h << zip_H_SHIFT)
-            ^ (zip_window[zip_strstart + MIN_MATCH - 1] & 0xff))
-            & zip_HASH_MASK;
-        zip_hash_head = zip_head1(zip_ins_h);
-        zip_prev[zip_strstart & zip_WMASK] = zip_hash_head;
-        zip_head2(zip_ins_h, zip_strstart);
-    };
-
-    /* Send a code of the given tree. c and tree must not have side effects */
-    var zip_SEND_CODE = function (c, tree) {
-        zip_send_bits(tree[c].fc, tree[c].dl);
-    };
-
-    /* Mapping from a distance to a distance code. dist is the distance - 1 and
-     * must not have side effects. dist_code[256] and dist_code[257] are never
-     * used.
-     */
-    var zip_D_CODE = function (dist) {
-        return (dist < 256 ? zip_dist_code[dist]
-            : zip_dist_code[256 + (dist >> 7)]) & 0xff;
-    };
-
-    /* ==========================================================================
-     * Compares to subtrees, using the tree depth as tie breaker when
-     * the subtrees have equal frequency. This minimizes the worst case length.
-     */
-    var zip_SMALLER = function (tree, n, m) {
-        return tree[n].fc < tree[m].fc ||
-            (tree[n].fc == tree[m].fc && zip_depth[n] <= zip_depth[m]);
-    };
-
-    /* ==========================================================================
-     * read string data
-     */
-    var zip_read_buff = function (buff, offset, n) {
-        var i;
-        for (i = 0; i < n && zip_deflate_pos < zip_deflate_data.length; i++)
-            buff[offset + i] =
-                zip_deflate_data[zip_deflate_pos++] & 0xff;
-        return i;
-    };
-
-    /* ==========================================================================
-     * Initialize the "longest match" routines for a new file
-     */
-    var zip_lm_init = function () {
-        var j;
-
-        /* Initialize the hash table. */
-        for (j = 0; j < zip_HASH_SIZE; j++)
-            zip_prev[WSIZE + j] = 0;
-        zip_max_lazy_match = zip_configuration_table[zip_compr_level].max_lazy;
-        zip_good_match = zip_configuration_table[zip_compr_level].good_length;
-        if (!zip_FULL_SEARCH)
-            zip_nice_match = zip_configuration_table[zip_compr_level].nice_length;
-        zip_max_chain_length = zip_configuration_table[zip_compr_level].max_chain;
-
-        zip_strstart = 0;
-        zip_block_start = 0;
-
-        zip_lookahead = zip_read_buff(zip_window, 0, 2 * WSIZE);
-        if (zip_lookahead <= 0) {
-            zip_eofile = true;
-            zip_lookahead = 0;
-            return;
-        }
-        zip_eofile = false;
-        /* Make sure that we always have enough lookahead. This is important
-         * if input comes from a device such as a tty.
-         */
-        while (zip_lookahead < zip_MIN_LOOKAHEAD && !zip_eofile)
-            zip_fill_window();
-
-        /* If lookahead < MIN_MATCH, ins_h is garbage, but this is
-         * not important since only literal bytes will be emitted.
-         */
-        zip_ins_h = 0;
-        for (j = 0; j < MIN_MATCH - 1; j++) {
-            zip_ins_h = ((zip_ins_h << zip_H_SHIFT) ^ (zip_window[j] & 0xff)) & zip_HASH_MASK;
-        }
-    };
-
-    /* ==========================================================================
-     * Set match_start to the longest match starting at the given string and
-     * return its length. Matches shorter or equal to prev_length are discarded,
-     * in which case the result is equal to prev_length and match_start is
-     * garbage.
-     * IN assertions: cur_match is the head of the hash chain for the current
-     *   string (strstart) and its distance is <= MAX_DIST, and prev_length >= 1
-     */
-    var zip_longest_match = function (cur_match) {
-        var chain_length = zip_max_chain_length; // max hash chain length
-        var scanp = zip_strstart; // current string
-        var matchp;		// matched string
-        var len;		// length of current match
-        var best_len = zip_prev_length;	// best match length so far
-
-        /* Stop when cur_match becomes <= limit. To simplify the code,
-         * we prevent matches with the string of window index 0.
-         */
-        var limit = (zip_strstart > zip_MAX_DIST ? zip_strstart - zip_MAX_DIST : zip_NIL);
-
-        var strendp = zip_strstart + MAX_MATCH;
-        var scan_end1 = zip_window[scanp + best_len - 1];
-        var scan_end = zip_window[scanp + best_len];
-
-        /* Do not waste too much time if we already have a good match: */
-        if (zip_prev_length >= zip_good_match)
-            chain_length >>= 2;
-
-        do {
-            matchp = cur_match;
-
-            /* Skip to next match if the match length cannot increase
-             * or if the match length is less than 2:
-             */
-            if (zip_window[matchp + best_len] != scan_end ||
-                zip_window[matchp + best_len - 1] != scan_end1 ||
-                zip_window[matchp] != zip_window[scanp] ||
-                zip_window[++matchp] != zip_window[scanp + 1]) {
-                continue;
-            }
-
-            /* The check at best_len-1 can be removed because it will be made
-             * again later. (This heuristic is not always a win.)
-             * It is not necessary to compare scan[2] and match[2] since they
-             * are always equal when the other bytes match, given that
-             * the hash keys are equal and that HASH_BITS >= 8.
-             */
-            scanp += 2;
-            matchp++;
-
-            /* We check for insufficient lookahead only every 8th comparison;
-             * the 256th check will be made at strstart+258.
-             */
-            do {
-            } while (zip_window[++scanp] == zip_window[++matchp] &&
-                zip_window[++scanp] == zip_window[++matchp] &&
-                zip_window[++scanp] == zip_window[++matchp] &&
-                zip_window[++scanp] == zip_window[++matchp] &&
-                zip_window[++scanp] == zip_window[++matchp] &&
-                zip_window[++scanp] == zip_window[++matchp] &&
-                zip_window[++scanp] == zip_window[++matchp] &&
-                zip_window[++scanp] == zip_window[++matchp] &&
-                scanp < strendp);
-
-            len = MAX_MATCH - (strendp - scanp);
-            scanp = strendp - MAX_MATCH;
-
-            if (len > best_len) {
-                zip_match_start = cur_match;
-                best_len = len;
-                if (zip_FULL_SEARCH) {
-                    if (len >= MAX_MATCH) break;
-                } else {
-                    if (len >= zip_nice_match) break;
-                }
-
-                scan_end1 = zip_window[scanp + best_len - 1];
-                scan_end = zip_window[scanp + best_len];
-            }
-        } while ((cur_match = zip_prev[cur_match & zip_WMASK]) > limit
-            && --chain_length != 0);
-
-        return best_len;
-    };
-
-    /* ==========================================================================
-     * Fill the window when the lookahead becomes insufficient.
-     * Updates strstart and lookahead, and sets eofile if end of input file.
-     * IN assertion: lookahead < MIN_LOOKAHEAD && strstart + lookahead > 0
-     * OUT assertions: at least one byte has been read, or eofile is set;
-     *    file reads are performed for at least two bytes (required for the
-     *    translate_eol option).
-     */
-    var zip_fill_window = function () {
-        var n, m;
-
-        // Amount of free space at the end of the window.
-        var more = zip_window_size - zip_lookahead - zip_strstart;
-
-        /* If the window is almost full and there is insufficient lookahead,
-         * move the upper half to the lower one to make room in the upper half.
-         */
-        if (more == -1) {
-            /* Very unlikely, but possible on 16 bit machine if strstart == 0
-             * and lookahead == 1 (input done one byte at time)
-             */
-            more--;
-        } else if (zip_strstart >= WSIZE + zip_MAX_DIST) {
-            /* By the IN assertion, the window is not empty so we can't confuse
-             * more == 0 with more == 64K on a 16 bit machine.
-             */
-            for (n = 0; n < WSIZE; n++)
-                zip_window[n] = zip_window[n + WSIZE];
-
-            zip_match_start -= WSIZE;
-            zip_strstart -= WSIZE;
-            /* we now have strstart >= MAX_DIST: */
-            zip_block_start -= WSIZE;
-
-            for (n = 0; n < zip_HASH_SIZE; n++) {
-                m = zip_head1(n);
-                zip_head2(n, m >= WSIZE ? m - WSIZE : zip_NIL);
-            }
-            for (n = 0; n < WSIZE; n++) {
-                /* If n is not on any hash chain, prev[n] is garbage but
-                 * its value will never be used.
-                 */
-                m = zip_prev[n];
-                zip_prev[n] = (m >= WSIZE ? m - WSIZE : zip_NIL);
-            }
-            more += WSIZE;
-        }
-        // At this point, more >= 2
-        if (!zip_eofile) {
-            n = zip_read_buff(zip_window, zip_strstart + zip_lookahead, more);
-            if (n <= 0)
-                zip_eofile = true;
-            else
-                zip_lookahead += n;
-        }
-    };
-
-    /* ==========================================================================
-     * Processes a new input file and return its compressed length. This
-     * function does not perform lazy evaluationof matches and inserts
-     * new strings in the dictionary only for unmatched strings or for short
-     * matches. It is used only for the fast compression options.
-     */
-    var zip_deflate_fast = function () {
-        while (zip_lookahead != 0 && zip_qhead == null) {
-            var flush; // set if current block must be flushed
-
-            /* Insert the string window[strstart .. strstart+2] in the
-             * dictionary, and set hash_head to the head of the hash chain:
-             */
-            zip_INSERT_STRING();
-
-            /* Find the longest match, discarding those <= prev_length.
-             * At this point we have always match_length < MIN_MATCH
-             */
-            if (zip_hash_head != zip_NIL &&
-                zip_strstart - zip_hash_head <= zip_MAX_DIST) {
-                /* To simplify the code, we prevent matches with the string
-                 * of window index 0 (in particular we have to avoid a match
-                 * of the string with itself at the start of the input file).
-                 */
-                zip_match_length = zip_longest_match(zip_hash_head);
-                /* longest_match() sets match_start */
-                if (zip_match_length > zip_lookahead)
-                    zip_match_length = zip_lookahead;
-            }
-            if (zip_match_length >= MIN_MATCH) {
-                flush = zip_ct_tally(zip_strstart - zip_match_start,
-                    zip_match_length - MIN_MATCH);
-                zip_lookahead -= zip_match_length;
-
-                /* Insert new strings in the hash table only if the match length
-                 * is not too large. This saves time but degrades compression.
-                 */
-                if (zip_match_length <= zip_max_lazy_match) {
-                    zip_match_length--; // string at strstart already in hash table
-                    do {
-                        zip_strstart++;
-                        zip_INSERT_STRING();
-                        /* strstart never exceeds WSIZE-MAX_MATCH, so there are
-                         * always MIN_MATCH bytes ahead. If lookahead < MIN_MATCH
-                         * these bytes are garbage, but it does not matter since
-                         * the next lookahead bytes will be emitted as literals.
-                         */
-                    } while (--zip_match_length != 0);
-                    zip_strstart++;
-                } else {
-                    zip_strstart += zip_match_length;
-                    zip_match_length = 0;
-                    zip_ins_h = zip_window[zip_strstart] & 0xff;
-                    zip_ins_h = ((zip_ins_h << zip_H_SHIFT) ^ (zip_window[zip_strstart + 1] & 0xff)) & zip_HASH_MASK;
-                }
-            } else {
-                /* No match, output a literal byte */
-                flush = zip_ct_tally(0, zip_window[zip_strstart] & 0xff);
-                zip_lookahead--;
-                zip_strstart++;
-            }
-            if (flush) {
-                zip_flush_block(0);
-                zip_block_start = zip_strstart;
-            }
-
-            /* Make sure that we always have enough lookahead, except
-             * at the end of the input file. We need MAX_MATCH bytes
-             * for the next match, plus MIN_MATCH bytes to insert the
-             * string following the next match.
-             */
-            while (zip_lookahead < zip_MIN_LOOKAHEAD && !zip_eofile)
-                zip_fill_window();
-        }
-    };
-
-    var zip_deflate_better = function () {
-        /* Process the input block. */
-        while (zip_lookahead != 0 && zip_qhead == null) {
-            /* Insert the string window[strstart .. strstart+2] in the
-             * dictionary, and set hash_head to the head of the hash chain:
-             */
-            zip_INSERT_STRING();
-
-            /* Find the longest match, discarding those <= prev_length.
-             */
-            zip_prev_length = zip_match_length;
-            zip_prev_match = zip_match_start;
-            zip_match_length = MIN_MATCH - 1;
-
-            if (zip_hash_head != zip_NIL &&
-                zip_prev_length < zip_max_lazy_match &&
-                zip_strstart - zip_hash_head <= zip_MAX_DIST) {
-                /* To simplify the code, we prevent matches with the string
-                 * of window index 0 (in particular we have to avoid a match
-                 * of the string with itself at the start of the input file).
-                 */
-                zip_match_length = zip_longest_match(zip_hash_head);
-                /* longest_match() sets match_start */
-                if (zip_match_length > zip_lookahead)
-                    zip_match_length = zip_lookahead;
-
-                /* Ignore a length 3 match if it is too distant: */
-                if (zip_match_length == MIN_MATCH &&
-                    zip_strstart - zip_match_start > zip_TOO_FAR) {
-                    /* If prev_match is also MIN_MATCH, match_start is garbage
-                     * but we will ignore the current match anyway.
-                     */
-                    zip_match_length--;
-                }
-            }
-            /* If there was a match at the previous step and the current
-             * match is not better, output the previous match:
-             */
-            if (zip_prev_length >= MIN_MATCH &&
-                zip_match_length <= zip_prev_length) {
-                var flush; // set if current block must be flushed
-                flush = zip_ct_tally(zip_strstart - 1 - zip_prev_match,
-                    zip_prev_length - MIN_MATCH);
-
-                /* Insert in hash table all strings up to the end of the match.
-                 * strstart-1 and strstart are already inserted.
-                 */
-                zip_lookahead -= zip_prev_length - 1;
-                zip_prev_length -= 2;
-                do {
-                    zip_strstart++;
-                    zip_INSERT_STRING();
-                    /* strstart never exceeds WSIZE-MAX_MATCH, so there are
-                     * always MIN_MATCH bytes ahead. If lookahead < MIN_MATCH
-                     * these bytes are garbage, but it does not matter since the
-                     * next lookahead bytes will always be emitted as literals.
-                     */
-                } while (--zip_prev_length != 0);
-                zip_match_available = 0;
-                zip_match_length = MIN_MATCH - 1;
-                zip_strstart++;
-                if (flush) {
-                    zip_flush_block(0);
-                    zip_block_start = zip_strstart;
-                }
-            } else if (zip_match_available != 0) {
-                /* If there was no match at the previous position, output a
-                 * single literal. If there was a match but the current match
-                 * is longer, truncate the previous match to a single literal.
-                 */
-                if (zip_ct_tally(0, zip_window[zip_strstart - 1] & 0xff)) {
-                    zip_flush_block(0);
-                    zip_block_start = zip_strstart;
-                }
-                zip_strstart++;
-                zip_lookahead--;
-            } else {
-                /* There is no previous match to compare with, wait for
-                 * the next step to decide.
-                 */
-                zip_match_available = 1;
-                zip_strstart++;
-                zip_lookahead--;
-            }
-
-            /* Make sure that we always have enough lookahead, except
-             * at the end of the input file. We need MAX_MATCH bytes
-             * for the next match, plus MIN_MATCH bytes to insert the
-             * string following the next match.
-             */
-            while (zip_lookahead < zip_MIN_LOOKAHEAD && !zip_eofile)
-                zip_fill_window();
-        }
-    };
-
-    var zip_init_deflate = function () {
-        if (zip_eofile)
-            return;
-        zip_bi_buf = 0;
-        zip_bi_valid = 0;
-        zip_ct_init();
-        zip_lm_init();
-
-        zip_qhead = null;
-        zip_outcnt = 0;
-        zip_outoff = 0;
-        zip_match_available = 0;
-
-        if (zip_compr_level <= 3) {
-            zip_prev_length = MIN_MATCH - 1;
-            zip_match_length = 0;
-        }
-        else {
-            zip_match_length = MIN_MATCH - 1;
-            zip_match_available = 0;
-            zip_match_available = 0;
-        }
-
-        zip_complete = false;
-    };
-
-    /* ==========================================================================
-     * Same as above, but achieves better compression. We use a lazy
-     * evaluation for matches: a match is finally adopted only if there is
-     * no better match at the next window position.
-     */
-    var zip_deflate_internal = function (buff, off, buff_size) {
-        var n;
-
-        if (!zip_initflag) {
-            zip_init_deflate();
-            zip_initflag = true;
-            if (zip_lookahead == 0) { // empty
-                zip_complete = true;
-                return 0;
-            }
-        }
-
-        if ((n = zip_qcopy(buff, off, buff_size)) == buff_size)
-            return buff_size;
-
-        if (zip_complete)
-            return n;
-
-        if (zip_compr_level <= 3) // optimized for speed
-            zip_deflate_fast();
-        else
-            zip_deflate_better();
-        if (zip_lookahead == 0) {
-            if (zip_match_available != 0)
-                zip_ct_tally(0, zip_window[zip_strstart - 1] & 0xff);
-            zip_flush_block(1);
-            zip_complete = true;
-        }
-        return n + zip_qcopy(buff, n + off, buff_size - n);
-    };
-
-    var zip_qcopy = function (buff, off, buff_size) {
-        var n, i, j;
-
-        n = 0;
-        while (zip_qhead != null && n < buff_size) {
-            i = buff_size - n;
-            if (i > zip_qhead.len)
-                i = zip_qhead.len;
-            for (j = 0; j < i; j++)
-                buff[off + n + j] = zip_qhead.ptr[zip_qhead.off + j];
-
-            zip_qhead.off += i;
-            zip_qhead.len -= i;
-            n += i;
-            if (zip_qhead.len == 0) {
-                var p;
-                p = zip_qhead;
-                zip_qhead = zip_qhead.next;
-                zip_reuse_queue(p);
-            }
-        }
-
-        if (n == buff_size)
-            return n;
-
-        if (zip_outoff < zip_outcnt) {
-            i = buff_size - n;
-            if (i > zip_outcnt - zip_outoff)
-                i = zip_outcnt - zip_outoff;
-            // System.arraycopy(outbuf, outoff, buff, off + n, i);
-            for (j = 0; j < i; j++)
-                buff[off + n + j] = zip_outbuf[zip_outoff + j];
-            zip_outoff += i;
-            n += i;
-            if (zip_outcnt == zip_outoff)
-                zip_outcnt = zip_outoff = 0;
-        }
-        return n;
-    };
-
-    /* ==========================================================================
-     * Allocate the match buffer, initialize the various tables and save the
-     * location of the internal file attribute (ascii/binary) and method
-     * (DEFLATE/STORE).
-     */
-    var zip_ct_init = function () {
-        var n;	// iterates over tree elements
-        var bits;	// bit counter
-        var length;	// length value
-        var code;	// code value
-        var dist;	// distance index
-
-        if (zip_static_dtree[0].dl != 0) return; // ct_init already called
-
-        zip_l_desc.dyn_tree = zip_dyn_ltree;
-        zip_l_desc.static_tree = zip_static_ltree;
-        zip_l_desc.extra_bits = zip_extra_lbits;
-        zip_l_desc.extra_base = zip_LITERALS + 1;
-        zip_l_desc.elems = zip_L_CODES;
-        zip_l_desc.max_length = zip_MAX_BITS;
-        zip_l_desc.max_code = 0;
-
-        zip_d_desc.dyn_tree = zip_dyn_dtree;
-        zip_d_desc.static_tree = zip_static_dtree;
-        zip_d_desc.extra_bits = zip_extra_dbits;
-        zip_d_desc.extra_base = 0;
-        zip_d_desc.elems = zip_D_CODES;
-        zip_d_desc.max_length = zip_MAX_BITS;
-        zip_d_desc.max_code = 0;
-
-        zip_bl_desc.dyn_tree = zip_bl_tree;
-        zip_bl_desc.static_tree = null;
-        zip_bl_desc.extra_bits = zip_extra_blbits;
-        zip_bl_desc.extra_base = 0;
-        zip_bl_desc.elems = zip_BL_CODES;
-        zip_bl_desc.max_length = zip_MAX_BL_BITS;
-        zip_bl_desc.max_code = 0;
-
-        // Initialize the mapping length (0..255) -> length code (0..28)
-        length = 0;
-        for (code = 0; code < zip_LENGTH_CODES - 1; code++) {
-            zip_base_length[code] = length;
-            for (n = 0; n < (1 << zip_extra_lbits[code]); n++)
-                zip_length_code[length++] = code;
-        }
-        /* Note that the length 255 (match length 258) can be represented
-         * in two different ways: code 284 + 5 bits or code 285, so we
-         * overwrite length_code[255] to use the best encoding:
-         */
-        zip_length_code[length - 1] = code;
-
-        /* Initialize the mapping dist (0..32K) -> dist code (0..29) */
-        dist = 0;
-        for (code = 0; code < 16; code++) {
-            zip_base_dist[code] = dist;
-            for (n = 0; n < (1 << zip_extra_dbits[code]); n++) {
-                zip_dist_code[dist++] = code;
-            }
-        }
-        dist >>= 7; // from now on, all distances are divided by 128
-        for (; code < zip_D_CODES; code++) {
-            zip_base_dist[code] = dist << 7;
-            for (n = 0; n < (1 << (zip_extra_dbits[code] - 7)); n++)
-                zip_dist_code[256 + dist++] = code;
-        }
-        // Construct the codes of the static literal tree
-        for (bits = 0; bits <= zip_MAX_BITS; bits++)
-            zip_bl_count[bits] = 0;
-        n = 0;
-        while (n <= 143) {
-            zip_static_ltree[n++].dl = 8;
-            zip_bl_count[8]++;
-        }
-        while (n <= 255) {
-            zip_static_ltree[n++].dl = 9;
-            zip_bl_count[9]++;
-        }
-        while (n <= 279) {
-            zip_static_ltree[n++].dl = 7;
-            zip_bl_count[7]++;
-        }
-        while (n <= 287) {
-            zip_static_ltree[n++].dl = 8;
-            zip_bl_count[8]++;
-        }
-        /* Codes 286 and 287 do not exist, but we must include them in the
-         * tree construction to get a canonical Huffman tree (longest code
-         * all ones)
-         */
-        zip_gen_codes(zip_static_ltree, zip_L_CODES + 1);
-
-        /* The static distance tree is trivial: */
-        for (n = 0; n < zip_D_CODES; n++) {
-            zip_static_dtree[n].dl = 5;
-            zip_static_dtree[n].fc = zip_bi_reverse(n, 5);
-        }
-
-        // Initialize the first block of the first file:
-        zip_init_block();
-    };
-
-    /* ==========================================================================
-     * Initialize a new block.
-     */
-    var zip_init_block = function () {
-        var n; // iterates over tree elements
-
-        // Initialize the trees.
-        for (n = 0; n < zip_L_CODES; n++) zip_dyn_ltree[n].fc = 0;
-        for (n = 0; n < zip_D_CODES; n++) zip_dyn_dtree[n].fc = 0;
-        for (n = 0; n < zip_BL_CODES; n++) zip_bl_tree[n].fc = 0;
-
-        zip_dyn_ltree[zip_END_BLOCK].fc = 1;
-        zip_opt_len = zip_static_len = 0;
-        zip_last_lit = zip_last_dist = zip_last_flags = 0;
-        zip_flags = 0;
-        zip_flag_bit = 1;
-    };
-
-    /* ==========================================================================
-     * Restore the heap property by moving down the tree starting at node k,
-     * exchanging a node with the smallest of its two sons if necessary, stopping
-     * when the heap property is re-established (each father smaller than its
-     * two sons).
-     */
-    var zip_pqdownheap = function (tree,	// the tree to restore
-                                   k) {	// node to move down
-        var v = zip_heap[k];
-        var j = k << 1;	// left son of k
-
-        while (j <= zip_heap_len) {
-            // Set j to the smallest of the two sons:
-            if (j < zip_heap_len &&
-                zip_SMALLER(tree, zip_heap[j + 1], zip_heap[j]))
-                j++;
-
-            // Exit if v is smaller than both sons
-            if (zip_SMALLER(tree, v, zip_heap[j]))
-                break;
-
-            // Exchange v with the smallest son
-            zip_heap[k] = zip_heap[j];
-            k = j;
-
-            // And continue down the tree, setting j to the left son of k
-            j <<= 1;
-        }
-        zip_heap[k] = v;
-    };
-
-    /* ==========================================================================
-     * Compute the optimal bit lengths for a tree and update the total bit length
-     * for the current block.
-     * IN assertion: the fields freq and dad are set, heap[heap_max] and
-     *    above are the tree nodes sorted by increasing frequency.
-     * OUT assertions: the field len is set to the optimal bit length, the
-     *     array bl_count contains the frequencies for each bit length.
-     *     The length opt_len is updated; static_len is also updated if stree is
-     *     not null.
-     */
-    var zip_gen_bitlen = function (desc) { // the tree descriptor
-        var tree = desc.dyn_tree;
-        var extra = desc.extra_bits;
-        var base = desc.extra_base;
-        var max_code = desc.max_code;
-        var max_length = desc.max_length;
-        var stree = desc.static_tree;
-        var h;		// heap index
-        var n, m;		// iterate over the tree elements
-        var bits;		// bit length
-        var xbits;		// extra bits
-        var f;		// frequency
-        var overflow = 0;	// number of elements with bit length too large
-
-        for (bits = 0; bits <= zip_MAX_BITS; bits++)
-            zip_bl_count[bits] = 0;
-
-        /* In a first pass, compute the optimal bit lengths (which may
-         * overflow in the case of the bit length tree).
-         */
-        tree[zip_heap[zip_heap_max]].dl = 0; // root of the heap
-
-        for (h = zip_heap_max + 1; h < zip_HEAP_SIZE; h++) {
-            n = zip_heap[h];
-            bits = tree[tree[n].dl].dl + 1;
-            if (bits > max_length) {
-                bits = max_length;
-                overflow++;
-            }
-            tree[n].dl = bits;
-            // We overwrite tree[n].dl which is no longer needed
-
-            if (n > max_code)
-                continue; // not a leaf node
-
-            zip_bl_count[bits]++;
-            xbits = 0;
-            if (n >= base)
-                xbits = extra[n - base];
-            f = tree[n].fc;
-            zip_opt_len += f * (bits + xbits);
-            if (stree != null)
-                zip_static_len += f * (stree[n].dl + xbits);
-        }
-        if (overflow == 0)
-            return;
-
-        // This happens for example on obj2 and pic of the Calgary corpus
-
-        // Find the first bit length which could increase:
-        do {
-            bits = max_length - 1;
-            while (zip_bl_count[bits] == 0)
-                bits--;
-            zip_bl_count[bits]--;		// move one leaf down the tree
-            zip_bl_count[bits + 1] += 2;	// move one overflow item as its brother
-            zip_bl_count[max_length]--;
-            /* The brother of the overflow item also moves one step up,
-             * but this does not affect bl_count[max_length]
-             */
-            overflow -= 2;
-        } while (overflow > 0);
-
-        /* Now recompute all bit lengths, scanning in increasing frequency.
-         * h is still equal to HEAP_SIZE. (It is simpler to reconstruct all
-         * lengths instead of fixing only the wrong ones. This idea is taken
-         * from 'ar' written by Haruhiko Okumura.)
-         */
-        for (bits = max_length; bits != 0; bits--) {
-            n = zip_bl_count[bits];
-            while (n != 0) {
-                m = zip_heap[--h];
-                if (m > max_code)
-                    continue;
-                if (tree[m].dl != bits) {
-                    zip_opt_len += (bits - tree[m].dl) * tree[m].fc;
-                    tree[m].fc = bits;
-                }
-                n--;
-            }
-        }
-    };
-
-    /* ==========================================================================
-     * Generate the codes for a given tree and bit counts (which need not be
-     * optimal).
-     * IN assertion: the array bl_count contains the bit length statistics for
-     * the given tree and the field len is set for all tree elements.
-     * OUT assertion: the field code is set for all tree elements of non
-     *     zero code length.
-     */
-    var zip_gen_codes = function (tree,	// the tree to decorate
-                                  max_code) {	// largest code with non zero frequency
-        var next_code = new Array(zip_MAX_BITS + 1); // next code value for each bit length
-        var code = 0;		// running code value
-        var bits;			// bit index
-        var n;			// code index
-
-        /* The distribution counts are first used to generate the code values
-         * without bit reversal.
-         */
-        for (bits = 1; bits <= zip_MAX_BITS; bits++) {
-            code = ((code + zip_bl_count[bits - 1]) << 1);
-            next_code[bits] = code;
-        }
-
-        /* Check that the bit counts in bl_count are consistent. The last code
-         * must be all ones.
-         */
-        for (n = 0; n <= max_code; n++) {
-            var len = tree[n].dl;
-            if (len == 0)
-                continue;
-            // Now reverse the bits
-            tree[n].fc = zip_bi_reverse(next_code[len]++, len);
-        }
-    };
-
-    /* ==========================================================================
-     * Construct one Huffman tree and assigns the code bit strings and lengths.
-     * Update the total bit length for the current block.
-     * IN assertion: the field freq is set for all tree elements.
-     * OUT assertions: the fields len and code are set to the optimal bit length
-     *     and corresponding code. The length opt_len is updated; static_len is
-     *     also updated if stree is not null. The field max_code is set.
-     */
-    var zip_build_tree = function (desc) { // the tree descriptor
-        var tree = desc.dyn_tree;
-        var stree = desc.static_tree;
-        var elems = desc.elems;
-        var n, m;		// iterate over heap elements
-        var max_code = -1;	// largest code with non zero frequency
-        var node = elems;	// next internal node of the tree
-
-        /* Construct the initial heap, with least frequent element in
-         * heap[SMALLEST]. The sons of heap[n] are heap[2*n] and heap[2*n+1].
-         * heap[0] is not used.
-         */
-        zip_heap_len = 0;
-        zip_heap_max = zip_HEAP_SIZE;
-
-        for (n = 0; n < elems; n++) {
-            if (tree[n].fc != 0) {
-                zip_heap[++zip_heap_len] = max_code = n;
-                zip_depth[n] = 0;
-            } else
-                tree[n].dl = 0;
-        }
-
-        /* The pkzip format requires that at least one distance code exists,
-         * and that at least one bit should be sent even if there is only one
-         * possible code. So to avoid special checks later on we force at least
-         * two codes of non zero frequency.
-         */
-        while (zip_heap_len < 2) {
-            var xnew = zip_heap[++zip_heap_len] = (max_code < 2 ? ++max_code : 0);
-            tree[xnew].fc = 1;
-            zip_depth[xnew] = 0;
-            zip_opt_len--;
-            if (stree != null)
-                zip_static_len -= stree[xnew].dl;
-            // new is 0 or 1 so it does not have extra bits
-        }
-        desc.max_code = max_code;
-
-        /* The elements heap[heap_len/2+1 .. heap_len] are leaves of the tree,
-         * establish sub-heaps of increasing lengths:
-         */
-        for (n = zip_heap_len >> 1; n >= 1; n--)
-            zip_pqdownheap(tree, n);
-
-        /* Construct the Huffman tree by repeatedly combining the least two
-         * frequent nodes.
-         */
-        do {
-            n = zip_heap[zip_SMALLEST];
-            zip_heap[zip_SMALLEST] = zip_heap[zip_heap_len--];
-            zip_pqdownheap(tree, zip_SMALLEST);
-
-            m = zip_heap[zip_SMALLEST];  // m = node of next least frequency
-
-            // keep the nodes sorted by frequency
-            zip_heap[--zip_heap_max] = n;
-            zip_heap[--zip_heap_max] = m;
-
-            // Create a new node father of n and m
-            tree[node].fc = tree[n].fc + tree[m].fc;
-            if (zip_depth[n] > zip_depth[m] + 1)
-                zip_depth[node] = zip_depth[n];
-            else
-                zip_depth[node] = zip_depth[m] + 1;
-            tree[n].dl = tree[m].dl = node;
-
-            // and insert the new node in the heap
-            zip_heap[zip_SMALLEST] = node++;
-            zip_pqdownheap(tree, zip_SMALLEST);
-
-        } while (zip_heap_len >= 2);
-
-        zip_heap[--zip_heap_max] = zip_heap[zip_SMALLEST];
-
-        /* At this point, the fields freq and dad are set. We can now
-         * generate the bit lengths.
-         */
-        zip_gen_bitlen(desc);
-
-        // The field len is now set, we can generate the bit codes
-        zip_gen_codes(tree, max_code);
-    };
-
-    /* ==========================================================================
-     * Scan a literal or distance tree to determine the frequencies of the codes
-     * in the bit length tree. Updates opt_len to take into account the repeat
-     * counts. (The contribution of the bit length codes will be added later
-     * during the construction of bl_tree.)
-     */
-    var zip_scan_tree = function (tree,// the tree to be scanned
-                                  max_code) {  // and its largest code of non zero frequency
-        var n;			// iterates over all tree elements
-        var prevlen = -1;		// last emitted length
-        var curlen;			// length of current code
-        var nextlen = tree[0].dl;	// length of next code
-        var count = 0;		// repeat count of the current code
-        var max_count = 7;		// max repeat count
-        var min_count = 4;		// min repeat count
-
-        if (nextlen == 0) {
-            max_count = 138;
-            min_count = 3;
-        }
-        tree[max_code + 1].dl = 0xffff; // guard
-
-        for (n = 0; n <= max_code; n++) {
-            curlen = nextlen;
-            nextlen = tree[n + 1].dl;
-            if (++count < max_count && curlen == nextlen)
-                continue;
-            else if (count < min_count)
-                zip_bl_tree[curlen].fc += count;
-            else if (curlen != 0) {
-                if (curlen != prevlen)
-                    zip_bl_tree[curlen].fc++;
-                zip_bl_tree[zip_REP_3_6].fc++;
-            } else if (count <= 10)
-                zip_bl_tree[zip_REPZ_3_10].fc++;
-            else
-                zip_bl_tree[zip_REPZ_11_138].fc++;
-            count = 0;
-            prevlen = curlen;
-            if (nextlen == 0) {
-                max_count = 138;
-                min_count = 3;
-            } else if (curlen == nextlen) {
-                max_count = 6;
-                min_count = 3;
-            } else {
-                max_count = 7;
-                min_count = 4;
-            }
-        }
-    };
-
-    /* ==========================================================================
-     * Send a literal or distance tree in compressed form, using the codes in
-     * bl_tree.
-     */
-    var zip_send_tree = function (tree, // the tree to be scanned
-                                  max_code) { // and its largest code of non zero frequency
-        var n;			// iterates over all tree elements
-        var prevlen = -1;		// last emitted length
-        var curlen;			// length of current code
-        var nextlen = tree[0].dl;	// length of next code
-        var count = 0;		// repeat count of the current code
-        var max_count = 7;		// max repeat count
-        var min_count = 4;		// min repeat count
-
-        /* tree[max_code+1].dl = -1; */
-        /* guard already set */
-        if (nextlen == 0) {
-            max_count = 138;
-            min_count = 3;
-        }
-
-        for (n = 0; n <= max_code; n++) {
-            curlen = nextlen;
-            nextlen = tree[n + 1].dl;
-            if (++count < max_count && curlen == nextlen) {
-                continue;
-            } else if (count < min_count) {
-                do {
-                    zip_SEND_CODE(curlen, zip_bl_tree);
-                } while (--count != 0);
-            } else if (curlen != 0) {
-                if (curlen != prevlen) {
-                    zip_SEND_CODE(curlen, zip_bl_tree);
-                    count--;
-                }
-                // Assert(count >= 3 && count <= 6, " 3_6?");
-                zip_SEND_CODE(zip_REP_3_6, zip_bl_tree);
-                zip_send_bits(count - 3, 2);
-            } else if (count <= 10) {
-                zip_SEND_CODE(zip_REPZ_3_10, zip_bl_tree);
-                zip_send_bits(count - 3, 3);
-            } else {
-                zip_SEND_CODE(zip_REPZ_11_138, zip_bl_tree);
-                zip_send_bits(count - 11, 7);
-            }
-            count = 0;
-            prevlen = curlen;
-            if (nextlen == 0) {
-                max_count = 138;
-                min_count = 3;
-            } else if (curlen == nextlen) {
-                max_count = 6;
-                min_count = 3;
-            } else {
-                max_count = 7;
-                min_count = 4;
-            }
-        }
-    };
-
-    /* ==========================================================================
-     * Construct the Huffman tree for the bit lengths and return the index in
-     * bl_order of the last bit length code to send.
-     */
-    var zip_build_bl_tree = function () {
-        var max_blindex;  // index of last bit length code of non zero freq
-
-        // Determine the bit length frequencies for literal and distance trees
-        zip_scan_tree(zip_dyn_ltree, zip_l_desc.max_code);
-        zip_scan_tree(zip_dyn_dtree, zip_d_desc.max_code);
-
-        // Build the bit length tree:
-        zip_build_tree(zip_bl_desc);
-        /* opt_len now includes the length of the tree representations, except
-         * the lengths of the bit lengths codes and the 5+5+4 bits for the counts.
-         */
-
-        /* Determine the number of bit length codes to send. The pkzip format
-         * requires that at least 4 bit length codes be sent. (appnote.txt says
-         * 3 but the actual value used is 4.)
-         */
-        for (max_blindex = zip_BL_CODES - 1; max_blindex >= 3; max_blindex--) {
-            if (zip_bl_tree[zip_bl_order[max_blindex]].dl != 0) break;
-        }
-        /* Update opt_len to include the bit length tree and counts */
-        zip_opt_len += 3 * (max_blindex + 1) + 5 + 5 + 4;
-        return max_blindex;
-    };
-
-    /* ==========================================================================
-     * Send the header for a block using dynamic Huffman trees: the counts, the
-     * lengths of the bit length codes, the literal tree and the distance tree.
-     * IN assertion: lcodes >= 257, dcodes >= 1, blcodes >= 4.
-     */
-    var zip_send_all_trees = function (lcodes, dcodes, blcodes) { // number of codes for each tree
-        var rank; // index in bl_order
-        zip_send_bits(lcodes - 257, 5); // not +255 as stated in appnote.txt
-        zip_send_bits(dcodes - 1, 5);
-        zip_send_bits(blcodes - 4, 4); // not -3 as stated in appnote.txt
-        for (rank = 0; rank < blcodes; rank++) {
-            zip_send_bits(zip_bl_tree[zip_bl_order[rank]].dl, 3);
-        }
-
-        // send the literal tree
-        zip_send_tree(zip_dyn_ltree, lcodes - 1);
-
-        // send the distance tree
-        zip_send_tree(zip_dyn_dtree, dcodes - 1);
-    };
-
-    /* ==========================================================================
-     * Determine the best encoding for the current block: dynamic trees, static
-     * trees or store, and output the encoded block to the zip file.
-     */
-    var zip_flush_block = function (eof) { // true if this is the last block for a file
-        var opt_lenb, static_lenb; // opt_len and static_len in bytes
-        var max_blindex;	// index of last bit length code of non zero freq
-        var stored_len;	// length of input block
-
-        stored_len = zip_strstart - zip_block_start;
-        zip_flag_buf[zip_last_flags] = zip_flags; // Save the flags for the last 8 items
-
-        // Construct the literal and distance trees
-        zip_build_tree(zip_l_desc);
-        zip_build_tree(zip_d_desc);
-        /* At this point, opt_len and static_len are the total bit lengths of
-         * the compressed block data, excluding the tree representations.
-         */
-
-        /* Build the bit length tree for the above two trees, and get the index
-         * in bl_order of the last bit length code to send.
-         */
-        max_blindex = zip_build_bl_tree();
-
-        // Determine the best encoding. Compute first the block length in bytes
-        opt_lenb = (zip_opt_len + 3 + 7) >> 3;
-        static_lenb = (zip_static_len + 3 + 7) >> 3;
-        if (static_lenb <= opt_lenb)
-            opt_lenb = static_lenb;
-        if (stored_len + 4 <= opt_lenb // 4: two words for the lengths
-            && zip_block_start >= 0) {
-            var i;
-
-            /* The test buf != NULL is only necessary if LIT_BUFSIZE > WSIZE.
-             * Otherwise we can't have processed more than WSIZE input bytes since
-             * the last block flush, because compression would have been
-             * successful. If LIT_BUFSIZE <= WSIZE, it is never too late to
-             * transform a block into a stored block.
-             */
-            zip_send_bits((zip_STORED_BLOCK << 1) + eof, 3);
-            /* send block type */
-            zip_bi_windup();
-            /* align on byte boundary */
-            zip_put_short(stored_len);
-            zip_put_short(~stored_len);
-
-            // copy block
-            for (i = 0; i < stored_len; i++)
-                zip_put_byte(zip_window[zip_block_start + i]);
-
-        } else if (static_lenb == opt_lenb) {
-            zip_send_bits((zip_STATIC_TREES << 1) + eof, 3);
-            zip_compress_block(zip_static_ltree, zip_static_dtree);
-        } else {
-            zip_send_bits((zip_DYN_TREES << 1) + eof, 3);
-            zip_send_all_trees(zip_l_desc.max_code + 1,
-                zip_d_desc.max_code + 1,
-                max_blindex + 1);
-            zip_compress_block(zip_dyn_ltree, zip_dyn_dtree);
-        }
-
-        zip_init_block();
-
-        if (eof != 0)
-            zip_bi_windup();
-    };
-
-    /* ==========================================================================
-     * Save the match info and tally the frequency counts. Return true if
-     * the current block must be flushed.
-     */
-    var zip_ct_tally = function (dist, // distance of matched string
-                                 lc) { // match length-MIN_MATCH or unmatched char (if dist==0)
-        zip_l_buf[zip_last_lit++] = lc;
-        if (dist == 0) {
-            // lc is the unmatched char
-            zip_dyn_ltree[lc].fc++;
-        } else {
-            // Here, lc is the match length - MIN_MATCH
-            dist--;		    // dist = match distance - 1
-            zip_dyn_ltree[zip_length_code[lc] + zip_LITERALS + 1].fc++;
-            zip_dyn_dtree[zip_D_CODE(dist)].fc++;
-
-            zip_d_buf[zip_last_dist++] = dist;
-            zip_flags |= zip_flag_bit;
-        }
-        zip_flag_bit <<= 1;
-
-        // Output the flags if they fill a byte
-        if ((zip_last_lit & 7) == 0) {
-            zip_flag_buf[zip_last_flags++] = zip_flags;
-            zip_flags = 0;
-            zip_flag_bit = 1;
-        }
-        // Try to guess if it is profitable to stop the current block here
-        if (zip_compr_level > 2 && (zip_last_lit & 0xfff) == 0) {
-            // Compute an upper bound for the compressed length
-            var out_length = zip_last_lit * 8;
-            var in_length = zip_strstart - zip_block_start;
-            var dcode;
-
-            for (dcode = 0; dcode < zip_D_CODES; dcode++) {
-                out_length += zip_dyn_dtree[dcode].fc * (5 + zip_extra_dbits[dcode]);
-            }
-            out_length >>= 3;
-            if (zip_last_dist < parseInt(zip_last_lit / 2) &&
-                out_length < parseInt(in_length / 2))
-                return true;
-        }
-        return (zip_last_lit == LIT_BUFSIZE - 1 ||
-            zip_last_dist == zip_DIST_BUFSIZE);
-        /* We avoid equality with LIT_BUFSIZE because of wraparound at 64K
-         * on 16 bit machines and because stored blocks are restricted to
-         * 64K-1 bytes.
-         */
-    };
-
-    /* ==========================================================================
-     * Send the block data compressed using the given Huffman trees
-     */
-    var zip_compress_block = function (ltree,	// literal tree
-                                       dtree) {	// distance tree
-        var dist;		// distance of matched string
-        var lc;		// match length or unmatched char (if dist == 0)
-        var lx = 0;		// running index in l_buf
-        var dx = 0;		// running index in d_buf
-        var fx = 0;		// running index in flag_buf
-        var flag = 0;	// current flags
-        var code;		// the code to send
-        var extra;		// number of extra bits to send
-
-        if (zip_last_lit != 0) do {
-            if ((lx & 7) == 0)
-                flag = zip_flag_buf[fx++];
-            lc = zip_l_buf[lx++] & 0xff;
-            if ((flag & 1) == 0) {
-                zip_SEND_CODE(lc, ltree);
-                /* send a literal byte */
-            } else {
-                // Here, lc is the match length - MIN_MATCH
-                code = zip_length_code[lc];
-                zip_SEND_CODE(code + zip_LITERALS + 1, ltree); // send the length code
-                extra = zip_extra_lbits[code];
-                if (extra != 0) {
-                    lc -= zip_base_length[code];
-                    zip_send_bits(lc, extra); // send the extra length bits
-                }
-                dist = zip_d_buf[dx++];
-                // Here, dist is the match distance - 1
-                code = zip_D_CODE(dist);
-                zip_SEND_CODE(code, dtree);	  // send the distance code
-                extra = zip_extra_dbits[code];
-                if (extra != 0) {
-                    dist -= zip_base_dist[code];
-                    zip_send_bits(dist, extra);   // send the extra distance bits
-                }
-            } // literal or match pair ?
-            flag >>= 1;
-        } while (lx < zip_last_lit);
-
-        zip_SEND_CODE(zip_END_BLOCK, ltree);
-    };
-
-    /* ==========================================================================
-     * Send a value on a given number of bits.
-     * IN assertion: length <= 16 and value fits in length bits.
-     */
-    var zip_Buf_size = 16; // bit size of bi_buf
-    var zip_send_bits = function (value,	// value to send
-                                  length) {	// number of bits
-        /* If not enough room in bi_buf, use (valid) bits from bi_buf and
-         * (16 - bi_valid) bits from value, leaving (width - (16-bi_valid))
-         * unused bits in value.
-         */
-        if (zip_bi_valid > zip_Buf_size - length) {
-            zip_bi_buf |= (value << zip_bi_valid);
-            zip_put_short(zip_bi_buf);
-            zip_bi_buf = (value >> (zip_Buf_size - zip_bi_valid));
-            zip_bi_valid += length - zip_Buf_size;
-        } else {
-            zip_bi_buf |= value << zip_bi_valid;
-            zip_bi_valid += length;
-        }
-    };
-
-    /* ==========================================================================
-     * Reverse the first len bits of a code, using straightforward code (a faster
-     * method would use a table)
-     * IN assertion: 1 <= len <= 15
-     */
-    var zip_bi_reverse = function (code,	// the value to invert
-                                   len) {	// its bit length
-        var res = 0;
-        do {
-            res |= code & 1;
-            code >>= 1;
-            res <<= 1;
-        } while (--len > 0);
-        return res >> 1;
-    };
-
-    /* ==========================================================================
-     * Write out any remaining bits in an incomplete byte.
-     */
-    var zip_bi_windup = function () {
-        if (zip_bi_valid > 8) {
-            zip_put_short(zip_bi_buf);
-        } else if (zip_bi_valid > 0) {
-            zip_put_byte(zip_bi_buf);
-        }
-        zip_bi_buf = 0;
-        zip_bi_valid = 0;
-    };
-
-    var zip_qoutbuf = function () {
-        if (zip_outcnt != 0) {
-            var q, i;
-            q = zip_new_queue();
-            if (zip_qhead == null)
-                zip_qhead = zip_qtail = q;
-            else
-                zip_qtail = zip_qtail.next = q;
-            q.len = zip_outcnt - zip_outoff;
-            for (i = 0; i < q.len; i++)
-                q.ptr[i] = zip_outbuf[zip_outoff + i];
-            zip_outcnt = zip_outoff = 0;
-        }
-    };
-
-    function deflate(buffData, level) {
-        zip_deflate_data = buffData;
-        zip_deflate_pos = 0;
-        zip_deflate_start(level);
-
-        var buff = new Array(1024),
-            pages = [],
-            totalSize = 0,
-            i;
-
-        for (i = 0; i < 1024; i++) buff[i] = 0;
-        while ((i = zip_deflate_internal(buff, 0, buff.length)) > 0) {
-            var buf = new Buffer(buff.slice(0, i));
-            pages.push(buf);
-            totalSize += buf.length;
-        }
-
-        if (pages.length == 1) {
-            return pages[0];
-        }
-
-        var result = new Buffer(totalSize),
-            index = 0;
-
-        for (i = 0; i < pages.length; i++) {
-            pages[i].copy(result, index);
-            index = index + pages[i].length
-        }
-
-        return result;
-    }
-
-    return {
-        deflate: function () {
-            return deflate(inbuf, 8);
-        }
-    }
-}
-
-module.exports = function (/*Buffer*/inbuf) {
-
-    var zlib = require("zlib");
-
-    return {
-        deflate: function () {
-            return new JSDeflater(inbuf).deflate();
-        },
-
-        deflateAsync: function (/*Function*/callback) {
-            var tmp = zlib.createDeflateRaw({chunkSize:(parseInt(inbuf.length / 1024) + 1)*1024}),
-                parts = [], total = 0;
-            tmp.on('data', function(data) {
-                parts.push(data);
-                total += data.length;
-            });
-            tmp.on('end', function() {
-                var buf = new Buffer(total), written = 0;
-                buf.fill(0);
-
-                for (var i = 0; i < parts.length; i++) {
-                    var part = parts[i];
-                    part.copy(buf, written);
-                    written += part.length;
-                }
-                callback && callback(buf);
-            });
-            tmp.end(inbuf);
-        }
-    }
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/index.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/index.js
deleted file mode 100644
index 58c718d..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/index.js
+++ /dev/null
@@ -1,2 +0,0 @@
-exports.Deflater = require("./deflater");
-exports.Inflater = require("./inflater");
\ No newline at end of file
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/inflater.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/inflater.js
deleted file mode 100644
index 3739d98..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/methods/inflater.js
+++ /dev/null
@@ -1,448 +0,0 @@
-var Buffer = require("buffer").Buffer;
-
-function JSInflater(/*Buffer*/input) {
-
-    var WSIZE = 0x8000,
-        slide = new Buffer(0x10000),
-        windowPos = 0,
-        fixedTableList = null,
-        fixedTableDist,
-        fixedLookup,
-        bitBuf = 0,
-        bitLen = 0,
-        method = -1,
-        eof = false,
-        copyLen = 0,
-        copyDist = 0,
-        tblList, tblDist, bitList, bitdist,
-
-        inputPosition = 0,
-
-        MASK_BITS = [0x0000, 0x0001, 0x0003, 0x0007, 0x000f, 0x001f, 0x003f, 0x007f, 0x00ff, 0x01ff, 0x03ff, 0x07ff, 0x0fff, 0x1fff, 0x3fff, 0x7fff, 0xffff],
-        LENS = [3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 15, 17, 19, 23, 27, 31, 35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0, 0],
-        LEXT = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0, 99, 99],
-        DISTS = [1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145, 8193, 12289, 16385, 24577],
-        DEXT = [0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13],
-        BITORDER = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];
-
-    function HuffTable(clen, cnum, cval, blist, elist, lookupm) {
-
-        this.status = 0;
-        this.root = null;
-        this.maxbit = 0;
-
-        var el, f, tail,
-            offsets = [],
-            countTbl = [],
-            sTbl = [],
-            values = [],
-            tentry = {extra: 0, bitcnt: 0, lbase: 0, next: null};
-
-        tail = this.root = null;
-        for(var i = 0; i < 0x11; i++)  { countTbl[i] = 0; sTbl[i] = 0; offsets[i] = 0; }
-        for(i = 0; i < 0x120; i++) values[i] = 0;
-
-        el = cnum > 256 ? clen[256] : 16;
-
-        var pidx = -1;
-        while (++pidx < cnum) countTbl[clen[pidx]]++;
-
-        if(countTbl[0] == cnum) return;
-
-        for(var j = 1; j <= 16; j++) if(countTbl[j] != 0) break;
-        var bitLen = j;
-        for(i = 16; i != 0; i--) if(countTbl[i] != 0) break;
-        var maxLen = i;
-
-        lookupm < j && (lookupm = j);
-
-        var dCodes = 1 << j;
-        for(; j < i; j++, dCodes <<= 1)
-            if((dCodes -= countTbl[j]) < 0) {
-                this.status = 2;
-                this.maxbit = lookupm;
-                return;
-            }
-
-        if((dCodes -= countTbl[i]) < 0) {
-            this.status = 2;
-            this.maxbit = lookupm;
-            return;
-        }
-
-        countTbl[i] += dCodes;
-        offsets[1] = j = 0;
-        pidx = 1;
-        var xp = 2;
-        while(--i > 0) offsets[xp++] = (j += countTbl[pidx++]);
-        pidx = 0;
-        i = 0;
-        do {
-            (j = clen[pidx++]) && (values[offsets[j]++] = i);
-        } while(++i < cnum);
-        cnum = offsets[maxLen];
-        offsets[0] = i = 0;
-        pidx = 0;
-
-        var level = -1,
-            w = sTbl[0] = 0,
-            cnode = null,
-            tblCnt = 0,
-            tblStack = [];
-
-        for(; bitLen <= maxLen; bitLen++) {
-            var kccnt = countTbl[bitLen];
-            while(kccnt-- > 0) {
-                while(bitLen > w + sTbl[1 + level]) {
-                    w += sTbl[1 + level];
-                    level++;
-                    tblCnt = (tblCnt = maxLen - w) > lookupm ? lookupm : tblCnt;
-                    if((f = 1 << (j = bitLen - w)) > kccnt + 1) {
-                        f -= kccnt + 1;
-                        xp = bitLen;
-                        while(++j < tblCnt) {
-                            if((f <<= 1) <= countTbl[++xp]) break;
-                            f -= countTbl[xp];
-                        }
-                    }
-                    if(w + j > el && w < el) j = el - w;
-                    tblCnt = 1 << j;
-                    sTbl[1 + level] = j;
-                    cnode = [];
-                    while (cnode.length < tblCnt) cnode.push({extra: 0, bitcnt: 0, lbase: 0, next: null});
-                    if (tail == null) {
-                        tail = this.root = {next:null, list:null};
-                    } else {
-                        tail = tail.next = {next:null, list:null}
-                    }
-                    tail.next = null;
-                    tail.list = cnode;
-
-                    tblStack[level] = cnode;
-
-                    if(level > 0) {
-                        offsets[level] = i;
-                        tentry.bitcnt = sTbl[level];
-                        tentry.extra = 16 + j;
-                        tentry.next = cnode;
-                        j = (i & ((1 << w) - 1)) >> (w - sTbl[level]);
-
-                        tblStack[level-1][j].extra = tentry.extra;
-                        tblStack[level-1][j].bitcnt = tentry.bitcnt;
-                        tblStack[level-1][j].lbase = tentry.lbase;
-                        tblStack[level-1][j].next = tentry.next;
-                    }
-                }
-                tentry.bitcnt = bitLen - w;
-                if(pidx >= cnum)
-                    tentry.extra = 99;
-                else if(values[pidx] < cval) {
-                    tentry.extra = (values[pidx] < 256 ? 16 : 15);
-                    tentry.lbase = values[pidx++];
-                } else {
-                    tentry.extra = elist[values[pidx] - cval];
-                    tentry.lbase = blist[values[pidx++] - cval];
-                }
-
-                f = 1 << (bitLen - w);
-                for(j = i >> w; j < tblCnt; j += f) {
-                    cnode[j].extra = tentry.extra;
-                    cnode[j].bitcnt = tentry.bitcnt;
-                    cnode[j].lbase = tentry.lbase;
-                    cnode[j].next = tentry.next;
-                }
-                for(j = 1 << (bitLen - 1); (i & j) != 0; j >>= 1)
-                    i ^= j;
-                i ^= j;
-                while((i & ((1 << w) - 1)) != offsets[level]) {
-                    w -= sTbl[level];
-                    level--;
-                }
-            }
-        }
-
-        this.maxbit = sTbl[1];
-        this.status = ((dCodes != 0 && maxLen != 1) ? 1 : 0);
-    }
-
-    function addBits(n) {
-        while(bitLen < n) {
-            bitBuf |= input[inputPosition++] << bitLen;
-            bitLen += 8;
-        }
-        return bitBuf;
-    }
-
-    function cutBits(n) {
-        bitLen -= n;
-        return bitBuf >>= n;
-    }
-
-    function maskBits(n) {
-        while(bitLen < n) {
-            bitBuf |= input[inputPosition++] << bitLen;
-            bitLen += 8;
-        }
-        var res = bitBuf & MASK_BITS[n];
-        bitBuf >>= n;
-        bitLen -= n;
-        return res;
-    }
-
-    function codes(buff, off, size) {
-        var e, t;
-        if(size == 0) return 0;
-
-        var n = 0;
-        for(;;) {
-            t = tblList.list[addBits(bitList) & MASK_BITS[bitList]];
-            e = t.extra;
-            while(e > 16) {
-                if(e == 99) return -1;
-                cutBits(t.bitcnt);
-                e -= 16;
-                t = t.next[addBits(e) & MASK_BITS[e]];
-                e = t.extra;
-            }
-            cutBits(t.bitcnt);
-            if(e == 16) {
-                windowPos &= WSIZE - 1;
-                buff[off + n++] = slide[windowPos++] = t.lbase;
-                if(n == size) return size;
-                continue;
-            }
-            if(e == 15) break;
-
-            copyLen = t.lbase + maskBits(e);
-            t = tblDist.list[addBits(bitdist) & MASK_BITS[bitdist]];
-            e = t.extra;
-
-            while(e > 16) {
-                if(e == 99) return -1;
-                cutBits(t.bitcnt);
-                e -= 16;
-                t = t.next[addBits(e) & MASK_BITS[e]];
-                e = t.extra
-            }
-            cutBits(t.bitcnt);
-            copyDist = windowPos - t.lbase - maskBits(e);
-
-            while(copyLen > 0 && n < size) {
-                copyLen--;
-                copyDist &= WSIZE - 1;
-                windowPos &= WSIZE - 1;
-                buff[off + n++] = slide[windowPos++] = slide[copyDist++];
-            }
-
-            if(n == size) return size;
-        }
-
-        method = -1; // done
-        return n;
-    }
-
-    function stored(buff, off, size) {
-        cutBits(bitLen & 7);
-        var n = maskBits(0x10);
-        if(n != ((~maskBits(0x10)) & 0xffff)) return -1;
-        copyLen = n;
-
-        n = 0;
-        while(copyLen > 0 && n < size) {
-            copyLen--;
-            windowPos &= WSIZE - 1;
-            buff[off + n++] = slide[windowPos++] = maskBits(8);
-        }
-
-        if(copyLen == 0) method = -1;
-        return n;
-    }
-
-    function fixed(buff, off, size) {
-        var fixed_bd = 0;
-        if(fixedTableList == null) {
-            var lengths = [];
-
-            for(var symbol = 0; symbol < 144; symbol++) lengths[symbol] = 8;
-            for(; symbol < 256; symbol++) lengths[symbol] = 9;
-            for(; symbol < 280; symbol++) lengths[symbol] = 7;
-            for(; symbol < 288; symbol++) lengths[symbol] = 8;
-
-            fixedLookup = 7;
-
-            var htbl = new HuffTable(lengths, 288, 257, LENS, LEXT, fixedLookup);
-
-            if(htbl.status != 0) return -1;
-
-            fixedTableList = htbl.root;
-            fixedLookup = htbl.maxbit;
-
-            for(symbol = 0; symbol < 30; symbol++) lengths[symbol] = 5;
-            fixed_bd = 5;
-
-            htbl = new HuffTable(lengths, 30, 0, DISTS, DEXT, fixed_bd);
-            if(htbl.status > 1) {
-                fixedTableList = null;
-                return -1;
-            }
-            fixedTableDist = htbl.root;
-            fixed_bd = htbl.maxbit;
-        }
-
-        tblList = fixedTableList;
-        tblDist = fixedTableDist;
-        bitList = fixedLookup;
-        bitdist = fixed_bd;
-        return codes(buff, off, size);
-    }
-
-    function dynamic(buff, off, size) {
-        var ll = new Array(0x023C);
-
-        for (var m = 0; m < 0x023C; m++) ll[m] = 0;
-
-        var llencnt = 257 + maskBits(5),
-            dcodescnt = 1 + maskBits(5),
-            bitlencnt = 4 + maskBits(4);
-
-        if(llencnt > 286 || dcodescnt > 30) return -1;
-
-        for(var j = 0; j < bitlencnt; j++) ll[BITORDER[j]] = maskBits(3);
-        for(; j < 19; j++) ll[BITORDER[j]] = 0;
-
-        // build decoding table for trees--single level, 7 bit lookup
-        bitList = 7;
-        var hufTable = new HuffTable(ll, 19, 19, null, null, bitList);
-        if(hufTable.status != 0)
-            return -1;	// incomplete code set
-
-        tblList = hufTable.root;
-        bitList = hufTable.maxbit;
-        var lencnt = llencnt + dcodescnt,
-            i = 0,
-            lastLen = 0;
-        while(i < lencnt) {
-            var hufLcode = tblList.list[addBits(bitList) & MASK_BITS[bitList]];
-            j = hufLcode.bitcnt;
-            cutBits(j);
-            j = hufLcode.lbase;
-            if(j < 16)
-                ll[i++] = lastLen = j;
-            else if(j == 16) {
-                j = 3 + maskBits(2);
-                if(i + j > lencnt) return -1;
-                while(j-- > 0) ll[i++] = lastLen;
-            } else if(j == 17) {
-                j = 3 + maskBits(3);
-                if(i + j > lencnt) return -1;
-                while(j-- > 0) ll[i++] = 0;
-                lastLen = 0;
-            } else {
-                j = 11 + maskBits(7);
-                if(i + j > lencnt) return -1;
-                while(j-- > 0) ll[i++] = 0;
-                lastLen = 0;
-            }
-        }
-        bitList = 9;
-        hufTable = new HuffTable(ll, llencnt, 257, LENS, LEXT, bitList);
-        bitList == 0 && (hufTable.status = 1);
-
-        if (hufTable.status != 0) return -1;
-
-        tblList = hufTable.root;
-        bitList = hufTable.maxbit;
-
-        for(i = 0; i < dcodescnt; i++) ll[i] = ll[i + llencnt];
-        bitdist = 6;
-        hufTable = new HuffTable(ll, dcodescnt, 0, DISTS, DEXT, bitdist);
-        tblDist = hufTable.root;
-        bitdist = hufTable.maxbit;
-
-        if((bitdist == 0 && llencnt > 257) || hufTable.status != 0) return -1;
-
-        return codes(buff, off, size);
-    }
-
-    return {
-        inflate : function(/*Buffer*/outputBuffer) {
-            tblList = null;
-
-            var size = outputBuffer.length,
-                offset = 0, i;
-
-            while(offset < size) {
-                if(eof && method == -1) return;
-                if(copyLen > 0) {
-                    if(method != 0) {
-                        while(copyLen > 0 && offset < size) {
-                            copyLen--;
-                            copyDist &= WSIZE - 1;
-                            windowPos &= WSIZE - 1;
-                            outputBuffer[offset++] = (slide[windowPos++] = slide[copyDist++]);
-                        }
-                    } else {
-                        while(copyLen > 0 && offset < size) {
-                            copyLen--;
-                            windowPos &= WSIZE - 1;
-                            outputBuffer[offset++] = (slide[windowPos++] = maskBits(8));
-                        }
-                        copyLen == 0 && (method = -1); // done
-                    }
-                    if (offset == size) return;
-                }
-
-                if(method == -1) {
-                    if(eof) break;
-                    eof = maskBits(1) != 0;
-                    method = maskBits(2);
-                    tblList = null;
-                    copyLen = 0;
-                }
-                switch(method) {
-                    case 0: i = stored(outputBuffer, offset, size - offset); break;
-                    case 1: i = tblList != null ? codes(outputBuffer, offset, size - offset) : fixed(outputBuffer, offset, size - offset); break;
-                    case 2: i = tblList != null ? codes(outputBuffer, offset, size - offset) : dynamic(outputBuffer, offset, size - offset); break;
-                    default: i = -1; break;
-                }
-
-                if(i == -1) return;
-                offset += i;
-            }
-        }
-    };
-}
-
-module.exports = function(/*Buffer*/inbuf) {
-    var zlib = require("zlib");
-    return {
-        inflateAsync : function(/*Function*/callback) {
-            var tmp = zlib.createInflateRaw(),
-                parts = [], total = 0;
-            tmp.on('data', function(data) {
-                parts.push(data);
-                total += data.length;
-            });
-            tmp.on('end', function() {
-                var buf = new Buffer(total), written = 0;
-                buf.fill(0);
-
-                for (var i = 0; i < parts.length; i++) {
-                    var part = parts[i];
-                    part.copy(buf, written);
-                    written += part.length;
-                }
-                callback && callback(buf);
-            });
-            tmp.end(inbuf)
-        },
-
-        inflate : function(/*Buffer*/outputBuffer) {
-            var x = {
-                x: new JSInflater(inbuf)
-            };
-            x.x.inflate(outputBuffer);
-            delete(x.x);
-        }
-    }
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/package.json
deleted file mode 100644
index 00afae6..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/package.json
+++ /dev/null
@@ -1,102 +0,0 @@
-{
-  "_args": [
-    [
-      {
-        "raw": "adm-zip@^0.4.7",
-        "scope": null,
-        "escapedName": "adm-zip",
-        "name": "adm-zip",
-        "rawSpec": "^0.4.7",
-        "spec": ">=0.4.7 <0.5.0",
-        "type": "range"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser"
-    ]
-  ],
-  "_from": "adm-zip@>=0.4.7 <0.5.0",
-  "_id": "adm-zip@0.4.7",
-  "_inCache": true,
-  "_location": "/adm-zip",
-  "_nodeVersion": "0.12.0",
-  "_npmUser": {
-    "name": "cthackers",
-    "email": "iacob.campia@gmail.com"
-  },
-  "_npmVersion": "2.5.1",
-  "_phantomChildren": {},
-  "_requested": {
-    "raw": "adm-zip@^0.4.7",
-    "scope": null,
-    "escapedName": "adm-zip",
-    "name": "adm-zip",
-    "rawSpec": "^0.4.7",
-    "spec": ">=0.4.7 <0.5.0",
-    "type": "range"
-  },
-  "_requiredBy": [
-    "/"
-  ],
-  "_resolved": "https://registry.npmjs.org/adm-zip/-/adm-zip-0.4.7.tgz",
-  "_shasum": "8606c2cbf1c426ce8c8ec00174447fd49b6eafc1",
-  "_shrinkwrap": null,
-  "_spec": "adm-zip@^0.4.7",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser",
-  "author": {
-    "name": "Nasca Iacob",
-    "email": "sy@another-d-mention.ro",
-    "url": "https://github.com/cthackers"
-  },
-  "bugs": {
-    "url": "https://github.com/cthackers/adm-zip/issues",
-    "email": "sy@another-d-mention.ro"
-  },
-  "dependencies": {},
-  "description": "A Javascript implementation of zip for nodejs. Allows user to create or extract zip files both in memory or to/from disk",
-  "devDependencies": {},
-  "directories": {},
-  "dist": {
-    "shasum": "8606c2cbf1c426ce8c8ec00174447fd49b6eafc1",
-    "tarball": "https://registry.npmjs.org/adm-zip/-/adm-zip-0.4.7.tgz"
-  },
-  "engines": {
-    "node": ">=0.3.0"
-  },
-  "files": [
-    "adm-zip.js",
-    "headers",
-    "methods",
-    "util",
-    "zipEntry.js",
-    "zipFile.js"
-  ],
-  "gitHead": "6708a3e5788ff9e67ddba288397f7788a5c02855",
-  "homepage": "http://github.com/cthackers/adm-zip",
-  "keywords": [
-    "zip",
-    "methods",
-    "archive",
-    "unzip"
-  ],
-  "licenses": [
-    {
-      "type": "MIT",
-      "url": "https://raw.github.com/cthackers/adm-zip/master/MIT-LICENSE.txt"
-    }
-  ],
-  "main": "adm-zip.js",
-  "maintainers": [
-    {
-      "name": "cthackers",
-      "email": "sy@another-d-mention.ro"
-    }
-  ],
-  "name": "adm-zip",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/cthackers/adm-zip.git"
-  },
-  "scripts": {},
-  "version": "0.4.7"
-}
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/constants.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/constants.js
deleted file mode 100644
index 02de1e9..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/constants.js
+++ /dev/null
@@ -1,115 +0,0 @@
-module.exports = {
-    /* The local file header */
-    LOCHDR           : 30, // LOC header size
-    LOCSIG           : 0x04034b50, // "PK\003\004"
-    LOCVER           : 4,	// version needed to extract
-    LOCFLG           : 6, // general purpose bit flag
-    LOCHOW           : 8, // compression method
-    LOCTIM           : 10, // modification time (2 bytes time, 2 bytes date)
-    LOCCRC           : 14, // uncompressed file crc-32 value
-    LOCSIZ           : 18, // compressed size
-    LOCLEN           : 22, // uncompressed size
-    LOCNAM           : 26, // filename length
-    LOCEXT           : 28, // extra field length
-
-    /* The Data descriptor */
-    EXTSIG           : 0x08074b50, // "PK\007\008"
-    EXTHDR           : 16, // EXT header size
-    EXTCRC           : 4, // uncompressed file crc-32 value
-    EXTSIZ           : 8, // compressed size
-    EXTLEN           : 12, // uncompressed size
-
-    /* The central directory file header */
-    CENHDR           : 46, // CEN header size
-    CENSIG           : 0x02014b50, // "PK\001\002"
-    CENVEM           : 4, // version made by
-    CENVER           : 6, // version needed to extract
-    CENFLG           : 8, // encrypt, decrypt flags
-    CENHOW           : 10, // compression method
-    CENTIM           : 12, // modification time (2 bytes time, 2 bytes date)
-    CENCRC           : 16, // uncompressed file crc-32 value
-    CENSIZ           : 20, // compressed size
-    CENLEN           : 24, // uncompressed size
-    CENNAM           : 28, // filename length
-    CENEXT           : 30, // extra field length
-    CENCOM           : 32, // file comment length
-    CENDSK           : 34, // volume number start
-    CENATT           : 36, // internal file attributes
-    CENATX           : 38, // external file attributes (host system dependent)
-    CENOFF           : 42, // LOC header offset
-
-    /* The entries in the end of central directory */
-    ENDHDR           : 22, // END header size
-    ENDSIG           : 0x06054b50, // "PK\005\006"
-    ENDSUB           : 8, // number of entries on this disk
-    ENDTOT           : 10, // total number of entries
-    ENDSIZ           : 12, // central directory size in bytes
-    ENDOFF           : 16, // offset of first CEN header
-    ENDCOM           : 20, // zip file comment length
-
-    /* Compression methods */
-    STORED           : 0, // no compression
-    SHRUNK           : 1, // shrunk
-    REDUCED1         : 2, // reduced with compression factor 1
-    REDUCED2         : 3, // reduced with compression factor 2
-    REDUCED3         : 4, // reduced with compression factor 3
-    REDUCED4         : 5, // reduced with compression factor 4
-    IMPLODED         : 6, // imploded
-    // 7 reserved
-    DEFLATED         : 8, // deflated
-    ENHANCED_DEFLATED: 9, // enhanced deflated
-    PKWARE           : 10,// PKWare DCL imploded
-    // 11 reserved
-    BZIP2            : 12, //  compressed using BZIP2
-    // 13 reserved
-    LZMA             : 14, // LZMA
-    // 15-17 reserved
-    IBM_TERSE        : 18, // compressed using IBM TERSE
-    IBM_LZ77         : 19, //IBM LZ77 z
-
-    /* General purpose bit flag */
-    FLG_ENC          : 0,  // encripted file
-    FLG_COMP1        : 1,  // compression option
-    FLG_COMP2        : 2,  // compression option
-    FLG_DESC         : 4,  // data descriptor
-    FLG_ENH          : 8,  // enhanced deflation
-    FLG_STR          : 16, // strong encryption
-    FLG_LNG          : 1024, // language encoding
-    FLG_MSK          : 4096, // mask header values
-
-    /* Load type */
-    FILE             : 0,
-    BUFFER           : 1,
-    NONE             : 2,
-
-    /* 4.5 Extensible data fields */
-    EF_ID            : 0,
-    EF_SIZE          : 2,
-
-    /* Header IDs */
-    ID_ZIP64         : 0x0001,
-    ID_AVINFO        : 0x0007,
-    ID_PFS           : 0x0008,
-    ID_OS2           : 0x0009,
-    ID_NTFS          : 0x000a,
-    ID_OPENVMS       : 0x000c,
-    ID_UNIX          : 0x000d,
-    ID_FORK          : 0x000e,
-    ID_PATCH         : 0x000f,
-    ID_X509_PKCS7    : 0x0014,
-    ID_X509_CERTID_F : 0x0015,
-    ID_X509_CERTID_C : 0x0016,
-    ID_STRONGENC     : 0x0017,
-    ID_RECORD_MGT    : 0x0018,
-    ID_X509_PKCS7_RL : 0x0019,
-    ID_IBM1          : 0x0065,
-    ID_IBM2          : 0x0066,
-    ID_POSZIP        : 0x4690,
-
-    EF_ZIP64_OR_32   : 0xffffffff,
-    EF_ZIP64_OR_16   : 0xffff,
-    EF_ZIP64_SUNCOMP : 0,
-    EF_ZIP64_SCOMP   : 8,
-    EF_ZIP64_RHO     : 16,
-    EF_ZIP64_DSN     : 24
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/errors.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/errors.js
deleted file mode 100644
index 50931c3..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/errors.js
+++ /dev/null
@@ -1,35 +0,0 @@
-module.exports = {
-    /* Header error messages */
-    "INVALID_LOC" : "Invalid LOC header (bad signature)",
-    "INVALID_CEN" : "Invalid CEN header (bad signature)",
-    "INVALID_END" : "Invalid END header (bad signature)",
-
-    /* ZipEntry error messages*/
-    "NO_DATA" : "Nothing to decompress",
-    "BAD_CRC" : "CRC32 checksum failed",
-    "FILE_IN_THE_WAY" : "There is a file in the way: %s",
-    "UNKNOWN_METHOD" : "Invalid/unsupported compression method",
-
-    /* Inflater error messages */
-    "AVAIL_DATA" : "inflate::Available inflate data did not terminate",
-    "INVALID_DISTANCE" : "inflate::Invalid literal/length or distance code in fixed or dynamic block",
-    "TO_MANY_CODES" : "inflate::Dynamic block code description: too many length or distance codes",
-    "INVALID_REPEAT_LEN" : "inflate::Dynamic block code description: repeat more than specified lengths",
-    "INVALID_REPEAT_FIRST" : "inflate::Dynamic block code description: repeat lengths with no first length",
-    "INCOMPLETE_CODES" : "inflate::Dynamic block code description: code lengths codes incomplete",
-    "INVALID_DYN_DISTANCE": "inflate::Dynamic block code description: invalid distance code lengths",
-    "INVALID_CODES_LEN": "inflate::Dynamic block code description: invalid literal/length code lengths",
-    "INVALID_STORE_BLOCK" : "inflate::Stored block length did not match one's complement",
-    "INVALID_BLOCK_TYPE" : "inflate::Invalid block type (type == 3)",
-
-    /* ADM-ZIP error messages */
-    "CANT_EXTRACT_FILE" : "Could not extract the file",
-    "CANT_OVERRIDE" : "Target file already exists",
-    "NO_ZIP" : "No zip file was loaded",
-    "NO_ENTRY" : "Entry doesn't exist",
-    "DIRECTORY_CONTENT_ERROR" : "A directory cannot have content",
-    "FILE_NOT_FOUND" : "File not found: %s",
-    "NOT_IMPLEMENTED" : "Not implemented",
-    "INVALID_FILENAME" : "Invalid filename",
-    "INVALID_FORMAT" : "Invalid or unsupported zip format. No END header found"
-};
\ No newline at end of file
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/fattr.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/fattr.js
deleted file mode 100644
index 4f247ea..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/fattr.js
+++ /dev/null
@@ -1,84 +0,0 @@
-var fs = require("fs"),
-    pth = require("path");
-	
-fs.existsSync = fs.existsSync || pth.existsSync;
-
-module.exports = function(/*String*/path) {
-
-    var _path = path || "",
-        _permissions = 0,
-        _obj = newAttr(),
-        _stat = null;
-
-    function newAttr() {
-        return {
-            directory : false,
-            readonly : false,
-            hidden : false,
-            executable : false,
-            mtime : 0,
-            atime : 0
-        }
-    }
-
-    if (_path && fs.existsSync(_path)) {
-        _stat = fs.statSync(_path);
-        _obj.directory = _stat.isDirectory();
-        _obj.mtime = _stat.mtime;
-        _obj.atime = _stat.atime;
-        _obj.executable = !!(1 & parseInt ((_stat.mode & parseInt ("777", 8)).toString (8)[0]));
-        _obj.readonly = !!(2 & parseInt ((_stat.mode & parseInt ("777", 8)).toString (8)[0]));
-        _obj.hidden = pth.basename(_path)[0] === ".";
-    } else {
-        console.warn("Invalid path: " + _path)
-    }
-
-    return {
-
-        get directory () {
-            return _obj.directory;
-        },
-
-        get readOnly () {
-            return _obj.readonly;
-        },
-
-        get hidden () {
-            return _obj.hidden;
-        },
-
-        get mtime () {
-            return _obj.mtime;
-        },
-
-        get atime () {
-           return _obj.atime;
-        },
-
-
-        get executable () {
-            return _obj.executable;
-        },
-
-        decodeAttributes : function(val) {
-
-        },
-
-        encodeAttributes : function (val) {
-
-        },
-
-        toString : function() {
-           return '{\n' +
-               '\t"path" : "' + _path + ",\n" +
-               '\t"isDirectory" : ' + _obj.directory + ",\n" +
-               '\t"isReadOnly" : ' + _obj.readonly + ",\n" +
-               '\t"isHidden" : ' + _obj.hidden + ",\n" +
-               '\t"isExecutable" : ' + _obj.executable + ",\n" +
-               '\t"mTime" : ' + _obj.mtime + "\n" +
-               '\t"aTime" : ' + _obj.atime + "\n" +
-           '}';
-        }
-    }
-
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/index.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/index.js
deleted file mode 100644
index d77b980..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/index.js
+++ /dev/null
@@ -1,4 +0,0 @@
-module.exports = require("./utils");
-module.exports.Constants = require("./constants");
-module.exports.Errors = require("./errors");
-module.exports.FileAttr = require("./fattr");
\ No newline at end of file
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/utils.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/utils.js
deleted file mode 100644
index 52a8ed9..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/util/utils.js
+++ /dev/null
@@ -1,199 +0,0 @@
-var fs = require("fs"),
-    pth = require('path');
-
-fs.existsSync = fs.existsSync || pth.existsSync;
-
-module.exports = (function() {
-
-    var crcTable = [],
-        Constants = require('./constants'),
-        Errors = require('./errors'),
-
-        PATH_SEPARATOR = pth.normalize("/");
-
-
-    function mkdirSync(/*String*/path) {
-        var resolvedPath = path.split(PATH_SEPARATOR)[0];
-        path.split(PATH_SEPARATOR).forEach(function(name) {
-            if (!name || name.substr(-1,1) == ":") return;
-            resolvedPath += PATH_SEPARATOR + name;
-            var stat;
-            try {
-                stat = fs.statSync(resolvedPath);
-            } catch (e) {
-                fs.mkdirSync(resolvedPath);
-            }
-            if (stat && stat.isFile())
-                throw Errors.FILE_IN_THE_WAY.replace("%s", resolvedPath);
-        });
-    }
-
-    function findSync(/*String*/root, /*RegExp*/pattern, /*Boolean*/recoursive) {
-        if (typeof pattern === 'boolean') {
-            recoursive = pattern;
-            pattern = undefined;
-        }
-        var files = [];
-        fs.readdirSync(root).forEach(function(file) {
-            var path = pth.join(root, file);
-
-            if (fs.statSync(path).isDirectory() && recoursive)
-                files = files.concat(findSync(path, pattern, recoursive));
-
-            if (!pattern || pattern.test(path)) {
-                files.push(pth.normalize(path) + (fs.statSync(path).isDirectory() ? PATH_SEPARATOR : ""));
-            }
-
-        });
-        return files;
-    }
-
-    return {
-        makeDir : function(/*String*/path) {
-            mkdirSync(path);
-        },
-
-        crc32 : function(buf) {
-            var b = new Buffer(4);
-            if (!crcTable.length) {
-                for (var n = 0; n < 256; n++) {
-                    var c = n;
-                    for (var k = 8; --k >= 0;)  //
-                        if ((c & 1) != 0)  { c = 0xedb88320 ^ (c >>> 1); } else { c = c >>> 1; }
-                    if (c < 0) {
-                        b.writeInt32LE(c, 0);
-                        c = b.readUInt32LE(0);
-                    }
-                    crcTable[n] = c;
-                }
-            }
-            var crc = 0, off = 0, len = buf.length, c1 = ~crc;
-            while(--len >= 0) c1 = crcTable[(c1 ^ buf[off++]) & 0xff] ^ (c1 >>> 8);
-            crc = ~c1;
-            b.writeInt32LE(crc & 0xffffffff, 0);
-            return b.readUInt32LE(0);
-        },
-
-        methodToString : function(/*Number*/method) {
-            switch (method) {
-                case Constants.STORED:
-                    return 'STORED (' + method + ')';
-                case Constants.DEFLATED:
-                    return 'DEFLATED (' + method + ')';
-                default:
-                    return 'UNSUPPORTED (' + method + ')';
-            }
-
-        },
-
-        writeFileTo : function(/*String*/path, /*Buffer*/content, /*Boolean*/overwrite, /*Number*/attr) {
-            if (fs.existsSync(path)) {
-                if (!overwrite)
-                    return false; // cannot overwite
-
-                var stat = fs.statSync(path);
-                if (stat.isDirectory()) {
-                    return false;
-                }
-            }
-            var folder = pth.dirname(path);
-            if (!fs.existsSync(folder)) {
-                mkdirSync(folder);
-            }
-
-            var fd;
-            try {
-                fd = fs.openSync(path, 'w', 438); // 0666
-            } catch(e) {
-                fs.chmodSync(path, 438);
-                fd = fs.openSync(path, 'w', 438);
-            }
-            if (fd) {
-                fs.writeSync(fd, content, 0, content.length, 0);
-                fs.closeSync(fd);
-            }
-            fs.chmodSync(path, attr || 438);
-            return true;
-        },
-
-        writeFileToAsync : function(/*String*/path, /*Buffer*/content, /*Boolean*/overwrite, /*Number*/attr, /*Function*/callback) {
-            if(typeof attr === 'function') {
-                callback = attr;
-                attr = undefined;
-            }
-
-            fs.exists(path, function(exists) {
-                if(exists && !overwrite)
-                    return callback(false);
-
-                fs.stat(path, function(err, stat) {
-                    if(exists &&stat.isDirectory()) {
-                        return callback(false);
-                    }
-
-                    var folder = pth.dirname(path);
-                    fs.exists(folder, function(exists) {
-                        if(!exists)
-                            mkdirSync(folder);
-                        
-                        fs.open(path, 'w', 438, function(err, fd) {
-                            if(err) {
-                                fs.chmod(path, 438, function(err) {
-                                    fs.open(path, 'w', 438, function(err, fd) {
-                                        fs.write(fd, content, 0, content.length, 0, function(err, written, buffer) {
-                                            fs.close(fd, function(err) {
-                                                fs.chmod(path, attr || 438, function() {
-                                                    callback(true);
-                                                })
-                                            });
-                                        });
-                                    });
-                                })
-                            } else {
-                                if(fd) {
-                                    fs.write(fd, content, 0, content.length, 0, function(err, written, buffer) {
-                                        fs.close(fd, function(err) {
-                                            fs.chmod(path, attr || 438, function() {
-                                                callback(true);
-                                            })
-                                        });
-                                    });
-                                } else {
-                                    fs.chmod(path, attr || 438, function() {
-                                        callback(true);
-                                    })
-                                }
-                            }
-                        });
-                    })
-                })
-            })
-        },
-
-        findFiles : function(/*String*/path) {
-            return findSync(path, true);
-        },
-
-        getAttributes : function(/*String*/path) {
-
-        },
-
-        setAttributes : function(/*String*/path) {
-
-        },
-
-        toBuffer : function(input) {
-            if (Buffer.isBuffer(input)) {
-                return input;
-            } else {
-                if (input.length == 0) {
-                    return new Buffer(0)
-                }
-                return new Buffer(input, 'utf8');
-            }
-        },
-
-        Constants : Constants,
-        Errors : Errors
-    }
-})();
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/zipEntry.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/zipEntry.js
deleted file mode 100644
index 6b1309b..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/zipEntry.js
+++ /dev/null
@@ -1,284 +0,0 @@
-var Utils = require("./util"),
-    Headers = require("./headers"),
-    Constants = Utils.Constants,
-    Methods = require("./methods");
-
-module.exports = function (/*Buffer*/input) {
-
-    var _entryHeader = new Headers.EntryHeader(),
-        _entryName = new Buffer(0),
-        _comment = new Buffer(0),
-        _isDirectory = false,
-        uncompressedData = null,
-        _extra = new Buffer(0);
-
-    function getCompressedDataFromZip() {
-        if (!input || !Buffer.isBuffer(input)) {
-            return new Buffer(0);
-        }
-        _entryHeader.loadDataHeaderFromBinary(input);
-        return input.slice(_entryHeader.realDataOffset, _entryHeader.realDataOffset + _entryHeader.compressedSize)
-    }
-
-    function crc32OK(data) {
-        // if bit 3 (0x08) of the general-purpose flags field is set, then the CRC-32 and file sizes are not known when the header is written
-        if (_entryHeader.flags & 0x8 != 0x8) {
-           if (Utils.crc32(data) != _entryHeader.crc) {
-               return false;
-           }
-        } else {
-            // @TODO: load and check data descriptor header
-            // The fields in the local header are filled with zero, and the CRC-32 and size are appended in a 12-byte structure
-            // (optionally preceded by a 4-byte signature) immediately after the compressed data:
-        }
-        return true;
-    }
-
-    function decompress(/*Boolean*/async, /*Function*/callback, /*String*/pass) {
-        if(typeof callback === 'undefined' && typeof async === 'string') {
-            pass=async;
-            async=void 0;
-        }
-        if (_isDirectory) {
-            if (async && callback) {
-                callback(new Buffer(0), Utils.Errors.DIRECTORY_CONTENT_ERROR); //si added error.
-            }
-            return new Buffer(0);
-        }
-
-        var compressedData = getCompressedDataFromZip();
-       
-        if (compressedData.length == 0) {
-            if (async && callback) callback(compressedData, Utils.Errors.NO_DATA);//si added error.
-            return compressedData;
-        }
-
-        var data = new Buffer(_entryHeader.size);
-        data.fill(0);
-
-        switch (_entryHeader.method) {
-            case Utils.Constants.STORED:
-                compressedData.copy(data);
-                if (!crc32OK(data)) {
-                    if (async && callback) callback(data, Utils.Errors.BAD_CRC);//si added error
-                    return Utils.Errors.BAD_CRC;
-                } else {//si added otherwise did not seem to return data.
-                    if (async && callback) callback(data);
-                    return data;
-                }
-                break;
-            case Utils.Constants.DEFLATED:
-                var inflater = new Methods.Inflater(compressedData);
-                if (!async) {
-                    inflater.inflate(data);
-                    if (!crc32OK(data)) {
-                        console.warn(Utils.Errors.BAD_CRC + " " + _entryName.toString())
-                    }
-                    return data;
-                } else {
-                    inflater.inflateAsync(function(result) {
-                        result.copy(data, 0);
-                        if (!crc32OK(data)) {
-                            if (callback) callback(data, Utils.Errors.BAD_CRC); //si added error
-                        } else { //si added otherwise did not seem to return data.
-                            if (callback) callback(data);
-                        }
-                    })
-                }
-                break;
-            default:
-                if (async && callback) callback(new Buffer(0), Utils.Errors.UNKNOWN_METHOD);
-                return Utils.Errors.UNKNOWN_METHOD;
-        }
-    }
-
-    function compress(/*Boolean*/async, /*Function*/callback) {
-        if ((!uncompressedData || !uncompressedData.length) && Buffer.isBuffer(input)) {
-            // no data set or the data wasn't changed to require recompression
-            if (async && callback) callback(getCompressedDataFromZip());
-            return getCompressedDataFromZip();
-        }
-
-        if (uncompressedData.length && !_isDirectory) {
-            var compressedData;
-            // Local file header
-            switch (_entryHeader.method) {
-                case Utils.Constants.STORED:
-                    _entryHeader.compressedSize = _entryHeader.size;
-
-                    compressedData = new Buffer(uncompressedData.length);
-                    uncompressedData.copy(compressedData);
-
-                    if (async && callback) callback(compressedData);
-                    return compressedData;
-
-                    break;
-                default:
-                case Utils.Constants.DEFLATED:
-
-                    var deflater = new Methods.Deflater(uncompressedData);
-                    if (!async) {
-                        var deflated = deflater.deflate();
-                        _entryHeader.compressedSize = deflated.length;
-                        return deflated;
-                    } else {
-                        deflater.deflateAsync(function(data) {
-                            compressedData = new Buffer(data.length);
-                            _entryHeader.compressedSize = data.length;
-                            data.copy(compressedData);
-                            callback && callback(compressedData);
-                        })
-                    }
-                    deflater = null;
-                    break;
-            }
-        } else {
-            if (async && callback) {
-                callback(new Buffer(0));
-            } else {
-                return new Buffer(0);
-            }
-        }
-    }
-
-    function readUInt64LE(buffer, offset) {
-        return (buffer.readUInt32LE(offset + 4) << 4) + buffer.readUInt32LE(offset);
-    }
-
-    function parseExtra(data) {
-        var offset = 0;
-        var signature, size, part;
-        while(offset<data.length) {
-            signature = data.readUInt16LE(offset);
-            offset += 2;
-            size = data.readUInt16LE(offset);
-            offset += 2;
-            part = data.slice(offset, offset+size);
-            offset += size;
-            if(Constants.ID_ZIP64 === signature) {
-                parseZip64ExtendedInformation(part);
-            }
-        }
-    }
-
-    //Override header field values with values from the ZIP64 extra field
-    function parseZip64ExtendedInformation(data) {
-        var size, compressedSize, offset, diskNumStart;
-
-        if(data.length >= Constants.EF_ZIP64_SCOMP) {
-            size = readUInt64LE(data, Constants.EF_ZIP64_SUNCOMP);
-            if(_entryHeader.size === Constants.EF_ZIP64_OR_32) {
-                _entryHeader.size = size;
-            }
-        }
-        if(data.length >= Constants.EF_ZIP64_RHO) {
-            compressedSize = readUInt64LE(data, Constants.EF_ZIP64_SCOMP);
-            if(_entryHeader.compressedSize === Constants.EF_ZIP64_OR_32) {
-                _entryHeader.compressedSize = compressedSize;
-            }
-        }
-        if(data.length >= Constants.EF_ZIP64_DSN) {
-            offset = readUInt64LE(data, Constants.EF_ZIP64_RHO);
-            if(_entryHeader.offset === Constants.EF_ZIP64_OR_32) {
-                _entryHeader.offset = offset;
-            }
-        }
-        if(data.length >= Constants.EF_ZIP64_DSN+4) {
-            diskNumStart = data.readUInt32LE(Constants.EF_ZIP64_DSN);
-            if(_entryHeader.diskNumStart === Constants.EF_ZIP64_OR_16) {
-                _entryHeader.diskNumStart = diskNumStart;
-            }
-        }
-    }
-
-
-    return {
-        get entryName () { return _entryName.toString(); },
-        get rawEntryName() { return _entryName; },
-        set entryName (val) {
-            _entryName = Utils.toBuffer(val);
-            var lastChar = _entryName[_entryName.length - 1];
-            _isDirectory = (lastChar == 47) || (lastChar == 92);
-            _entryHeader.fileNameLength = _entryName.length;
-        },
-
-        get extra () { return _extra; },
-        set extra (val) {
-            _extra = val;
-            _entryHeader.extraLength = val.length;
-            parseExtra(val);
-        },
-
-        get comment () { return _comment.toString(); },
-        set comment (val) {
-            _comment = Utils.toBuffer(val);
-            _entryHeader.commentLength = _comment.length;
-        },
-
-        get name () { var n = _entryName.toString(); return _isDirectory ? n.substr(n.length - 1).split("/").pop() : n.split("/").pop(); },
-        get isDirectory () { return _isDirectory },
-
-        getCompressedData : function() {
-            return compress(false, null)
-        },
-
-        getCompressedDataAsync : function(/*Function*/callback) {
-            compress(true, callback)
-        },
-
-        setData : function(value) {
-            uncompressedData = Utils.toBuffer(value);
-            if (!_isDirectory && uncompressedData.length) {
-                _entryHeader.size = uncompressedData.length;
-                _entryHeader.method = Utils.Constants.DEFLATED;
-                _entryHeader.crc = Utils.crc32(value);
-            } else { // folders and blank files should be stored
-                _entryHeader.method = Utils.Constants.STORED;
-            }
-        },
-
-        getData : function(pass) {
-            return decompress(false, null, pass);
-        },
-
-        getDataAsync : function(/*Function*/callback, pass) {
-            decompress(true, callback, pass)
-        },
-
-        set attr(attr) { _entryHeader.attr = attr; },
-        get attr() { return _entryHeader.attr; },
-
-        set header(/*Buffer*/data) {
-            _entryHeader.loadFromBinary(data);
-        },
-
-        get header() {
-            return _entryHeader;
-        },
-
-        packHeader : function() {
-            var header = _entryHeader.entryHeaderToBinary();
-            // add
-            _entryName.copy(header, Utils.Constants.CENHDR);
-            if (_entryHeader.extraLength) {
-                _extra.copy(header, Utils.Constants.CENHDR + _entryName.length)
-            }
-            if (_entryHeader.commentLength) {
-                _comment.copy(header, Utils.Constants.CENHDR + _entryName.length + _entryHeader.extraLength, _comment.length);
-            }
-            return header;
-        },
-
-        toString : function() {
-            return '{\n' +
-                '\t"entryName" : "' + _entryName.toString() + "\",\n" +
-                '\t"name" : "' + _entryName.toString().split("/").pop() + "\",\n" +
-                '\t"comment" : "' + _comment.toString() + "\",\n" +
-                '\t"isDirectory" : ' + _isDirectory + ",\n" +
-                '\t"header" : ' + _entryHeader.toString().replace(/\t/mg, "\t\t") + ",\n" +
-                '\t"compressedData" : <' + (input && input.length  + " bytes buffer" || "null") + ">\n" +
-                '\t"data" : <' + (uncompressedData && uncompressedData.length  + " bytes buffer" || "null") + ">\n" +
-                '}';
-        }
-    }
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/zipFile.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/zipFile.js
deleted file mode 100644
index 794afdb..0000000
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/adm-zip/zipFile.js
+++ /dev/null
@@ -1,311 +0,0 @@
-var ZipEntry = require("./zipEntry"),
-    Headers = require("./headers"),
-    Utils = require("./util");
-
-module.exports = function(/*String|Buffer*/input, /*Number*/inputType) {
-    var entryList = [],
-        entryTable = {},
-        _comment = new Buffer(0),
-        filename = "",
-        fs = require("fs"),
-        inBuffer = null,
-        mainHeader = new Headers.MainHeader();
-
-    if (inputType == Utils.Constants.FILE) {
-        // is a filename
-        filename = input;
-        inBuffer = fs.readFileSync(filename);
-        readMainHeader();
-    } else if (inputType == Utils.Constants.BUFFER) {
-        // is a memory buffer
-        inBuffer = input;
-        readMainHeader();
-    } else {
-        // none. is a new file
-    }
-
-    function readEntries() {
-        entryTable = {};
-        entryList = new Array(mainHeader.diskEntries);  // total number of entries
-        var index = mainHeader.offset;  // offset of first CEN header
-        for(var i = 0; i < entryList.length; i++) {
-
-            var tmp = index,
-                entry = new ZipEntry(inBuffer);
-            entry.header = inBuffer.slice(tmp, tmp += Utils.Constants.CENHDR);
-
-            entry.entryName = inBuffer.slice(tmp, tmp += entry.header.fileNameLength);
-
-            if (entry.header.extraLength) {
-                entry.extra = inBuffer.slice(tmp, tmp += entry.header.extraLength);
-            }
-
-            if (entry.header.commentLength)
-                entry.comment = inBuffer.slice(tmp, tmp + entry.header.commentLength);
-
-            index += entry.header.entryHeaderSize;
-
-            entryList[i] = entry;
-            entryTable[entry.entryName] = entry;
-        }
-    }
-
-    function readMainHeader() {
-        var i = inBuffer.length - Utils.Constants.ENDHDR, // END header size
-            n = Math.max(0, i - 0xFFFF), // 0xFFFF is the max zip file comment length
-            endOffset = -1; // Start offset of the END header
-
-        for (i; i >= n; i--) {
-            if (inBuffer[i] != 0x50) continue; // quick check that the byte is 'P'
-            if (inBuffer.readUInt32LE(i) == Utils.Constants.ENDSIG) { // "PK\005\006"
-                endOffset = i;
-                break;
-            }
-        }
-        if (!~endOffset)
-            throw Utils.Errors.INVALID_FORMAT;
-
-        mainHeader.loadFromBinary(inBuffer.slice(endOffset, endOffset + Utils.Constants.ENDHDR));
-        if (mainHeader.commentLength) {
-            _comment = inBuffer.slice(endOffset + Utils.Constants.ENDHDR);
-        }
-        readEntries();
-    }
-
-    return {
-        /**
-         * Returns an array of ZipEntry objects existent in the current opened archive
-         * @return Array
-         */
-        get entries () {
-            return entryList;
-        },
-
-        /**
-         * Archive comment
-         * @return {String}
-         */
-        get comment () { return _comment.toString(); },
-        set comment(val) {
-            mainHeader.commentLength = val.length;
-            _comment = val;
-        },
-
-        /**
-         * Returns a reference to the entry with the given name or null if entry is inexistent
-         *
-         * @param entryName
-         * @return ZipEntry
-         */
-        getEntry : function(/*String*/entryName) {
-            return entryTable[entryName] || null;
-        },
-
-        /**
-         * Adds the given entry to the entry list
-         *
-         * @param entry
-         */
-        setEntry : function(/*ZipEntry*/entry) {
-            entryList.push(entry);
-            entryTable[entry.entryName] = entry;
-            mainHeader.totalEntries = entryList.length;
-        },
-
-        /**
-         * Removes the entry with the given name from the entry list.
-         *
-         * If the entry is a directory, then all nested files and directories will be removed
-         * @param entryName
-         */
-        deleteEntry : function(/*String*/entryName) {
-            var entry = entryTable[entryName];
-            if (entry && entry.isDirectory) {
-                var _self = this;
-                this.getEntryChildren(entry).forEach(function(child) {
-                    if (child.entryName != entryName) {
-                        _self.deleteEntry(child.entryName)
-                    }
-                })
-            }
-            entryList.splice(entryList.indexOf(entry), 1);
-            delete(entryTable[entryName]);
-            mainHeader.totalEntries = entryList.length;
-        },
-
-        /**
-         *  Iterates and returns all nested files and directories of the given entry
-         *
-         * @param entry
-         * @return Array
-         */
-        getEntryChildren : function(/*ZipEntry*/entry) {
-            if (entry.isDirectory) {
-                var list = [],
-                    name = entry.entryName,
-                    len = name.length;
-
-                entryList.forEach(function(zipEntry) {
-                    if (zipEntry.entryName.substr(0, len) == name) {
-                        list.push(zipEntry);
-                    }
-                });
-                return list;
-            }
-            return []
-        },
-
-        /**
-         * Returns the zip file
-         *
-         * @return Buffer
-         */
-        compressToBuffer : function() {
-            if (entryList.length > 1) {
-                entryList.sort(function(a, b) {
-                    var nameA = a.entryName.toLowerCase();
-                    var nameB = b.entryName.toLowerCase();
-                    if (nameA < nameB) {return -1}
-                    if (nameA > nameB) {return 1}
-                    return 0;
-                });
-            }
-
-            var totalSize = 0,
-                dataBlock = [],
-                entryHeaders = [],
-                dindex = 0;
-
-            mainHeader.size = 0;
-            mainHeader.offset = 0;
-
-            entryList.forEach(function(entry) {
-                entry.header.offset = dindex;
-
-                // compress data and set local and entry header accordingly. Reason why is called first
-                var compressedData = entry.getCompressedData();
-                // data header
-                var dataHeader = entry.header.dataHeaderToBinary();
-                var postHeader = new Buffer(entry.entryName + entry.extra.toString());
-                var dataLength = dataHeader.length + postHeader.length + compressedData.length;
-
-                dindex += dataLength;
-
-                dataBlock.push(dataHeader);
-                dataBlock.push(postHeader);
-                dataBlock.push(compressedData);
-
-                var entryHeader = entry.packHeader();
-                entryHeaders.push(entryHeader);
-                mainHeader.size += entryHeader.length;
-                totalSize += (dataLength + entryHeader.length);
-            });
-
-            totalSize += mainHeader.mainHeaderSize; // also includes zip file comment length
-            // point to end of data and begining of central directory first record
-            mainHeader.offset = dindex;
-
-            dindex = 0;
-            var outBuffer = new Buffer(totalSize);
-            dataBlock.forEach(function(content) {
-                content.copy(outBuffer, dindex); // write data blocks
-                dindex += content.length;
-            });
-            entryHeaders.forEach(function(content) {
-                content.copy(outBuffer, dindex); // write central directory entries
-                dindex += content.length;
-            });
-
-            var mh = mainHeader.toBinary();
-            if (_comment) {
-                _comment.copy(mh, Utils.Constants.ENDHDR); // add zip file comment
-            }
-
-            mh.copy(outBuffer, dindex); // write main header
-
-            return outBuffer
-        },
-
-        toAsyncBuffer : function(/*Function*/onSuccess,/*Function*/onFail,/*Function*/onItemStart,/*Function*/onItemEnd) {
-            if (entryList.length > 1) {
-                entryList.sort(function(a, b) {
-                    var nameA = a.entryName.toLowerCase();
-                    var nameB = b.entryName.toLowerCase();
-                    if (nameA > nameB) {return -1}
-                    if (nameA < nameB) {return 1}
-                    return 0;
-                });
-            }
-
-            var totalSize = 0,
-                dataBlock = [],
-                entryHeaders = [],
-                dindex = 0;
-
-            mainHeader.size = 0;
-            mainHeader.offset = 0;
-
-            var compress=function(entryList){
-                var self=arguments.callee;
-                var entry;
-                if(entryList.length){
-                    var entry=entryList.pop();
-                    var name=entry.entryName + entry.extra.toString();
-                    if(onItemStart)onItemStart(name);
-                    entry.getCompressedDataAsync(function(compressedData){
-                        if(onItemEnd)onItemEnd(name);
-
-                        entry.header.offset = dindex;
-                        // data header
-                        var dataHeader = entry.header.dataHeaderToBinary();
-                        var postHeader = new Buffer(name);
-                        var dataLength = dataHeader.length + postHeader.length + compressedData.length;
-
-                        dindex += dataLength;
-
-                        dataBlock.push(dataHeader);
-                        dataBlock.push(postHeader);
-                        dataBlock.push(compressedData);
-
-                        var entryHeader = entry.packHeader();
-                        entryHeaders.push(entryHeader);
-                        mainHeader.size += entryHeader.length;
-                        totalSize += (dataLength + entryHeader.length);
-
-                        if(entryList.length){
-                            self(entryList);
-                        }else{
-
-
-                            totalSize += mainHeader.mainHeaderSize; // also includes zip file comment length
-                            // point to end of data and begining of central directory first record
-                            mainHeader.offset = dindex;
-
-                            dindex = 0;
-                            var outBuffer = new Buffer(totalSize);
-                            dataBlock.forEach(function(content) {
-                                content.copy(outBuffer, dindex); // write data blocks
-                                dindex += content.length;
-                            });
-                            entryHeaders.forEach(function(content) {
-                                content.copy(outBuffer, dindex); // write central directory entries
-                                dindex += content.length;
-                            });
-
-                            var mh = mainHeader.toBinary();
-                            if (_comment) {
-                                _comment.copy(mh, Utils.Constants.ENDHDR); // add zip file comment
-                            }
-
-                            mh.copy(outBuffer, dindex); // write main header
-
-                            onSuccess(outBuffer);
-                        }
-                    });
-                }
-            };
-
-            compress(entryList);
-        }
-    }
-};
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/ansi-regex/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/ansi-regex/package.json
index ef8dbf4..cf8a52d 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/ansi-regex/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/ansi-regex/package.json
@@ -1,41 +1,19 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "ansi-regex@^2.0.0",
-        "scope": null,
-        "escapedName": "ansi-regex",
-        "name": "ansi-regex",
-        "rawSpec": "^2.0.0",
-        "spec": ">=2.0.0 <3.0.0",
-        "type": "range"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/has-ansi"
-    ]
-  ],
-  "_from": "ansi-regex@>=2.0.0 <3.0.0",
+  "_from": "ansi-regex@^2.0.0",
   "_id": "ansi-regex@2.1.1",
-  "_inCache": true,
+  "_inBundle": false,
+  "_integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=",
   "_location": "/ansi-regex",
-  "_nodeVersion": "0.10.32",
-  "_npmOperationalInternal": {
-    "host": "packages-18-east.internal.npmjs.com",
-    "tmp": "tmp/ansi-regex-2.1.1.tgz_1484363378013_0.4482989883981645"
-  },
-  "_npmUser": {
-    "name": "qix",
-    "email": "i.am.qix@gmail.com"
-  },
-  "_npmVersion": "2.14.2",
   "_phantomChildren": {},
   "_requested": {
+    "type": "range",
+    "registry": true,
     "raw": "ansi-regex@^2.0.0",
-    "scope": null,
-    "escapedName": "ansi-regex",
     "name": "ansi-regex",
+    "escapedName": "ansi-regex",
     "rawSpec": "^2.0.0",
-    "spec": ">=2.0.0 <3.0.0",
-    "type": "range"
+    "saveSpec": null,
+    "fetchSpec": "^2.0.0"
   },
   "_requiredBy": [
     "/has-ansi",
@@ -43,9 +21,8 @@
   ],
   "_resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz",
   "_shasum": "c3b33ab5ee360d86e0e628f0468ae7ef27d654df",
-  "_shrinkwrap": null,
   "_spec": "ansi-regex@^2.0.0",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/has-ansi",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/has-ansi",
   "author": {
     "name": "Sindre Sorhus",
     "email": "sindresorhus@gmail.com",
@@ -54,24 +31,19 @@
   "bugs": {
     "url": "https://github.com/chalk/ansi-regex/issues"
   },
-  "dependencies": {},
+  "bundleDependencies": false,
+  "deprecated": false,
   "description": "Regular expression for matching ANSI escape codes",
   "devDependencies": {
     "ava": "0.17.0",
     "xo": "0.16.0"
   },
-  "directories": {},
-  "dist": {
-    "shasum": "c3b33ab5ee360d86e0e628f0468ae7ef27d654df",
-    "tarball": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz"
-  },
   "engines": {
     "node": ">=0.10.0"
   },
   "files": [
     "index.js"
   ],
-  "gitHead": "7c908e7b4eb6cd82bfe1295e33fdf6d166c7ed85",
   "homepage": "https://github.com/chalk/ansi-regex#readme",
   "keywords": [
     "ansi",
@@ -103,17 +75,22 @@
   "license": "MIT",
   "maintainers": [
     {
-      "name": "qix",
-      "email": "i.am.qix@gmail.com"
+      "name": "Sindre Sorhus",
+      "email": "sindresorhus@gmail.com",
+      "url": "sindresorhus.com"
+    },
+    {
+      "name": "Joshua Appelman",
+      "email": "jappelman@xebia.com",
+      "url": "jbnicolai.com"
     },
     {
-      "name": "sindresorhus",
-      "email": "sindresorhus@gmail.com"
+      "name": "JD Ballard",
+      "email": "i.am.qix@gmail.com",
+      "url": "github.com/qix-"
     }
   ],
   "name": "ansi-regex",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+https://github.com/chalk/ansi-regex.git"
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/ansi-styles/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/ansi-styles/package.json
index 68f0c46..e70736e 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/ansi-styles/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/ansi-styles/package.json
@@ -1,50 +1,27 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "ansi-styles@^2.2.1",
-        "scope": null,
-        "escapedName": "ansi-styles",
-        "name": "ansi-styles",
-        "rawSpec": "^2.2.1",
-        "spec": ">=2.2.1 <3.0.0",
-        "type": "range"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/chalk"
-    ]
-  ],
-  "_from": "ansi-styles@>=2.2.1 <3.0.0",
+  "_from": "ansi-styles@^2.2.1",
   "_id": "ansi-styles@2.2.1",
-  "_inCache": true,
+  "_inBundle": false,
+  "_integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=",
   "_location": "/ansi-styles",
-  "_nodeVersion": "4.3.0",
-  "_npmOperationalInternal": {
-    "host": "packages-12-west.internal.npmjs.com",
-    "tmp": "tmp/ansi-styles-2.2.1.tgz_1459197317833_0.9694824463222176"
-  },
-  "_npmUser": {
-    "name": "sindresorhus",
-    "email": "sindresorhus@gmail.com"
-  },
-  "_npmVersion": "3.8.3",
   "_phantomChildren": {},
   "_requested": {
+    "type": "range",
+    "registry": true,
     "raw": "ansi-styles@^2.2.1",
-    "scope": null,
-    "escapedName": "ansi-styles",
     "name": "ansi-styles",
+    "escapedName": "ansi-styles",
     "rawSpec": "^2.2.1",
-    "spec": ">=2.2.1 <3.0.0",
-    "type": "range"
+    "saveSpec": null,
+    "fetchSpec": "^2.2.1"
   },
   "_requiredBy": [
     "/chalk"
   ],
   "_resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz",
   "_shasum": "b432dd3358b634cf75e1e4664368240533c1ddbe",
-  "_shrinkwrap": null,
   "_spec": "ansi-styles@^2.2.1",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/chalk",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/chalk",
   "author": {
     "name": "Sindre Sorhus",
     "email": "sindresorhus@gmail.com",
@@ -53,23 +30,18 @@
   "bugs": {
     "url": "https://github.com/chalk/ansi-styles/issues"
   },
-  "dependencies": {},
+  "bundleDependencies": false,
+  "deprecated": false,
   "description": "ANSI escape codes for styling strings in the terminal",
   "devDependencies": {
     "mocha": "*"
   },
-  "directories": {},
-  "dist": {
-    "shasum": "b432dd3358b634cf75e1e4664368240533c1ddbe",
-    "tarball": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz"
-  },
   "engines": {
     "node": ">=0.10.0"
   },
   "files": [
     "index.js"
   ],
-  "gitHead": "95c59b23be760108b6530ca1c89477c21b258032",
   "homepage": "https://github.com/chalk/ansi-styles#readme",
   "keywords": [
     "ansi",
@@ -96,13 +68,17 @@
   "license": "MIT",
   "maintainers": [
     {
-      "name": "sindresorhus",
-      "email": "sindresorhus@gmail.com"
+      "name": "Sindre Sorhus",
+      "email": "sindresorhus@gmail.com",
+      "url": "sindresorhus.com"
+    },
+    {
+      "name": "Joshua Appelman",
+      "email": "jappelman@xebia.com",
+      "url": "jbnicolai.com"
     }
   ],
   "name": "ansi-styles",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+https://github.com/chalk/ansi-styles.git"
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/array-flatten/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/array-flatten/package.json
index 16d80c2..787a246 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/array-flatten/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/array-flatten/package.json
@@ -1,46 +1,27 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "array-flatten@1.1.1",
-        "scope": null,
-        "escapedName": "array-flatten",
-        "name": "array-flatten",
-        "rawSpec": "1.1.1",
-        "spec": "1.1.1",
-        "type": "version"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/express"
-    ]
-  ],
   "_from": "array-flatten@1.1.1",
   "_id": "array-flatten@1.1.1",
-  "_inCache": true,
+  "_inBundle": false,
+  "_integrity": "sha1-ml9pkFGx5wczKPKgCJaLZOopVdI=",
   "_location": "/array-flatten",
-  "_nodeVersion": "2.3.3",
-  "_npmUser": {
-    "name": "blakeembrey",
-    "email": "hello@blakeembrey.com"
-  },
-  "_npmVersion": "2.11.3",
   "_phantomChildren": {},
   "_requested": {
+    "type": "version",
+    "registry": true,
     "raw": "array-flatten@1.1.1",
-    "scope": null,
-    "escapedName": "array-flatten",
     "name": "array-flatten",
+    "escapedName": "array-flatten",
     "rawSpec": "1.1.1",
-    "spec": "1.1.1",
-    "type": "version"
+    "saveSpec": null,
+    "fetchSpec": "1.1.1"
   },
   "_requiredBy": [
     "/express"
   ],
   "_resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz",
   "_shasum": "9a5f699051b1e7073328f2a008968b64ea2955d2",
-  "_shrinkwrap": null,
   "_spec": "array-flatten@1.1.1",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/express",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/express",
   "author": {
     "name": "Blake Embrey",
     "email": "hello@blakeembrey.com",
@@ -49,7 +30,8 @@
   "bugs": {
     "url": "https://github.com/blakeembrey/array-flatten/issues"
   },
-  "dependencies": {},
+  "bundleDependencies": false,
+  "deprecated": false,
   "description": "Flatten an array of nested arrays into a single flat array",
   "devDependencies": {
     "istanbul": "^0.3.13",
@@ -57,16 +39,10 @@
     "pre-commit": "^1.0.7",
     "standard": "^3.7.3"
   },
-  "directories": {},
-  "dist": {
-    "shasum": "9a5f699051b1e7073328f2a008968b64ea2955d2",
-    "tarball": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz"
-  },
   "files": [
     "array-flatten.js",
     "LICENSE"
   ],
-  "gitHead": "1963a9189229d408e1e8f585a00c8be9edbd1803",
   "homepage": "https://github.com/blakeembrey/array-flatten",
   "keywords": [
     "array",
@@ -76,15 +52,7 @@
   ],
   "license": "MIT",
   "main": "array-flatten.js",
-  "maintainers": [
-    {
-      "name": "blakeembrey",
-      "email": "hello@blakeembrey.com"
-    }
-  ],
   "name": "array-flatten",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git://github.com/blakeembrey/array-flatten.git"
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/History.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/History.md
index 559e063..13d463a 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/History.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/History.md
@@ -1,3 +1,20 @@
+3.0.0 / 2017-08-31
+==================
+
+  * Change "kB" to "KB" in format output
+  * Remove support for Node.js 0.6
+  * Remove support for ComponentJS
+
+2.5.0 / 2017-03-24
+==================
+
+  * Add option "unit"
+
+2.4.0 / 2016-06-01
+==================
+
+  * Add option "unitSeparator"
+
 2.3.0 / 2016-02-15
 ==================
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/Readme.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/Readme.md
index dd19ff2..9b53745 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/Readme.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/Readme.md
@@ -3,24 +3,35 @@
 [![NPM Version][npm-image]][npm-url]
 [![NPM Downloads][downloads-image]][downloads-url]
 [![Build Status][travis-image]][travis-url]
+[![Test Coverage][coveralls-image]][coveralls-url]
 
 Utility to parse a string bytes (ex: `1TB`) to bytes (`1099511627776`) and vice-versa.
 
+## Installation
+
+This is a [Node.js](https://nodejs.org/en/) module available through the
+[npm registry](https://www.npmjs.com/). Installation is done using the
+[`npm install` command](https://docs.npmjs.com/getting-started/installing-npm-packages-locally):
+
+```bash
+$ npm install bytes
+```
+
 ## Usage
 
 ```js
 var bytes = require('bytes');
 ```
 
-#### bytes.format(number value, [options]): string|null
+#### bytes.format(number value, [options]): string|null
 
 Format the given value in bytes into a string. If the value is negative, it is kept as such. If it is a float, it is
  rounded.
 
 **Arguments**
 
-| Name    | Type   | Description        |
-|---------|--------|--------------------|
+| Name    | Type     | Description        |
+|---------|----------|--------------------|
 | value   | `number` | Value in bytes     |
 | options | `Object` | Conversion options |
 
@@ -28,21 +39,23 @@ Format the given value in bytes into a string. If the value is negative, it is k
 
 | Property          | Type   | Description                                                                             |
 |-------------------|--------|-----------------------------------------------------------------------------------------|
-| decimalPlaces | `number`&#124;`null` | Maximum number of decimal places to include in output. Default value to `2`. |
-| fixedDecimals | `boolean`&#124;`null` | Whether to always display the maximum number of decimal places. Default value to `false` |
-| thousandsSeparator | `string`&#124;`null` | Example of values: `' '`, `','` and `.`... Default value to `' '`. |
+| decimalPlaces | `number`|`null` | Maximum number of decimal places to include in output. Default value to `2`. |
+| fixedDecimals | `boolean`|`null` | Whether to always display the maximum number of decimal places. Default value to `false` |
+| thousandsSeparator | `string`|`null` | Example of values: `' '`, `','` and `.`... Default value to `''`. |
+| unit | `string`|`null` | The unit in which the result will be returned (B/KB/MB/GB/TB). Default value to `''` (which means auto detect). |
+| unitSeparator | `string`|`null` | Separator to use between number and unit. Default value to `''`. |
 
 **Returns**
 
-| Name    | Type        | Description             |
-|---------|-------------|-------------------------|
-| results | `string`&#124;`null` | Return null upon error. String value otherwise. |
+| Name    | Type             | Description                                     |
+|---------|------------------|-------------------------------------------------|
+| results | `string`|`null` | Return null upon error. String value otherwise. |
 
 **Example**
 
 ```js
 bytes(1024);
-// output: '1kB'
+// output: '1KB'
 
 bytes(1000);
 // output: '1000B'
@@ -51,20 +64,25 @@ bytes(1000, {thousandsSeparator: ' '});
 // output: '1 000B'
 
 bytes(1024 * 1.7, {decimalPlaces: 0});
-// output: '2kB'
+// output: '2KB'
+
+bytes(1024, {unitSeparator: ' '});
+// output: '1 KB'
+
 ```
 
-#### bytes.parse(string value): number|null
+#### bytes.parse(string|number value): number|null
 
-Parse the string value into an integer in bytes. If no unit is given, it is assumed the value is in bytes.
+Parse the string value into an integer in bytes. If no unit is given, or `value`
+is a number, it is assumed the value is in bytes.
 
 Supported units and abbreviations are as follows and are case-insensitive:
 
-  * "b" for bytes
-  * "kb" for kilobytes
-  * "mb" for megabytes
-  * "gb" for gigabytes
-  * "tb" for terabytes
+  * `b` for bytes
+  * `kb` for kilobytes
+  * `mb` for megabytes
+  * `gb` for gigabytes
+  * `tb` for terabytes
 
 The units are in powers of two, not ten. This means 1kb = 1024b according to this parser.
 
@@ -72,34 +90,30 @@ The units are in powers of two, not ten. This means 1kb = 1024b according to thi
 
 | Name          | Type   | Description        |
 |---------------|--------|--------------------|
-| value   | `string` | String to parse.   |
+| value   | `string`|`number` | String to parse, or number in bytes.   |
 
 **Returns**
 
 | Name    | Type        | Description             |
 |---------|-------------|-------------------------|
-| results | `number`&#124;`null` | Return null upon error. Value in bytes otherwise. |
+| results | `number`|`null` | Return null upon error. Value in bytes otherwise. |
 
 **Example**
 
 ```js
-bytes('1kB');
+bytes('1KB');
 // output: 1024
 
 bytes('1024');
 // output: 1024
-```
-
-## Installation
 
-```bash
-npm install bytes --save
-component install visionmedia/bytes.js
+bytes(1024);
+// output: 1024
 ```
 
 ## License 
 
-[![npm](https://img.shields.io/npm/l/express.svg)](https://github.com/visionmedia/bytes.js/blob/master/LICENSE)
+[MIT](LICENSE)
 
 [downloads-image]: https://img.shields.io/npm/dm/bytes.svg
 [downloads-url]: https://npmjs.org/package/bytes
@@ -107,3 +121,5 @@ component install visionmedia/bytes.js
 [npm-url]: https://npmjs.org/package/bytes
 [travis-image]: https://img.shields.io/travis/visionmedia/bytes.js/master.svg
 [travis-url]: https://travis-ci.org/visionmedia/bytes.js
+[coveralls-image]: https://img.shields.io/coveralls/visionmedia/bytes.js/master.svg
+[coveralls-url]: https://coveralls.io/r/visionmedia/bytes.js?branch=master
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/index.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/index.js
index f71cca7..1e39afd 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/index.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/index.js
@@ -33,9 +33,6 @@ var map = {
   tb: ((1 << 30) * 1024)
 };
 
-// TODO: use is-finite module?
-var numberIsFinite = Number.isFinite || function (v) { return typeof v === 'number' && isFinite(v); };
-
 var parseRegExp = /^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb)$/i;
 
 /**
@@ -47,6 +44,7 @@ var parseRegExp = /^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb)$/i;
  *  decimalPlaces: [number]
  *  fixedDecimals: [boolean]
  *  thousandsSeparator: [string]
+ *  unitSeparator: [string]
  *  }} [options] bytes options.
  *
  * @returns {string|number|null}
@@ -75,30 +73,37 @@ function bytes(value, options) {
  * @param {number} [options.decimalPlaces=2]
  * @param {number} [options.fixedDecimals=false]
  * @param {string} [options.thousandsSeparator=]
+ * @param {string} [options.unit=]
+ * @param {string} [options.unitSeparator=]
  *
  * @returns {string|null}
  * @public
  */
 
 function format(value, options) {
-  if (!numberIsFinite(value)) {
+  if (!Number.isFinite(value)) {
     return null;
   }
 
   var mag = Math.abs(value);
   var thousandsSeparator = (options && options.thousandsSeparator) || '';
+  var unitSeparator = (options && options.unitSeparator) || '';
   var decimalPlaces = (options && options.decimalPlaces !== undefined) ? options.decimalPlaces : 2;
   var fixedDecimals = Boolean(options && options.fixedDecimals);
-  var unit = 'B';
-
-  if (mag >= map.tb) {
-    unit = 'TB';
-  } else if (mag >= map.gb) {
-    unit = 'GB';
-  } else if (mag >= map.mb) {
-    unit = 'MB';
-  } else if (mag >= map.kb) {
-    unit = 'kB';
+  var unit = (options && options.unit) || '';
+
+  if (!unit || !map[unit.toLowerCase()]) {
+    if (mag >= map.tb) {
+      unit = 'TB';
+    } else if (mag >= map.gb) {
+      unit = 'GB';
+    } else if (mag >= map.mb) {
+      unit = 'MB';
+    } else if (mag >= map.kb) {
+      unit = 'KB';
+    } else {
+      unit = 'B';
+    }
   }
 
   var val = value / map[unit.toLowerCase()];
@@ -112,7 +117,7 @@ function format(value, options) {
     str = str.replace(formatThousandsRegExp, thousandsSeparator);
   }
 
-  return str + unit;
+  return str + unitSeparator + unit;
 }
 
 /**
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/package.json
index 19ad7cc..f6f3888 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/bytes/package.json
@@ -1,50 +1,29 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "bytes@2.3.0",
-        "scope": null,
-        "escapedName": "bytes",
-        "name": "bytes",
-        "rawSpec": "2.3.0",
-        "spec": "2.3.0",
-        "type": "version"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/compression"
-    ]
-  ],
-  "_from": "bytes@2.3.0",
-  "_id": "bytes@2.3.0",
-  "_inCache": true,
+  "_from": "bytes@3.0.0",
+  "_id": "bytes@3.0.0",
+  "_inBundle": false,
+  "_integrity": "sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg=",
   "_location": "/bytes",
-  "_nodeVersion": "4.2.3",
-  "_npmOperationalInternal": {
-    "host": "packages-6-west.internal.npmjs.com",
-    "tmp": "tmp/bytes-2.3.0.tgz_1455595208428_0.5990735022351146"
-  },
-  "_npmUser": {
-    "name": "dougwilson",
-    "email": "doug@somethingdoug.com"
-  },
-  "_npmVersion": "2.14.7",
   "_phantomChildren": {},
   "_requested": {
-    "raw": "bytes@2.3.0",
-    "scope": null,
-    "escapedName": "bytes",
+    "type": "version",
+    "registry": true,
+    "raw": "bytes@3.0.0",
     "name": "bytes",
-    "rawSpec": "2.3.0",
-    "spec": "2.3.0",
-    "type": "version"
+    "escapedName": "bytes",
+    "rawSpec": "3.0.0",
+    "saveSpec": null,
+    "fetchSpec": "3.0.0"
   },
   "_requiredBy": [
-    "/compression"
+    "/body-parser",
+    "/compression",
+    "/raw-body"
   ],
-  "_resolved": "https://registry.npmjs.org/bytes/-/bytes-2.3.0.tgz",
-  "_shasum": "d5b680a165b6201739acb611542aabc2d8ceb070",
-  "_shrinkwrap": null,
-  "_spec": "bytes@2.3.0",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/compression",
+  "_resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz",
+  "_shasum": "d32815404d689699f85a4ea4fa8755dd13a96048",
+  "_spec": "bytes@3.0.0",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/compression",
   "author": {
     "name": "TJ Holowaychuk",
     "email": "tj@vision-media.ca",
@@ -53,11 +32,7 @@
   "bugs": {
     "url": "https://github.com/visionmedia/bytes.js/issues"
   },
-  "component": {
-    "scripts": {
-      "bytes/index.js": "index.js"
-    }
-  },
+  "bundleDependencies": false,
   "contributors": [
     {
       "name": "Jed Watson",
@@ -68,15 +43,14 @@
       "email": "theo.fidry@gmail.com"
     }
   ],
-  "dependencies": {},
+  "deprecated": false,
   "description": "Utility to parse a string bytes to bytes and vice-versa",
   "devDependencies": {
-    "mocha": "1.21.5"
+    "mocha": "2.5.3",
+    "nyc": "10.3.2"
   },
-  "directories": {},
-  "dist": {
-    "shasum": "d5b680a165b6201739acb611542aabc2d8ceb070",
-    "tarball": "https://registry.npmjs.org/bytes/-/bytes-2.3.0.tgz"
+  "engines": {
+    "node": ">= 0.8"
   },
   "files": [
     "History.md",
@@ -84,7 +58,6 @@
     "Readme.md",
     "index.js"
   ],
-  "gitHead": "c8be41b24b04e04992d5918356d5a4dd35fbf805",
   "homepage": "https://github.com/visionmedia/bytes.js#readme",
   "keywords": [
     "byte",
@@ -96,25 +69,15 @@
     "converter"
   ],
   "license": "MIT",
-  "maintainers": [
-    {
-      "name": "dougwilson",
-      "email": "doug@somethingdoug.com"
-    },
-    {
-      "name": "tjholowaychuk",
-      "email": "tj@vision-media.ca"
-    }
-  ],
   "name": "bytes",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+https://github.com/visionmedia/bytes.js.git"
   },
   "scripts": {
-    "test": "mocha --check-leaks --reporter spec"
+    "test": "mocha --check-leaks --reporter spec",
+    "test-ci": "nyc --reporter=text npm test",
+    "test-cov": "nyc --reporter=html --reporter=text npm test"
   },
-  "version": "2.3.0"
+  "version": "3.0.0"
 }
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/chalk/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/chalk/package.json
index 6056177..f578c43 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/chalk/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/chalk/package.json
@@ -1,53 +1,31 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "chalk@^1.1.1",
-        "scope": null,
-        "escapedName": "chalk",
-        "name": "chalk",
-        "rawSpec": "^1.1.1",
-        "spec": ">=1.1.1 <2.0.0",
-        "type": "range"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/cordova-serve"
-    ]
-  ],
-  "_from": "chalk@>=1.1.1 <2.0.0",
+  "_from": "chalk@^1.1.1",
   "_id": "chalk@1.1.3",
-  "_inCache": true,
+  "_inBundle": false,
+  "_integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=",
   "_location": "/chalk",
-  "_nodeVersion": "0.10.32",
-  "_npmOperationalInternal": {
-    "host": "packages-12-west.internal.npmjs.com",
-    "tmp": "tmp/chalk-1.1.3.tgz_1459210604109_0.3892582862172276"
-  },
-  "_npmUser": {
-    "name": "qix",
-    "email": "i.am.qix@gmail.com"
-  },
-  "_npmVersion": "2.14.2",
   "_phantomChildren": {},
   "_requested": {
+    "type": "range",
+    "registry": true,
     "raw": "chalk@^1.1.1",
-    "scope": null,
-    "escapedName": "chalk",
     "name": "chalk",
+    "escapedName": "chalk",
     "rawSpec": "^1.1.1",
-    "spec": ">=1.1.1 <2.0.0",
-    "type": "range"
+    "saveSpec": null,
+    "fetchSpec": "^1.1.1"
   },
   "_requiredBy": [
     "/cordova-serve"
   ],
   "_resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
   "_shasum": "a8115c55e4a702fe4d150abd3872822a7e09fc98",
-  "_shrinkwrap": null,
   "_spec": "chalk@^1.1.1",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/cordova-serve",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/cordova-serve",
   "bugs": {
     "url": "https://github.com/chalk/chalk/issues"
   },
+  "bundleDependencies": false,
   "dependencies": {
     "ansi-styles": "^2.2.1",
     "escape-string-regexp": "^1.0.2",
@@ -55,6 +33,7 @@
     "strip-ansi": "^3.0.0",
     "supports-color": "^2.0.0"
   },
+  "deprecated": false,
   "description": "Terminal string styling done right. Much color.",
   "devDependencies": {
     "coveralls": "^2.11.2",
@@ -66,18 +45,12 @@
     "semver": "^4.3.3",
     "xo": "*"
   },
-  "directories": {},
-  "dist": {
-    "shasum": "a8115c55e4a702fe4d150abd3872822a7e09fc98",
-    "tarball": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz"
-  },
   "engines": {
     "node": ">=0.10.0"
   },
   "files": [
     "index.js"
   ],
-  "gitHead": "0d8d8c204eb87a4038219131ad4d8369c9f59d24",
   "homepage": "https://github.com/chalk/chalk#readme",
   "keywords": [
     "color",
@@ -105,21 +78,22 @@
   "license": "MIT",
   "maintainers": [
     {
-      "name": "qix",
-      "email": "i.am.qix@gmail.com"
+      "name": "Sindre Sorhus",
+      "email": "sindresorhus@gmail.com",
+      "url": "sindresorhus.com"
     },
     {
-      "name": "sindresorhus",
-      "email": "sindresorhus@gmail.com"
+      "name": "Joshua Appelman",
+      "email": "jappelman@xebia.com",
+      "url": "jbnicolai.com"
     },
     {
-      "name": "unicorn",
-      "email": "sindresorhus+unicorn@gmail.com"
+      "name": "JD Ballard",
+      "email": "i.am.qix@gmail.com",
+      "url": "github.com/qix-"
     }
   ],
   "name": "chalk",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+https://github.com/chalk/chalk.git"
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/HISTORY.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/HISTORY.md
index 6896784..a4d38d1 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/HISTORY.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/HISTORY.md
@@ -1,3 +1,18 @@
+2.0.12 / 2017-10-20
+===================
+
+  * deps: mime-db@'>= 1.30.0 < 2'
+
+2.0.11 / 2017-07-27
+===================
+
+  * deps: mime-db@'>= 1.29.0 < 2'
+
+2.0.10 / 2017-03-23
+===================
+
+  * deps: mime-db@'>= 1.27.0 < 2'
+
 2.0.9 / 2016-10-31
 ==================
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/README.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/README.md
index 6d8699d..4402937 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/README.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/README.md
@@ -10,12 +10,14 @@ Compressible `Content-Type` / `mime` checking.
 
 ## Installation
 
-```bash
+```sh
 $ npm install compressible
 ```
 
 ## API
 
+<!-- eslint-disable no-unused-vars -->
+
 ```js
 var compressible = require('compressible')
 ```
@@ -37,6 +39,8 @@ this module will fallback to `true` for the following types:
 If this module is not sure if a type is specifically compressible or specifically
 uncompressible, `undefined` is returned.
 
+<!-- eslint-disable no-undef -->
+
 ```js
 compressible('text/html') // => true
 compressible('image/png') // => false
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/index.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/index.js
index bf14ad7..1184ada 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/index.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/index.js
@@ -20,8 +20,8 @@ var db = require('mime-db')
  * @private
  */
 
-var compressibleTypeRegExp = /^text\/|\+json$|\+text$|\+xml$/i
-var extractTypeRegExp = /^\s*([^;\s]*)(?:;|\s|$)/
+var COMPRESSIBLE_TYPE_REGEXP = /^text\/|\+(?:json|text|xml)$/i
+var EXTRACT_TYPE_REGEXP = /^\s*([^;\s]*)(?:;|\s|$)/
 
 /**
  * Module exports.
@@ -44,7 +44,7 @@ function compressible (type) {
   }
 
   // strip parameters
-  var match = extractTypeRegExp.exec(type)
+  var match = EXTRACT_TYPE_REGEXP.exec(type)
   var mime = match && match[1].toLowerCase()
   var data = db[mime]
 
@@ -54,5 +54,5 @@ function compressible (type) {
   }
 
   // fallback to regexp or unknown
-  return compressibleTypeRegExp.test(mime) || undefined
+  return COMPRESSIBLE_TYPE_REGEXP.test(mime) || undefined
 }
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/package.json
index 404f4d1..27d871a 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compressible/package.json
@@ -1,52 +1,31 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "compressible@~2.0.8",
-        "scope": null,
-        "escapedName": "compressible",
-        "name": "compressible",
-        "rawSpec": "~2.0.8",
-        "spec": ">=2.0.8 <2.1.0",
-        "type": "range"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/compression"
-    ]
-  ],
-  "_from": "compressible@>=2.0.8 <2.1.0",
-  "_id": "compressible@2.0.9",
-  "_inCache": true,
+  "_from": "compressible@~2.0.11",
+  "_id": "compressible@2.0.12",
+  "_inBundle": false,
+  "_integrity": "sha1-xZpcmdt2dn6YdlAOJx72OzSTvWY=",
   "_location": "/compressible",
-  "_npmOperationalInternal": {
-    "host": "packages-18-east.internal.npmjs.com",
-    "tmp": "tmp/compressible-2.0.9.tgz_1477956262136_0.9366124230436981"
-  },
-  "_npmUser": {
-    "name": "dougwilson",
-    "email": "doug@somethingdoug.com"
-  },
-  "_npmVersion": "1.4.28",
   "_phantomChildren": {},
   "_requested": {
-    "raw": "compressible@~2.0.8",
-    "scope": null,
-    "escapedName": "compressible",
+    "type": "range",
+    "registry": true,
+    "raw": "compressible@~2.0.11",
     "name": "compressible",
-    "rawSpec": "~2.0.8",
-    "spec": ">=2.0.8 <2.1.0",
-    "type": "range"
+    "escapedName": "compressible",
+    "rawSpec": "~2.0.11",
+    "saveSpec": null,
+    "fetchSpec": "~2.0.11"
   },
   "_requiredBy": [
     "/compression"
   ],
-  "_resolved": "https://registry.npmjs.org/compressible/-/compressible-2.0.9.tgz",
-  "_shasum": "6daab4e2b599c2770dd9e21e7a891b1c5a755425",
-  "_shrinkwrap": null,
-  "_spec": "compressible@~2.0.8",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/compression",
+  "_resolved": "https://registry.npmjs.org/compressible/-/compressible-2.0.12.tgz",
+  "_shasum": "c59a5c99db76767e9876500e271ef63b3493bd66",
+  "_spec": "compressible@~2.0.11",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/compression",
   "bugs": {
     "url": "https://github.com/jshttp/compressible/issues"
   },
+  "bundleDependencies": false,
   "contributors": [
     {
       "name": "Douglas Christopher Wilson",
@@ -64,21 +43,20 @@
     }
   ],
   "dependencies": {
-    "mime-db": ">= 1.24.0 < 2"
+    "mime-db": ">= 1.30.0 < 2"
   },
+  "deprecated": false,
   "description": "Compressible Content-Type / mime checking",
   "devDependencies": {
-    "eslint": "3.9.1",
-    "eslint-config-standard": "6.2.1",
-    "eslint-plugin-promise": "3.3.0",
-    "eslint-plugin-standard": "2.0.1",
-    "istanbul": "0.4.5",
-    "mocha": "~1.21.5"
-  },
-  "directories": {},
-  "dist": {
-    "shasum": "6daab4e2b599c2770dd9e21e7a891b1c5a755425",
-    "tarball": "https://registry.npmjs.org/compressible/-/compressible-2.0.9.tgz"
+    "eslint": "3.19.0",
+    "eslint-config-standard": "10.2.1",
+    "eslint-plugin-import": "2.7.0",
+    "eslint-plugin-markdown": "1.0.0-beta.6",
+    "eslint-plugin-node": "5.2.0",
+    "eslint-plugin-promise": "3.6.0",
+    "eslint-plugin-standard": "3.0.1",
+    "mocha": "~1.21.5",
+    "nyc": "11.2.1"
   },
   "engines": {
     "node": ">= 0.6"
@@ -89,8 +67,7 @@
     "README.md",
     "index.js"
   ],
-  "gitHead": "9e750e00d459f01b9a16df504f87ad829bf2a518",
-  "homepage": "https://github.com/jshttp/compressible",
+  "homepage": "https://github.com/jshttp/compressible#readme",
   "keywords": [
     "compress",
     "gzip",
@@ -98,48 +75,16 @@
     "content-type"
   ],
   "license": "MIT",
-  "maintainers": [
-    {
-      "name": "defunctzombie",
-      "email": "shtylman@gmail.com"
-    },
-    {
-      "name": "dougwilson",
-      "email": "doug@somethingdoug.com"
-    },
-    {
-      "name": "federomero",
-      "email": "federomero@gmail.com"
-    },
-    {
-      "name": "fishrock123",
-      "email": "fishrock123@rocketmail.com"
-    },
-    {
-      "name": "jongleberry",
-      "email": "jonathanrichardong@gmail.com"
-    },
-    {
-      "name": "mscdex",
-      "email": "mscdex@mscdex.net"
-    },
-    {
-      "name": "tjholowaychuk",
-      "email": "tj@vision-media.ca"
-    }
-  ],
   "name": "compressible",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+https://github.com/jshttp/compressible.git"
   },
   "scripts": {
-    "lint": "eslint .",
+    "lint": "eslint --plugin markdown --ext js,md .",
     "test": "mocha --reporter spec --bail --check-leaks test/",
-    "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks",
-    "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot --check-leaks"
+    "test-cov": "nyc --reporter=html --reporter=text npm test",
+    "test-travis": "nyc --reporter=text npm test"
   },
-  "version": "2.0.9"
+  "version": "2.0.12"
 }
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/HISTORY.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/HISTORY.md
index 663f0de..3cb6fbb 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/HISTORY.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/HISTORY.md
@@ -1,3 +1,33 @@
+1.7.1 / 2017-09-26
+==================
+
+  * deps: accepts@~1.3.4
+    - deps: mime-types@~2.1.16
+  * deps: bytes@3.0.0
+  * deps: compressible@~2.0.11
+    - deps: mime-db@'>= 1.29.0 < 2'
+  * deps: debug@2.6.9
+  * deps: vary@~1.1.2
+    - perf: improve header token parsing speed
+
+1.7.0 / 2017-07-10
+==================
+
+  * Use `safe-buffer` for improved Buffer API
+  * deps: bytes@2.5.0
+  * deps: compressible@~2.0.10
+    - Fix regex fallback to not override `compressible: false` in db
+    - deps: mime-db@'>= 1.27.0 < 2'
+  * deps: debug@2.6.8
+    - Allow colors in workers
+    - Deprecated `DEBUG_FD` environment variable set to `3` or higher
+    - Fix error when running under React Native
+    - Fix `DEBUG_MAX_ARRAY_LENGTH`
+    - Use same color for same namespace
+    - deps: ms@2.0.0
+  * deps: vary@~1.1.1
+    - perf: hoist regular expression
+
 1.6.2 / 2016-05-12
 ==================
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/README.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/README.md
index a5d599d..662ba53 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/README.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/README.md
@@ -15,12 +15,18 @@ The following compression codings are supported:
 
 ## Install
 
+This is a [Node.js](https://nodejs.org/en/) module available through the
+[npm registry](https://www.npmjs.com/). Installation is done using the
+[`npm install` command](https://docs.npmjs.com/getting-started/installing-npm-packages-locally):
+
 ```bash
 $ npm install compression
 ```
 
 ## API
 
+<!-- eslint-disable no-unused-vars -->
+
 ```js
 var compression = require('compression')
 ```
@@ -142,9 +148,13 @@ The default `filter` function. This is used to construct a custom filter
 function that is an extension of the default function.
 
 ```js
+var compression = require('compression')
+var express = require('express')
+
+var app = express()
 app.use(compression({filter: shouldCompress}))
 
-function shouldCompress(req, res) {
+function shouldCompress (req, res) {
   if (req.headers['x-no-compression']) {
     // don't compress responses with this request header
     return false
@@ -173,7 +183,7 @@ var express = require('express')
 
 var app = express()
 
-// compress all requests
+// compress all responses
 app.use(compression())
 
 // add all routes
@@ -191,7 +201,7 @@ actually make it to the client.
 
 ```js
 var compression = require('compression')
-var express     = require('express')
+var express = require('express')
 
 var app = express()
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/index.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/index.js
index c0e801e..f190c68 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/index.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/index.js
@@ -15,6 +15,7 @@
  */
 
 var accepts = require('accepts')
+var Buffer = require('safe-buffer').Buffer
 var bytes = require('bytes')
 var compressible = require('compressible')
 var debug = require('debug')('compression')
@@ -84,7 +85,7 @@ function compression (options) {
       }
 
       return stream
-        ? stream.write(new Buffer(chunk, encoding))
+        ? stream.write(Buffer.from(chunk, encoding))
         : _write.call(this, chunk, encoding)
     }
 
@@ -111,7 +112,7 @@ function compression (options) {
 
       // write Buffer for Node.js 0.8
       return chunk
-        ? stream.end(new Buffer(chunk, encoding))
+        ? stream.end(Buffer.from(chunk, encoding))
         : stream.end()
     }
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/package.json
index 1b339ba..e88fa64 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/compression/package.json
@@ -1,53 +1,31 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "compression@^1.6.0",
-        "scope": null,
-        "escapedName": "compression",
-        "name": "compression",
-        "rawSpec": "^1.6.0",
-        "spec": ">=1.6.0 <2.0.0",
-        "type": "range"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/cordova-serve"
-    ]
-  ],
-  "_from": "compression@>=1.6.0 <2.0.0",
-  "_id": "compression@1.6.2",
-  "_inCache": true,
+  "_from": "compression@^1.6.0",
+  "_id": "compression@1.7.1",
+  "_inBundle": false,
+  "_integrity": "sha1-7/JgPvwuIs+G810uuTWJ+YdTc9s=",
   "_location": "/compression",
-  "_nodeVersion": "4.4.3",
-  "_npmOperationalInternal": {
-    "host": "packages-12-west.internal.npmjs.com",
-    "tmp": "tmp/compression-1.6.2.tgz_1463095977791_0.03453603922389448"
-  },
-  "_npmUser": {
-    "name": "dougwilson",
-    "email": "doug@somethingdoug.com"
-  },
-  "_npmVersion": "2.15.1",
   "_phantomChildren": {},
   "_requested": {
+    "type": "range",
+    "registry": true,
     "raw": "compression@^1.6.0",
-    "scope": null,
-    "escapedName": "compression",
     "name": "compression",
+    "escapedName": "compression",
     "rawSpec": "^1.6.0",
-    "spec": ">=1.6.0 <2.0.0",
-    "type": "range"
+    "saveSpec": null,
+    "fetchSpec": "^1.6.0"
   },
   "_requiredBy": [
     "/cordova-serve"
   ],
-  "_resolved": "https://registry.npmjs.org/compression/-/compression-1.6.2.tgz",
-  "_shasum": "cceb121ecc9d09c52d7ad0c3350ea93ddd402bc3",
-  "_shrinkwrap": null,
+  "_resolved": "https://registry.npmjs.org/compression/-/compression-1.7.1.tgz",
+  "_shasum": "eff2603efc2e22cf86f35d2eb93589f9875373db",
   "_spec": "compression@^1.6.0",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/cordova-serve",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/cordova-serve",
   "bugs": {
     "url": "https://github.com/expressjs/compression/issues"
   },
+  "bundleDependencies": false,
   "contributors": [
     {
       "name": "Douglas Christopher Wilson",
@@ -60,28 +38,28 @@
     }
   ],
   "dependencies": {
-    "accepts": "~1.3.3",
-    "bytes": "2.3.0",
-    "compressible": "~2.0.8",
-    "debug": "~2.2.0",
+    "accepts": "~1.3.4",
+    "bytes": "3.0.0",
+    "compressible": "~2.0.11",
+    "debug": "2.6.9",
     "on-headers": "~1.0.1",
-    "vary": "~1.1.0"
+    "safe-buffer": "5.1.1",
+    "vary": "~1.1.2"
   },
+  "deprecated": false,
   "description": "Node.js compression middleware",
   "devDependencies": {
-    "eslint": "2.9.0",
-    "eslint-config-standard": "5.3.1",
-    "eslint-plugin-promise": "1.1.0",
-    "eslint-plugin-standard": "1.3.2",
-    "istanbul": "0.4.3",
-    "mocha": "2.4.5",
+    "eslint": "3.19.0",
+    "eslint-config-standard": "10.2.1",
+    "eslint-plugin-import": "2.7.0",
+    "eslint-plugin-markdown": "1.0.0-beta.6",
+    "eslint-plugin-node": "5.1.1",
+    "eslint-plugin-promise": "3.5.0",
+    "eslint-plugin-standard": "3.0.1",
+    "istanbul": "0.4.5",
+    "mocha": "2.5.3",
     "supertest": "1.1.0"
   },
-  "directories": {},
-  "dist": {
-    "shasum": "cceb121ecc9d09c52d7ad0c3350ea93ddd402bc3",
-    "tarball": "https://registry.npmjs.org/compression/-/compression-1.6.2.tgz"
-  },
   "engines": {
     "node": ">= 0.8.0"
   },
@@ -90,27 +68,18 @@
     "HISTORY.md",
     "index.js"
   ],
-  "gitHead": "b9c63ced82b9f719cd5d9fd250c8432b00752d89",
   "homepage": "https://github.com/expressjs/compression#readme",
   "license": "MIT",
-  "maintainers": [
-    {
-      "name": "dougwilson",
-      "email": "doug@somethingdoug.com"
-    }
-  ],
   "name": "compression",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+https://github.com/expressjs/compression.git"
   },
   "scripts": {
-    "lint": "eslint **/*.js",
+    "lint": "eslint --plugin markdown --ext js,md .",
     "test": "mocha --check-leaks --reporter spec --bail",
     "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --check-leaks --reporter dot",
     "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --check-leaks --reporter spec"
   },
-  "version": "1.6.2"
+  "version": "1.7.1"
 }
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-disposition/package.json b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-disposition/package.json
index 51dc2d9..1d2ad51 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-disposition/package.json
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-disposition/package.json
@@ -1,60 +1,38 @@
 {
-  "_args": [
-    [
-      {
-        "raw": "content-disposition@0.5.2",
-        "scope": null,
-        "escapedName": "content-disposition",
-        "name": "content-disposition",
-        "rawSpec": "0.5.2",
-        "spec": "0.5.2",
-        "type": "version"
-      },
-      "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/express"
-    ]
-  ],
   "_from": "content-disposition@0.5.2",
   "_id": "content-disposition@0.5.2",
-  "_inCache": true,
+  "_inBundle": false,
+  "_integrity": "sha1-DPaLud318r55YcOoUXjLhdunjLQ=",
   "_location": "/content-disposition",
-  "_nodeVersion": "4.6.0",
-  "_npmOperationalInternal": {
-    "host": "packages-18-east.internal.npmjs.com",
-    "tmp": "tmp/content-disposition-0.5.2.tgz_1481246224565_0.35659545403905213"
-  },
-  "_npmUser": {
-    "name": "dougwilson",
-    "email": "doug@somethingdoug.com"
-  },
-  "_npmVersion": "2.15.9",
   "_phantomChildren": {},
   "_requested": {
+    "type": "version",
+    "registry": true,
     "raw": "content-disposition@0.5.2",
-    "scope": null,
-    "escapedName": "content-disposition",
     "name": "content-disposition",
+    "escapedName": "content-disposition",
     "rawSpec": "0.5.2",
-    "spec": "0.5.2",
-    "type": "version"
+    "saveSpec": null,
+    "fetchSpec": "0.5.2"
   },
   "_requiredBy": [
     "/express"
   ],
   "_resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.2.tgz",
   "_shasum": "0cf68bb9ddf5f2be7961c3a85178cb85dba78cb4",
-  "_shrinkwrap": null,
   "_spec": "content-disposition@0.5.2",
-  "_where": "/Users/auso/cordova/cordova-lib/cordova-lib/spec-cordova/fixtures/platforms/cordova-browser/node_modules/express",
+  "_where": "/Users/auso/cordova/cordova-browser/node_modules/express",
   "bugs": {
     "url": "https://github.com/jshttp/content-disposition/issues"
   },
+  "bundleDependencies": false,
   "contributors": [
     {
       "name": "Douglas Christopher Wilson",
       "email": "doug@somethingdoug.com"
     }
   ],
-  "dependencies": {},
+  "deprecated": false,
   "description": "Create and parse Content-Disposition header",
   "devDependencies": {
     "eslint": "3.11.1",
@@ -64,11 +42,6 @@
     "istanbul": "0.4.5",
     "mocha": "1.21.5"
   },
-  "directories": {},
-  "dist": {
-    "shasum": "0cf68bb9ddf5f2be7961c3a85178cb85dba78cb4",
-    "tarball": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.2.tgz"
-  },
   "engines": {
     "node": ">= 0.6"
   },
@@ -78,7 +51,6 @@
     "README.md",
     "index.js"
   ],
-  "gitHead": "2a08417377cf55678c9f870b305f3c6c088920f3",
   "homepage": "https://github.com/jshttp/content-disposition#readme",
   "keywords": [
     "content-disposition",
@@ -87,15 +59,7 @@
     "res"
   ],
   "license": "MIT",
-  "maintainers": [
-    {
-      "name": "dougwilson",
-      "email": "doug@somethingdoug.com"
-    }
-  ],
   "name": "content-disposition",
-  "optionalDependencies": {},
-  "readme": "ERROR: No README data found!",
   "repository": {
     "type": "git",
     "url": "git+https://github.com/jshttp/content-disposition.git"
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-type/HISTORY.md b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-type/HISTORY.md
index 01652ff..8f5cb70 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-type/HISTORY.md
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-type/HISTORY.md
@@ -1,3 +1,13 @@
+1.0.4 / 2017-09-11
+==================
+
+  * perf: skip parameter parsing when no parameters
+
+1.0.3 / 2017-09-10
+==================
+
+  * perf: remove argument reassignment
+
 1.0.2 / 2016-05-09
 ==================
 
diff --git a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-type/index.js b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-type/index.js
index 61ba6b5..6ce03f2 100644
--- a/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-type/index.js
+++ b/spec/cordova/fixtures/platforms/cordova-browser/node_modules/content-type/index.js
@@ -20,9 +20,9 @@
  * obs-text      = %x80-FF
  * quoted-pair   = "\" ( HTAB / SP / VCHAR / obs-text )
  */
-var paramRegExp = /; *([!#$%&'\*\+\-\.\^_`\|~0-9A-Za-z]+) *= *("(?:[\u000b\u0020\u0021\u0023-\u005b\u005d-\u007e\u0080-\u00ff]|\\[\u000b\u0020-\u00ff])*"|[!#$%&'\*\+\-\.\^_`\|~0-9A-Za-z]+) */g
-var textRegExp = /^[\u000b\u0020-\u007e\u0080-\u00ff]+$/
-var tokenRegExp = /^[!#$%&'\*\+\-\.\^_`\|~0-9A-Za-z]+$/
+var PARAM_REGEXP = /; *([!#$%&'*+.^_`|~0-9A-Za-z-]+) *= *("(?:[\u000b\u0020\u0021\u0023-\u005b\u005d-\u007e\u0080-\u00ff]|\\[\u000b\u0020-\u00ff])*"|[!#$%&'*+.^_`|~0-9A-Za-z-]+) */g
+var TEXT_REGEXP = /^[\u000b\u0020-\u007e\u0080-\u00ff]+$/
+var TOKEN_REGEXP = /^[!#$%&'*+.^_`|~0-9A-Za-z-]+$/
 
 /**
  * RegExp to match quoted-pair in RFC 7230 sec 3.2.6
@@ -30,21 +30,21 @@ var tokenRegExp = /^[!#$%&'\*\+\-\.\^_`\|~0-9A-Za-z]+$/
  * quoted-pair = "\" ( HTAB / SP / VCHAR / obs-text )
  * obs-text    = %x80-FF
  */
-var qescRegExp = /\\([\u000b\u0020-\u00ff])/g
+var QESC_REGEXP = /\\([\u000b\u0020-\u00ff])/g
 
 /**
  * RegExp to match chars that must be quoted-pair in RFC 7230 sec 3.2.6
  */
-var quoteRegExp = /([\\"])/g
+var QUOTE_REGEXP = /([\\"])/g
 
 /**
- * RegExp to match type in RFC 6838
+ * RegExp to match type in RFC 7231 sec 3.1.1.1
  *
  * media-type = type "/" subtype
  * type       = token
  * subtype    = token
  */
-var typeRegExp = /^[!#$%&'\*\+\-\.\^_`\|~0-9A-Za-z]+\/[!#$%&'\*\+\-\.\^_`\|~0-9A-Za-z]+$/
... 22136 lines suppressed ...

-- 
To stop receiving notification emails like this one, please contact
"commits@cordova.apache.org" <co...@cordova.apache.org>.

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org