① Single file upload
Standard <input type="file">. Playwright sets the file directly on the input.
id=single-upload
data-testid=single-upload · single-preview
type=file (single)
Playwright drives the standard HTML file input via locator.setInputFiles(...) — no OS dialog is opened.
Downloads are caught with page.waitForEvent('download') + download.saveAs().
Native OS upload dialogs from custom widgets are out of scope; this page sticks to the standard, supported flow.
Standard <input type="file">. Playwright sets the file directly on the input.
multiple attribute lets you select several. Playwright passes an array to setInputFiles.
setInputFiles)The visual is a div, but the hidden input behind it is what Playwright targets. Users see a drop zone; tests target the input.
#dropzone-input for tests.
Anchor with download attribute serves a generated Blob. Capture via page.waitForEvent('download').