diff --git a/test/lib/browsers/playwright.ts b/test/lib/browsers/playwright.ts index d2fb78b7476d4..164440745f245 100644 --- a/test/lib/browsers/playwright.ts +++ b/test/lib/browsers/playwright.ts @@ -30,6 +30,7 @@ export async function quit() { interface ElementHandleExt extends ElementHandle { getComputedCss(prop: string): Promise + text(): Promise } export class Playwright extends BrowserInterface { @@ -252,6 +253,7 @@ export class Playwright extends BrowserInterface { return Object.assign(el, { selector, getComputedCss, + text: () => el.innerText(), }) }