Update Puppeteer to v3.0.3
DISABLE_THIRD_PARTY_CHECK=update Puppeteer
Also-By: tvanderlippe@chromium.org
Change-Id: I4ddb6a2b426bcde95f9b764790e88b560441225c
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2187209
Commit-Queue: Mathias Bynens <mathias@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
diff --git a/node_modules/proxy-from-env/.eslintrc b/node_modules/proxy-from-env/.eslintrc
new file mode 100644
index 0000000..a51449b
--- /dev/null
+++ b/node_modules/proxy-from-env/.eslintrc
@@ -0,0 +1,29 @@
+{
+ "env": {
+ "node": true
+ },
+ "rules": {
+ "array-bracket-spacing": [2, "never"],
+ "block-scoped-var": 2,
+ "brace-style": [2, "1tbs"],
+ "camelcase": 1,
+ "computed-property-spacing": [2, "never"],
+ "curly": 2,
+ "eol-last": 2,
+ "eqeqeq": [2, "smart"],
+ "max-depth": [1, 3],
+ "max-len": [1, 80],
+ "max-statements": [1, 15],
+ "new-cap": 1,
+ "no-extend-native": 2,
+ "no-mixed-spaces-and-tabs": 2,
+ "no-trailing-spaces": 2,
+ "no-unused-vars": 1,
+ "no-use-before-define": [2, "nofunc"],
+ "object-curly-spacing": [2, "never"],
+ "quotes": [2, "single", "avoid-escape"],
+ "semi": [2, "always"],
+ "keyword-spacing": [2, {"before": true, "after": true}],
+ "space-unary-ops": 2
+ }
+}
diff --git a/node_modules/proxy-from-env/.jscsrc b/node_modules/proxy-from-env/.jscsrc
deleted file mode 100644
index 1f636de..0000000
--- a/node_modules/proxy-from-env/.jscsrc
+++ /dev/null
@@ -1,3 +0,0 @@
-{
- "preset": "node-style-guide"
-}
diff --git a/node_modules/proxy-from-env/.jshintrc b/node_modules/proxy-from-env/.jshintrc
deleted file mode 100644
index 29a1cf2..0000000
--- a/node_modules/proxy-from-env/.jshintrc
+++ /dev/null
@@ -1,15 +0,0 @@
-{
- "curly": true,
- "eqeqeq": true,
- "freeze": true,
- "indent": 2,
- "newcap": true,
- "quotmark": "single",
- "maxdepth": 3,
- "maxlen": 80,
- "eqnull": true,
- "funcscope": true,
- "node": true,
- "undef": true,
- "unused": "vars"
-}
diff --git a/node_modules/proxy-from-env/.npmignore b/node_modules/proxy-from-env/.npmignore
deleted file mode 100644
index 68e7bda..0000000
--- a/node_modules/proxy-from-env/.npmignore
+++ /dev/null
@@ -1,3 +0,0 @@
-*.swp
-coverage/
-node_modules/
diff --git a/node_modules/proxy-from-env/.travis.yml b/node_modules/proxy-from-env/.travis.yml
index 5bf285a..64a05f9 100644
--- a/node_modules/proxy-from-env/.travis.yml
+++ b/node_modules/proxy-from-env/.travis.yml
@@ -1,7 +1,7 @@
language: node_js
node_js:
- node
- - 0.10
+ - lts/*
script:
- npm run lint
# test-coverage will also run the tests, but does not print helpful output upon test failure.
diff --git a/node_modules/proxy-from-env/LICENSE b/node_modules/proxy-from-env/LICENSE
new file mode 100644
index 0000000..8f25097
--- /dev/null
+++ b/node_modules/proxy-from-env/LICENSE
@@ -0,0 +1,20 @@
+The MIT License
+
+Copyright (C) 2016-2018 Rob Wu <rob@robwu.nl>
+
+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/node_modules/proxy-from-env/index.js b/node_modules/proxy-from-env/index.js
index 5d49fba..df75004 100644
--- a/node_modules/proxy-from-env/index.js
+++ b/node_modules/proxy-from-env/index.js
@@ -39,7 +39,11 @@
return ''; // Don't proxy URLs that match NO_PROXY.
}
- var proxy = getEnv(proto + '_proxy') || getEnv('all_proxy');
+ var proxy =
+ getEnv('npm_config_' + proto + '_proxy') ||
+ getEnv(proto + '_proxy') ||
+ getEnv('npm_config_proxy') ||
+ getEnv('all_proxy');
if (proxy && proxy.indexOf('://') === -1) {
// Missing scheme in proxy, default to the requested URL's scheme.
proxy = proto + '://' + proxy;
@@ -56,7 +60,8 @@
* @private
*/
function shouldProxy(hostname, port) {
- var NO_PROXY = getEnv('no_proxy').toLowerCase();
+ var NO_PROXY =
+ (getEnv('npm_config_no_proxy') || getEnv('no_proxy')).toLowerCase();
if (!NO_PROXY) {
return true; // Always proxy if NO_PROXY is not set.
}
diff --git a/node_modules/proxy-from-env/package.json b/node_modules/proxy-from-env/package.json
index 55bed43..54fbe8e 100644
--- a/node_modules/proxy-from-env/package.json
+++ b/node_modules/proxy-from-env/package.json
@@ -5,11 +5,10 @@
},
"description": "Offers getProxyForUrl to get the proxy URL for a URL, respecting the *_PROXY (e.g. HTTP_PROXY) and NO_PROXY environment variables.",
"devDependencies": {
- "coveralls": "^2.11.6",
- "istanbul": "^0.4.2",
- "jscs": "^2.10.1",
- "jshint": "^2.9.1",
- "mocha": "^2.4.5"
+ "coveralls": "^3.0.9",
+ "eslint": "^6.8.0",
+ "istanbul": "^0.4.5",
+ "mocha": "^7.1.0"
},
"homepage": "https://github.com/Rob--W/proxy-from-env#readme",
"keywords": [
@@ -27,9 +26,9 @@
"url": "https://github.com/Rob--W/proxy-from-env.git"
},
"scripts": {
- "lint": "jscs *.js && jshint *.js",
+ "lint": "eslint *.js",
"test": "mocha ./test.js --reporter spec",
"test-coverage": "istanbul cover ./node_modules/.bin/_mocha -- --reporter spec"
},
- "version": "1.0.0"
+ "version": "1.1.0"
}
\ No newline at end of file
diff --git a/node_modules/proxy-from-env/test.js b/node_modules/proxy-from-env/test.js
index 124559d..abf6542 100644
--- a/node_modules/proxy-from-env/test.js
+++ b/node_modules/proxy-from-env/test.js
@@ -1,4 +1,4 @@
-/* jshint mocha:true */
+/* eslint max-statements:0 */
'use strict';
var assert = require('assert');
@@ -93,9 +93,8 @@
testProxyUrl(env, 'http://http-proxy', 'http://example');
testProxyUrl(env, 'http://http-proxy', parseUrl('http://example'));
- // jscs:disable requireCamelCaseOrUpperCaseIdentifiers
+ // eslint-disable-next-line camelcase
env.http_proxy = 'http://priority';
- // jscs:enable requireCamelCaseOrUpperCaseIdentifiers
testProxyUrl(env, 'http://priority', 'http://example');
});
@@ -123,9 +122,8 @@
env.HTTPS_PROXY = 'http://https-proxy';
testProxyUrl(env, 'http://https-proxy', 'https://example');
- // jscs:disable requireCamelCaseOrUpperCaseIdentifiers
+ // eslint-disable-next-line camelcase
env.https_proxy = 'http://priority';
- // jscs:enable requireCamelCaseOrUpperCaseIdentifiers
testProxyUrl(env, 'http://priority', 'https://example');
});
@@ -143,9 +141,8 @@
env.ALL_PROXY = 'http://catch-all';
testProxyUrl(env, 'http://catch-all', 'https://example');
- // jscs:disable requireCamelCaseOrUpperCaseIdentifiers
+ // eslint-disable-next-line camelcase
env.all_proxy = 'http://priority';
- // jscs:enable requireCamelCaseOrUpperCaseIdentifiers
testProxyUrl(env, 'http://priority', 'https://example');
});
@@ -390,4 +387,97 @@
testProxyUrl(env, '', 'http://ZzZ');
testProxyUrl(env, '', 'http://zZz');
});
+
+ describe('NPM proxy configuration', function() {
+ describe('npm_config_http_proxy should work', function() {
+ var env = {};
+ // eslint-disable-next-line camelcase
+ env.npm_config_http_proxy = 'http://http-proxy';
+
+ testProxyUrl(env, '', 'https://example');
+ testProxyUrl(env, 'http://http-proxy', 'http://example');
+
+ // eslint-disable-next-line camelcase
+ env.npm_config_http_proxy = 'http://priority';
+ testProxyUrl(env, 'http://priority', 'http://example');
+ });
+ // eslint-disable-next-line max-len
+ describe('npm_config_http_proxy should take precedence over HTTP_PROXY and npm_config_proxy', function() {
+ var env = {};
+ // eslint-disable-next-line camelcase
+ env.npm_config_http_proxy = 'http://http-proxy';
+ // eslint-disable-next-line camelcase
+ env.npm_config_proxy = 'http://unexpected-proxy';
+ env.HTTP_PROXY = 'http://unexpected-proxy';
+
+ testProxyUrl(env, 'http://http-proxy', 'http://example');
+ });
+ describe('npm_config_https_proxy should work', function() {
+ var env = {};
+ // eslint-disable-next-line camelcase
+ env.npm_config_http_proxy = 'http://unexpected.proxy';
+ testProxyUrl(env, '', 'https://example');
+
+ // eslint-disable-next-line camelcase
+ env.npm_config_https_proxy = 'http://https-proxy';
+ testProxyUrl(env, 'http://https-proxy', 'https://example');
+
+ // eslint-disable-next-line camelcase
+ env.npm_config_https_proxy = 'http://priority';
+ testProxyUrl(env, 'http://priority', 'https://example');
+ });
+ // eslint-disable-next-line max-len
+ describe('npm_config_https_proxy should take precedence over HTTPS_PROXY and npm_config_proxy', function() {
+ var env = {};
+ // eslint-disable-next-line camelcase
+ env.npm_config_https_proxy = 'http://https-proxy';
+ // eslint-disable-next-line camelcase
+ env.npm_config_proxy = 'http://unexpected-proxy';
+ env.HTTPS_PROXY = 'http://unexpected-proxy';
+
+ testProxyUrl(env, 'http://https-proxy', 'https://example');
+ });
+ describe('npm_config_proxy should work', function() {
+ var env = {};
+ // eslint-disable-next-line camelcase
+ env.npm_config_proxy = 'http://http-proxy';
+ testProxyUrl(env, 'http://http-proxy', 'http://example');
+ testProxyUrl(env, 'http://http-proxy', 'https://example');
+
+ // eslint-disable-next-line camelcase
+ env.npm_config_proxy = 'http://priority';
+ testProxyUrl(env, 'http://priority', 'http://example');
+ testProxyUrl(env, 'http://priority', 'https://example');
+ });
+ // eslint-disable-next-line max-len
+ describe('HTTP_PROXY and HTTPS_PROXY should take precedence over npm_config_proxy', function() {
+ var env = {};
+ env.HTTP_PROXY = 'http://http-proxy';
+ env.HTTPS_PROXY = 'http://https-proxy';
+ // eslint-disable-next-line camelcase
+ env.npm_config_proxy = 'http://unexpected-proxy';
+ testProxyUrl(env, 'http://http-proxy', 'http://example');
+ testProxyUrl(env, 'http://https-proxy', 'https://example');
+ });
+ describe('npm_config_no_proxy should work', function() {
+ var env = {};
+ env.HTTP_PROXY = 'http://proxy';
+ // eslint-disable-next-line camelcase
+ env.npm_config_no_proxy = 'example';
+
+ testProxyUrl(env, '', 'http://example');
+ testProxyUrl(env, 'http://proxy', 'http://otherwebsite');
+ });
+ // eslint-disable-next-line max-len
+ describe('npm_config_no_proxy should take precedence over NO_PROXY', function() {
+ var env = {};
+ env.HTTP_PROXY = 'http://proxy';
+ env.NO_PROXY = 'otherwebsite';
+ // eslint-disable-next-line camelcase
+ env.npm_config_no_proxy = 'example';
+
+ testProxyUrl(env, '', 'http://example');
+ testProxyUrl(env, 'http://proxy', 'http://otherwebsite');
+ });
+ });
});