(name)
| 551 | await mkdir(OUT_DIR, { recursive: true }); |
| 552 | |
| 553 | const readability = async (name) => { |
| 554 | const top = await measureReadability(page, READABILITY_EXCLUSIONS); |
| 555 | const scrolled = await scrollRegionsToEnd(page, READABILITY_EXCLUSIONS); |
| 556 | await page.waitForTimeout(200); |
| 557 | const bottom = await measureReadability(page, READABILITY_EXCLUSIONS); |
| 558 | await resetScroll(page, READABILITY_EXCLUSIONS); |
| 559 | extras.readability.push({ |
| 560 | name, |
| 561 | scrolledRegions: scrolled.length, |
| 562 | top: { candidates: top.candidates, overlaps: top.overlaps, clipped: top.clipped }, |
| 563 | bottom: { |
| 564 | candidates: bottom.candidates, |
| 565 | overlaps: bottom.overlaps, |
| 566 | clipped: bottom.clipped, |
| 567 | }, |
| 568 | }); |
| 569 | report.overlapViolations += top.overlaps.length + bottom.overlaps.length; |
| 570 | report.clippingViolations += top.clipped.length + bottom.clipped.length; |
| 571 | }; |
| 572 | |
| 573 | await openApp(page, origin); |
| 574 |
no test coverage detected