angular-docs-cn/scripts/puppeteer-chrome-versions.js
George Kalpakas ab8199f7c9 build: several minor fixes related to using puppeteer (#35381)
This is a follow-up to #35049 with a few minor fixes related to using
the browser provided by `puppeteer` to run tests. Included fixes:

- Make the `webdriver-manager-update.js` really portable. (Previously,
  it needed to be run from the directory that contained the
  `node_modules/` directory. Now, it can be executed from a subdirectory
  and will correctly resolve dependencies.)

- Use the `puppeteer`-based setup in AIO unit and e2e tests to ensure
  that the downloaded ChromeDriver version matches the browser version
  used in tests.

- Use the `puppeteer`-based setup in the `aio_monitoring_stable` CI job
  (as happens with `aio_monitoring_next`).

- Use the [recommended way][1] of getting the browser port when using
  `puppeteer` with `lighthouse` and avoid hard-coding the remote
  debugging port (to be able to handle multiple instances running
  concurrently).

[1]: https://github.com/GoogleChrome/lighthouse/blame/51df179a0/docs/puppeteer.md#L49

PR Close #35381
2020-02-18 12:42:47 -08:00

26 lines
819 B
JavaScript

/**
* @license
* Copyright Google Inc. All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
// Mapping of puppeteer releases to their default Chrome version
// derived from https://github.com/puppeteer/puppeteer/blob/master/docs/api.md.
// The puppeteer package.json file contains the compatible Chrome revision such as
// "chromium_revision": "722234" but this does not map easily to the Chrome version
// so we use this mapping here instead.
module.exports = {
"2.1.1": "80.0.3987.0",
"2.1.0": "80.0.3987.0",
"2.0.0": "79.0.3942.0",
"1.20.0": "78.0.3882.0",
"1.19.0": "77.0.3803.0",
"1.17.0": "76.0.3803.0",
"1.15.0": "75.0.3765.0",
"1.13.0": "74.0.3723.0",
"1.12.2": "73.0.3679.0",
};