@playwright/test 1.36.0-alpha-jun-21-2023 → 1.36.0-alpha-jun-23-2023

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -31,6 +31,7 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
31
31
  const defaultTimeout = 30000;
32
32
  exports.defaultTimeout = defaultTimeout;
33
33
  class FullConfigInternal {
34
+ // TODO: when merging reports, there could be no internal config. This is very unfortunate.
34
35
  static from(config) {
35
36
  return config[configInternalSymbol];
36
37
  }
@@ -15,6 +15,7 @@ var _raw = _interopRequireDefault(require("./raw"));
15
15
  var _base = require("./base");
16
16
  var _util = require("../util");
17
17
  var _zipBundle = require("playwright-core/lib/zipBundle");
18
+ var _config = require("../common/config");
18
19
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
20
  /**
20
21
  * Copyright (c) Microsoft Corporation.
@@ -97,6 +98,7 @@ class HtmlReporter {
97
98
  this._buildResult = await builder.build(this.config.metadata, reports);
98
99
  }
99
100
  async onExit() {
101
+ var _FullConfigInternal$f;
100
102
  if (process.env.CI || !this._buildResult) return;
101
103
  const {
102
104
  ok,
@@ -105,7 +107,7 @@ class HtmlReporter {
105
107
  const shouldOpen = this._open === 'always' || !ok && this._open === 'on-failure';
106
108
  if (shouldOpen) {
107
109
  await showHTMLReport(this._outputFolder, this._options.host, this._options.port, singleTestId);
108
- } else {
110
+ } else if (!((_FullConfigInternal$f = _config.FullConfigInternal.from(this.config)) !== null && _FullConfigInternal$f !== void 0 && _FullConfigInternal$f.cliListOnly)) {
109
111
  const relativeReportPath = this._outputFolder === standaloneDefaultFolder() ? '' : ' ' + _path.default.relative(process.cwd(), this._outputFolder);
110
112
  console.log('');
111
113
  console.log('To open last HTML report run:');
@@ -137,7 +137,7 @@ class TeleReporterEmitter {
137
137
  rootDir: config.rootDir,
138
138
  version: config.version,
139
139
  workers: config.workers,
140
- listOnly: (_FullConfigInternal$f = _config.FullConfigInternal.from(config)) === null || _FullConfigInternal$f === void 0 ? void 0 : _FullConfigInternal$f.cliListOnly
140
+ listOnly: !!((_FullConfigInternal$f = _config.FullConfigInternal.from(config)) !== null && _FullConfigInternal$f !== void 0 && _FullConfigInternal$f.cliListOnly)
141
141
  };
142
142
  }
143
143
  _serializeProject(suite) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@playwright/test",
3
- "version": "1.36.0-alpha-jun-21-2023",
3
+ "version": "1.36.0-alpha-jun-23-2023",
4
4
  "description": "A high-level API to automate web browsers",
5
5
  "repository": "github:Microsoft/playwright",
6
6
  "homepage": "https://playwright.dev",
@@ -41,7 +41,7 @@
41
41
  "license": "Apache-2.0",
42
42
  "dependencies": {
43
43
  "@types/node": "*",
44
- "playwright-core": "1.36.0-alpha-jun-21-2023"
44
+ "playwright-core": "1.36.0-alpha-jun-23-2023"
45
45
  },
46
46
  "optionalDependencies": {
47
47
  "fsevents": "2.3.2"
package/types/test.d.ts CHANGED
@@ -3518,10 +3518,12 @@ export interface PlaywrightWorkerOptions {
3518
3518
  * projects: [
3519
3519
  * {
3520
3520
  * name: 'chromium',
3521
- * use: { ...devices['Desktop Chrome'] },
3522
- * launchOptions: {
3523
- * args: ['--start-maximized'],
3524
- * },
3521
+ * use: {
3522
+ * ...devices['Desktop Chrome'],
3523
+ * launchOptions: {
3524
+ * args: ['--start-maximized']
3525
+ * }
3526
+ * }
3525
3527
  * }
3526
3528
  * ]
3527
3529
  * });