diff --git a/packages/expect-puppeteer/src/matchers/toFill.ts b/packages/expect-puppeteer/src/matchers/toFill.ts index 49e189c1..67cffc17 100644 --- a/packages/expect-puppeteer/src/matchers/toFill.ts +++ b/packages/expect-puppeteer/src/matchers/toFill.ts @@ -17,7 +17,7 @@ async function selectAll(element: ElementHandle) { if (element.setSelectionRange) { try { element.setSelectionRange(0, element.value.length); - } catch (e) { + } catch { // setSelectionRange throws an error for inputs: number/date/time/etc // we can just focus them and the content will be selected element.focus();