You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to audit my Single page application's performance using lighthouse by running it in Timespan as well as snapshot modes ( reference link: https://github.com/GoogleChrome/lighthouse/blob/HEAD/docs/user-flows.md ) using the LH library in playwright. But when I tried the below code similar to puppeteer, I am getting an exception as below,
at Driver.connect (/Users/***/Documents/Tools/playwright/node_modules/lighthouse/lighthouse-core/fraggle-rock/gather/driver.js:74:38)
at startTimespanGather (/Users/***/Documents/Tools/playwright/node_modules/lighthouse/lighthouse-core/fraggle-rock/gather/timespan-runner.js:30:16)
at UserFlow.startTimespan (/Users/***/Documents/Tools/playwright/node_modules/lighthouse/lighthouse-core/fraggle-rock/user-flow.js:127:28)
Hi @BALAMOHANP , did you find any work around for this.
I'm trying to run playaduit multiple times within the same test but once the analysis is done by audit the browser is auto closed for me due to which I'm unable to move to other parts of the page.
I would like to audit my Single page application's performance using lighthouse by running it in Timespan as well as snapshot modes ( reference link: https://github.com/GoogleChrome/lighthouse/blob/HEAD/docs/user-flows.md ) using the LH library in playwright. But when I tried the below code similar to puppeteer, I am getting an exception as below,
TypeError: this._page.target is not a function
155 | * View Cart
156 | */
Please review the code and help me to fix it.
Code :
const playwright = require('playwright');
const { playAudit } = require('playwright-lighthouse');
import lighthouseDesktopConfig from 'lighthouse/lighthouse-core/config/lr-desktop-config';
import { url, username, password, testResultDir, searchStr, timeout, skuUrl } from './../playwright.config';
const { test, expect } = require('@playwright/test');
const { startFlow } = require('lighthouse/lighthouse-core/fraggle-rock/api.js');
const os = require('os');
const fs = require('fs');
const path = require('path');
const appPrefix = 'pl-lh';
const tmpDir = os.tmpdir();
const tmpDir2 = fs.mkdtempSync(path.join(tmpDir, appPrefix));
test('my test',async () => {
// console.log(tmpDir);
const context = await playwright['chromium'].launchPersistentContext(tmpDir2, {
args: ['--remote-debugging-port=9222'],
headless: false
});
await context.close();
});
The text was updated successfully, but these errors were encountered: