lighthouse 9.5.0-dev.20220704 → 9.5.0-dev.20220707

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.
package/.gitattributes CHANGED
@@ -1,2 +1,3 @@
1
1
  *.js eol=lf
2
- **/locales/*.json linguist-generated=true
2
+ **/locales/*.json linguist-generated=true
3
+ build/** linguist-generated=false
@@ -135,10 +135,10 @@ async function begin() {
135
135
  default: false,
136
136
  describe: 'Save test artifacts and output verbose logs',
137
137
  },
138
- 'fraggle-rock': {
138
+ 'legacy-navigation': {
139
139
  type: 'boolean',
140
140
  default: false,
141
- describe: 'Use the new Fraggle Rock runner',
141
+ describe: 'Use the legacy navigation runner',
142
142
  },
143
143
  'jobs': {
144
144
  type: 'number',
@@ -216,7 +216,7 @@ async function begin() {
216
216
  jobs,
217
217
  retries,
218
218
  isDebug: argv.debug,
219
- useFraggleRock: argv.fraggleRock,
219
+ useLegacyNavigation: argv.legacyNavigation,
220
220
  lighthouseRunner: runLighthouse,
221
221
  takeNetworkRequestUrls,
222
222
  };
@@ -47,7 +47,7 @@ if (!isMainThread && parentPort) {
47
47
  /**
48
48
  * @param {string} url
49
49
  * @param {LH.Config.Json|undefined} configJson
50
- * @param {{isDebug?: boolean, useFraggleRock?: boolean}} testRunnerOptions
50
+ * @param {{isDebug?: boolean, useLegacyNavigation?: boolean}} testRunnerOptions
51
51
  * @return {Promise<{lhr: LH.Result, artifacts: LH.Artifacts}>}
52
52
  */
53
53
  async function runBundledLighthouse(url, configJson, testRunnerOptions) {
@@ -80,15 +80,15 @@ async function runBundledLighthouse(url, configJson, testRunnerOptions) {
80
80
  try {
81
81
  const logLevel = testRunnerOptions.isDebug ? 'info' : undefined;
82
82
  let runnerResult;
83
- if (testRunnerOptions.useFraggleRock) {
83
+ if (testRunnerOptions.useLegacyNavigation) {
84
+ const connection = new ChromeProtocol(port);
85
+ runnerResult =
86
+ await lighthouse.legacyNavigation(url, {port, logLevel}, configJson, connection);
87
+ } else {
84
88
  // Puppeteer is not included in the bundle, we must create the page here.
85
89
  const browser = await puppeteer.connect({browserURL: `http://localhost:${port}`});
86
90
  const page = await browser.newPage();
87
91
  runnerResult = await lighthouse(url, {port, logLevel}, configJson, page);
88
- } else {
89
- const connection = new ChromeProtocol(port);
90
- runnerResult =
91
- await lighthouse.legacyNavigation(url, {port, logLevel}, configJson, connection);
92
92
  }
93
93
  if (!runnerResult) throw new Error('No runnerResult');
94
94
 
@@ -106,7 +106,7 @@ async function runBundledLighthouse(url, configJson, testRunnerOptions) {
106
106
  * Launch Chrome and do a full Lighthouse run via the Lighthouse DevTools bundle.
107
107
  * @param {string} url
108
108
  * @param {LH.Config.Json=} configJson
109
- * @param {{isDebug?: boolean, useFraggleRock?: boolean}=} testRunnerOptions
109
+ * @param {{isDebug?: boolean, useLegacyNavigation?: boolean}=} testRunnerOptions
110
110
  * @return {Promise<{lhr: LH.Result, artifacts: LH.Artifacts, log: string}>}
111
111
  */
112
112
  async function runLighthouse(url, configJson, testRunnerOptions = {}) {
@@ -41,30 +41,16 @@ async function runLighthouse(url, configJson, testRunnerOptions = {}) {
41
41
  .finally(() => !isDebug && fs.rm(tmpPath, {recursive: true, force: true}));
42
42
  }
43
43
 
44
- /**
45
- * @param {LH.Config.Json=} configJson
46
- * @return {LH.Config.Json|undefined}
47
- */
48
- function convertToFraggleRockConfig(configJson) {
49
- if (!configJson) return configJson;
50
- if (!configJson.passes) return configJson;
51
-
52
- return {
53
- ...configJson,
54
- navigations: configJson.passes.map(pass => ({...pass, id: pass.passName})),
55
- };
56
- }
57
-
58
44
  /**
59
45
  * Internal runner.
60
46
  * @param {string} url
61
47
  * @param {string} tmpPath
62
48
  * @param {LH.Config.Json=} configJson
63
- * @param {{isDebug?: boolean, useFraggleRock?: boolean}=} options
49
+ * @param {{isDebug?: boolean, useLegacyNavigation?: boolean}=} options
64
50
  * @return {Promise<{lhr: LH.Result, artifacts: LH.Artifacts, log: string}>}
65
51
  */
66
52
  async function internalRun(url, tmpPath, configJson, options) {
67
- const {isDebug = false, useFraggleRock = false} = options || {};
53
+ const {isDebug = false, useLegacyNavigation = false} = options || {};
68
54
  const localConsole = new LocalConsole();
69
55
 
70
56
  const outputPath = `${tmpPath}/smokehouse.report.json`;
@@ -81,9 +67,7 @@ async function internalRun(url, tmpPath, configJson, options) {
81
67
  '--quiet',
82
68
  ];
83
69
 
84
- if (useFraggleRock) {
85
- configJson = convertToFraggleRockConfig(configJson);
86
- } else {
70
+ if (useLegacyNavigation) {
87
71
  args.push('--legacy-navigation');
88
72
  }
89
73
 
@@ -21,10 +21,10 @@ const devtoolsDir =
21
21
  * @param {string[]} logs
22
22
  * @param {string} command
23
23
  * @param {string[]} args
24
+ * @return {Promise<boolean>} true if command exited successfully.
24
25
  */
25
- async function spawnAndLog(logs, command, args) {
26
- /** @type {Promise<void>} */
27
- const promise = new Promise((resolve) => {
26
+ function spawnAndLog(logs, command, args) {
27
+ return new Promise((resolve) => {
28
28
  const spawnHandle = spawn(command, args);
29
29
  spawnHandle.on('close', code => {
30
30
  if (code) {
@@ -32,7 +32,7 @@ async function spawnAndLog(logs, command, args) {
32
32
  } else {
33
33
  logs.push('[SUCCESS] Command exited with code: 0\n');
34
34
  }
35
- resolve();
35
+ resolve(code === 0);
36
36
  });
37
37
  spawnHandle.on('error', (error) => {
38
38
  logs.push(`ERROR: ${error.toString()}`);
@@ -48,21 +48,22 @@ async function spawnAndLog(logs, command, args) {
48
48
  logs.push(`STDERR: ${data}`);
49
49
  });
50
50
  });
51
- await promise;
52
51
  }
53
52
 
54
- /** @type {Promise<void>} */
53
+ /** @type {Promise<boolean>} */
55
54
  let buildDevtoolsPromise;
56
55
  /**
57
- * @param {string[]} logs
58
56
  * Download/pull latest DevTools, build Lighthouse for DevTools, roll to DevTools, and build DevTools.
57
+ * @param {string[]} logs
59
58
  */
60
59
  async function buildDevtools(logs) {
61
- if (process.env.CI) return;
60
+ if (process.env.CI) return true;
62
61
 
63
62
  process.env.DEVTOOLS_PATH = devtoolsDir;
64
- await spawnAndLog(logs, 'bash', ['lighthouse-core/test/chromium-web-tests/download-devtools.sh']);
65
- await spawnAndLog(logs, 'bash', ['lighthouse-core/test/chromium-web-tests/roll-devtools.sh']);
63
+ const success =
64
+ await spawnAndLog(logs, 'bash', ['lighthouse-core/test/devtools-tests/download-devtools.sh']) &&
65
+ await spawnAndLog(logs, 'bash', ['lighthouse-core/test/devtools-tests/roll-devtools.sh']);
66
+ return success;
66
67
  }
67
68
 
68
69
  /**
@@ -80,7 +81,10 @@ async function runLighthouse(url, configJson, testRunnerOptions = {}) {
80
81
  const logs = [];
81
82
 
82
83
  if (!buildDevtoolsPromise) buildDevtoolsPromise = buildDevtools(logs);
83
- await buildDevtoolsPromise;
84
+ if (!await buildDevtoolsPromise) {
85
+ const log = logs.join('') + '\n';
86
+ throw new Error(`failed to build devtools:\n${log}`);
87
+ }
84
88
 
85
89
  const outputDir = fs.mkdtempSync(os.tmpdir() + '/lh-smoke-cdt-runner-');
86
90
  const chromeFlags = [
@@ -217,10 +217,10 @@ function makeComparison(name, actualResult, expectedResult) {
217
217
  * @param {LocalConsole} localConsole
218
218
  * @param {LH.Result} lhr
219
219
  * @param {Smokehouse.ExpectedRunnerResult} expected
220
- * @param {{runner?: string, isBundled?: boolean, useFraggleRock?: boolean}=} reportOptions
220
+ * @param {{runner?: string, isBundled?: boolean, useLegacyNavigation?: boolean}=} reportOptions
221
221
  */
222
222
  function pruneExpectations(localConsole, lhr, expected, reportOptions) {
223
- const isFraggleRock = reportOptions?.useFraggleRock;
223
+ const isLegacyNavigation = reportOptions?.useLegacyNavigation;
224
224
  const isBundled = reportOptions?.isBundled;
225
225
 
226
226
  /**
@@ -276,13 +276,13 @@ function pruneExpectations(localConsole, lhr, expected, reportOptions) {
276
276
  `Actual Chromium version: ${getChromeVersionString()}`,
277
277
  ].join(' '));
278
278
  remove(key);
279
- } else if (value._legacyOnly && isFraggleRock) {
279
+ } else if (value._legacyOnly && !isLegacyNavigation) {
280
280
  localConsole.log([
281
281
  `[${key}] marked legacy only but run is Fraggle Rock, pruning expectation:`,
282
282
  JSON.stringify(value, null, 2),
283
283
  ].join(' '));
284
284
  remove(key);
285
- } else if (value._fraggleRockOnly && !isFraggleRock) {
285
+ } else if (value._fraggleRockOnly && isLegacyNavigation) {
286
286
  localConsole.log([
287
287
  `[${key}] marked Fraggle Rock only but run is legacy, pruning expectation:`,
288
288
  JSON.stringify(value, null, 2),
@@ -459,7 +459,7 @@ function reportAssertion(localConsole, assertion) {
459
459
  * summary. Returns count of passed and failed tests.
460
460
  * @param {{lhr: LH.Result, artifacts: LH.Artifacts, networkRequests?: string[]}} actual
461
461
  * @param {Smokehouse.ExpectedRunnerResult} expected
462
- * @param {{runner?: string, isDebug?: boolean, isBundled?: boolean, useFraggleRock?: boolean}=} reportOptions
462
+ * @param {{runner?: string, isDebug?: boolean, isBundled?: boolean, useLegacyNavigation?: boolean}=} reportOptions
463
463
  * @return {{passed: number, failed: number, log: string}}
464
464
  */
465
465
  function getAssertionReport(actual, expected, reportOptions = {}) {
@@ -53,7 +53,7 @@ const DEFAULT_RETRIES = 0;
53
53
  async function runSmokehouse(smokeTestDefns, smokehouseOptions) {
54
54
  const {
55
55
  isDebug,
56
- useFraggleRock,
56
+ useLegacyNavigation,
57
57
  jobs = DEFAULT_CONCURRENT_RUNS,
58
58
  retries = DEFAULT_RETRIES,
59
59
  lighthouseRunner = Object.assign(cliLighthouseRunner, {runnerName: 'cli'}),
@@ -65,7 +65,13 @@ async function runSmokehouse(smokeTestDefns, smokehouseOptions) {
65
65
  // Run each testDefn in parallel based on the concurrencyLimit.
66
66
  const concurrentMapper = new ConcurrentMapper();
67
67
 
68
- const testOptions = {isDebug, useFraggleRock, retries, lighthouseRunner, takeNetworkRequestUrls};
68
+ const testOptions = {
69
+ isDebug,
70
+ useLegacyNavigation,
71
+ retries,
72
+ lighthouseRunner,
73
+ takeNetworkRequestUrls,
74
+ };
69
75
  const smokePromises = smokeTestDefns.map(testDefn => {
70
76
  // If defn is set to `runSerially`, we'll run it in succession with other tests, not parallel.
71
77
  const concurrency = testDefn.runSerially ? 1 : jobs;
@@ -118,15 +124,35 @@ function purpleify(str) {
118
124
  return `${log.purple}${str}${log.reset}`;
119
125
  }
120
126
 
127
+ /**
128
+ * @param {LH.Config.Json=} configJson
129
+ * @return {LH.Config.Json|undefined}
130
+ */
131
+ function convertToLegacyConfig(configJson) {
132
+ if (!configJson) return configJson;
133
+ if (!configJson.navigations) return configJson;
134
+
135
+ return {
136
+ ...configJson,
137
+ passes: configJson.navigations.map(nav => ({...nav, passName: nav.id.concat('Pass')})),
138
+ };
139
+ }
140
+
121
141
  /**
122
142
  * Run Lighthouse in the selected runner.
123
143
  * @param {Smokehouse.TestDfn} smokeTestDefn
124
- * @param {{isDebug?: boolean, useFraggleRock?: boolean, retries: number, lighthouseRunner: Smokehouse.LighthouseRunner, takeNetworkRequestUrls?: () => string[]}} testOptions
144
+ * @param {{isDebug?: boolean, useLegacyNavigation?: boolean, retries: number, lighthouseRunner: Smokehouse.LighthouseRunner, takeNetworkRequestUrls?: () => string[]}} testOptions
125
145
  * @return {Promise<SmokehouseResult>}
126
146
  */
127
147
  async function runSmokeTest(smokeTestDefn, testOptions) {
128
- const {id, config: configJson, expectations} = smokeTestDefn;
129
- const {lighthouseRunner, retries, isDebug, useFraggleRock, takeNetworkRequestUrls} = testOptions;
148
+ const {id, expectations} = smokeTestDefn;
149
+ const {
150
+ lighthouseRunner,
151
+ retries,
152
+ isDebug,
153
+ useLegacyNavigation,
154
+ takeNetworkRequestUrls,
155
+ } = testOptions;
130
156
  const requestedUrl = expectations.lhr.requestedUrl;
131
157
 
132
158
  console.log(`${purpleify(id)} smoketest starting…`);
@@ -143,10 +169,15 @@ async function runSmokeTest(smokeTestDefn, testOptions) {
143
169
  bufferedConsole.log(` Retrying run (${i} out of ${retries} retries)…`);
144
170
  }
145
171
 
172
+ let configJson = smokeTestDefn.config;
173
+ if (useLegacyNavigation) {
174
+ configJson = convertToLegacyConfig(configJson);
175
+ }
176
+
146
177
  // Run Lighthouse.
147
178
  try {
148
179
  result = {
149
- ...await lighthouseRunner(requestedUrl, configJson, {isDebug, useFraggleRock}),
180
+ ...await lighthouseRunner(requestedUrl, configJson, {isDebug, useLegacyNavigation}),
150
181
  networkRequests: takeNetworkRequestUrls ? takeNetworkRequestUrls() : undefined,
151
182
  };
152
183
  } catch (e) {
@@ -161,7 +192,7 @@ async function runSmokeTest(smokeTestDefn, testOptions) {
161
192
  report = getAssertionReport(result, expectations, {
162
193
  runner: lighthouseRunner.runnerName,
163
194
  isDebug,
164
- useFraggleRock,
195
+ useLegacyNavigation,
165
196
  });
166
197
 
167
198
  runs.push({
@@ -41,7 +41,7 @@ class Driver {
41
41
  * @private
42
42
  * Used to save network and lifecycle protocol traffic. Just Page and Network are needed.
43
43
  */
44
- _devtoolsLog = new DevtoolsMessageLog(/^(Page|Network)\./);
44
+ _devtoolsLog = new DevtoolsMessageLog(/^(Page|Network|Target|Runtime)\./);
45
45
 
46
46
  /**
47
47
  * @private
@@ -154,7 +154,7 @@ function convertNodeTimingsToTrace(nodeTimings) {
154
154
  ...requestData,
155
155
  decodedBodyLength: record.resourceSize,
156
156
  didFail: !!record.failed,
157
- finishTime: endTime,
157
+ finishTime: toMicroseconds(endTime) / (1000 * 1000),
158
158
  };
159
159
 
160
160
  /** @type {LH.TraceEvent[]} */
@@ -32,5 +32,5 @@ fi
32
32
  if [ -e "$CHROME_PATH" ]; then
33
33
  echo "cached chrome found"
34
34
  else
35
- wget "$url" --no-check-certificate -q -O chrome.zip && unzip -q chrome.zip
35
+ curl "$url" -Lo chrome.zip && unzip -q chrome.zip
36
36
  fi
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lighthouse",
3
- "version": "9.5.0-dev.20220704",
3
+ "version": "9.5.0-dev.20220707",
4
4
  "description": "Automated auditing, performance metrics, and best practices for the web.",
5
5
  "main": "./lighthouse-core/index.js",
6
6
  "bin": {
@@ -76,8 +76,7 @@
76
76
  "update:sample-artifacts": "node lighthouse-core/scripts/update-report-fixtures.js",
77
77
  "update:sample-json": "yarn i18n:collect-strings && node ./lighthouse-cli -A=./lighthouse-core/test/results/artifacts --config-path=./lighthouse-core/test/results/sample-config.js --output=json --output-path=./lighthouse-core/test/results/sample_v2.json && node lighthouse-core/scripts/cleanup-LHR-for-diff.js ./lighthouse-core/test/results/sample_v2.json --only-remove-timing && node ./lighthouse-core/scripts/update-flow-fixtures.js",
78
78
  "update:flow-sample-json": "yarn i18n:collect-strings && node ./lighthouse-core/scripts/update-flow-fixtures.js",
79
- "update:test-devtools": "bash lighthouse-core/test/chromium-web-tests/test-locally.sh --reset-results",
80
- "test-devtools": "bash lighthouse-core/test/chromium-web-tests/test-locally.sh",
79
+ "test-devtools": "bash lighthouse-core/test/devtools-tests/test-locally.sh",
81
80
  "open-devtools": "bash lighthouse-core/scripts/open-devtools.sh",
82
81
  "run-devtools": "node lighthouse-core/scripts/pptr-run-devtools.js",
83
82
  "diff:sample-json": "yarn i18n:checks && bash lighthouse-core/scripts/assert-golden-lhr-unchanged.sh",
package/readme.md CHANGED
@@ -246,7 +246,6 @@ Useful documentation, examples, and recipes to get you started.
246
246
 
247
247
  **Recipes**
248
248
 
249
- - [gulp](docs/recipes/gulp) - helpful for CI integration
250
249
  - [Plugin](./docs/recipes/lighthouse-plugin-example) - example Lighthouse plugin
251
250
  - [Custom Audit example](./docs/recipes/custom-audit) - extend Lighthouse, run your own audits
252
251
 
package/tsconfig.json CHANGED
@@ -39,7 +39,6 @@
39
39
  "clients/test/**/*.js",
40
40
  "lighthouse-cli/test/fixtures/**/*.js",
41
41
  "lighthouse-core/scripts/legacy-javascript/variants",
42
- "lighthouse-core/test/chromium-web-tests/webtests",
43
42
  // These test files require further changes before they can be type checked.
44
43
  "lighthouse-core/test/config/budget-test.js",
45
44
  "lighthouse-core/test/config/config-helpers-test.js",
@@ -52,13 +52,13 @@ declare global {
52
52
  {expectations: Smokehouse.ExpectedRunnerResult | Array<Smokehouse.ExpectedRunnerResult>}
53
53
 
54
54
  export type LighthouseRunner =
55
- {runnerName?: string} & ((url: string, configJson?: Config.Json, runnerOptions?: {isDebug?: boolean; useFraggleRock?: boolean}) => Promise<{lhr: LHResult, artifacts: Artifacts, log: string}>);
55
+ {runnerName?: string} & ((url: string, configJson?: Config.Json, runnerOptions?: {isDebug?: boolean; useLegacyNavigation?: boolean}) => Promise<{lhr: LHResult, artifacts: Artifacts, log: string}>);
56
56
 
57
57
  export interface SmokehouseOptions {
58
58
  /** If true, performs extra logging from the test runs. */
59
59
  isDebug?: boolean;
60
- /** If true, uses the new Fraggle Rock runner. */
61
- useFraggleRock?: boolean;
60
+ /** If true, use the legacy navigation runner. */
61
+ useLegacyNavigation?: boolean;
62
62
  /** Manually set the number of jobs to run at once. `1` runs all tests serially. */
63
63
  jobs?: number;
64
64
  /** The number of times to retry failing tests before accepting. Defaults to 0. */
@@ -1,14 +0,0 @@
1
- # Devtools e2e Tests
2
-
3
- These tests are rolled into the Chromium DevTools Frontend codebase. They "belong" to the devtools frontend, but are truly defined in this Lighthouse repo.
4
-
5
- Run with `sh lighthouse-core/test/devtools-tests/test-locally.sh`.
6
-
7
- See `lighthouse-core/test/chromium-web-tests/README.md` for more.
8
-
9
- ## Sync
10
-
11
- ```sh
12
- rsync -ahvz --exclude='OWNERS' ~/src/devtools/devtools-frontend/test/e2e/lighthouse/ third-party/devtools-tests/e2e/lighthouse/
13
- rsync -ahvz --exclude='OWNERS' ~/src/devtools/devtools-frontend/test/e2e/resources/lighthouse/ third-party/devtools-tests/e2e/resources/lighthouse/
14
- ```
@@ -1,17 +0,0 @@
1
- # Copyright 2020 The Chromium Authors. All rights reserved.
2
- # Use of this source code is governed by a BSD-style license that can be
3
- # found in the LICENSE file.
4
-
5
- import("../../../third_party/typescript/typescript.gni")
6
-
7
- node_ts_library("lighthouse") {
8
- sources = [
9
- "generate-report_test.ts",
10
- "indexeddb-warning_test.ts",
11
- ]
12
-
13
- deps = [
14
- "../../shared",
15
- "../helpers",
16
- ]
17
- }
@@ -1,29 +0,0 @@
1
- // Copyright 2020 The Chromium Authors. All rights reserved.
2
- // Use of this source code is governed by a BSD-style license that can be
3
- // found in the LICENSE file.
4
-
5
- import {assert} from 'chai';
6
-
7
- import {goToResource} from '../../shared/helper.js';
8
- import {describe, it} from '../../shared/mocha-extensions.js';
9
- import {isGenerateReportButtonDisabled, navigateToLighthouseTab} from '../helpers/lighthouse-helpers.js';
10
-
11
- describe('The Lighthouse Tab', function() {
12
- this.timeout(20_000);
13
-
14
- it('shows a button to generate a new report', async () => {
15
- await navigateToLighthouseTab('empty.html');
16
-
17
- const disabled = await isGenerateReportButtonDisabled();
18
- assert.isFalse(disabled, 'The Generate Report button should not be disabled');
19
- });
20
-
21
- // Broken on non-debug runs
22
- it.skip('[crbug.com/1057948] shows generate report button even when navigating to an unreachable page', async () => {
23
- await navigateToLighthouseTab('empty.html');
24
-
25
- await goToResource('network/unreachable.rawresponse');
26
- const disabled = await isGenerateReportButtonDisabled();
27
- assert.isTrue(disabled, 'The Generate Report button should be disabled');
28
- });
29
- });
@@ -1,29 +0,0 @@
1
- // Copyright 2022 The Chromium Authors. All rights reserved.
2
- // Use of this source code is governed by a BSD-style license that can be
3
- // found in the LICENSE file.
4
-
5
- import {assert} from 'chai';
6
-
7
- import {waitFor} from '../../shared/helper.js';
8
- import {describe, it} from '../../shared/mocha-extensions.js';
9
- import {navigateToLighthouseTab} from '../helpers/lighthouse-helpers.js';
10
-
11
- describe('IndexedDB warning', function() {
12
- this.timeout(20_000);
13
-
14
- it('displays when important data may affect performance', async () => {
15
- await navigateToLighthouseTab('empty.html');
16
-
17
- let warningElem = await waitFor('.lighthouse-warning-text.hidden');
18
- const warningText1 = await warningElem.evaluate(node => node.textContent?.trim());
19
- assert.strictEqual(warningText1, '');
20
-
21
- await navigateToLighthouseTab('lighthouse/lighthouse-storage.html');
22
-
23
- warningElem = await waitFor('.lighthouse-warning-text:not(.hidden)');
24
- const expected =
25
- 'There may be stored data affecting loading performance in this location: IndexedDB. Audit this page in an incognito window to prevent those resources from affecting your scores.';
26
- const warningText2 = await warningElem.evaluate(node => node.textContent?.trim());
27
- assert.strictEqual(warningText2, expected);
28
- });
29
- });
@@ -1,9 +0,0 @@
1
- # Copyright 2022 The Chromium Authors. All rights reserved.
2
- # Use of this source code is governed by a BSD-style license that can be
3
- # found in the LICENSE file.
4
-
5
- import("../../../../scripts/build/ninja/copy.gni")
6
-
7
- copy_to_gen("lighthouse") {
8
- sources = [ "lighthouse-storage.html" ]
9
- }
@@ -1,11 +0,0 @@
1
- <!DOCTYPE html>
2
- <head>
3
- <meta charset="UTF-8">
4
- <script>
5
- // Indexeddb
6
- window.indexedDB.open("DataBase", 3);
7
- </script>
8
- </head>
9
- <body>
10
- hi
11
- </body>