MCPcopy
hub / github.com/vitest-dev/vitest / upload

Method upload

packages/browser/context.d.ts:650–650  ·  view source on GitHub ↗

* Change a file input element to have the specified files. Uses provider's API under the hood. * @see {@link https://vitest.dev/api/browser/interactivity#userevent-upload}

(files: File | File[] | string | string[], options?: UserEventUploadOptions)

Source from the content-addressed store, hash-verified

648 * @see {@link https://vitest.dev/api/browser/interactivity#userevent-upload}
649 */
650 upload(files: File | File[] | string | string[], options?: UserEventUploadOptions): Promise<void>
651
652 /**
653 * Make a screenshot of an element matching the locator.

Callers 5

uploadFunction · 0.65
uploadMethod · 0.65
uploadMethod · 0.65
userEvent.test.tsFile · 0.65
failing.test.tsFile · 0.65

Calls

no outgoing calls

Tested by

no test coverage detected