Keystone home page
Search...
⌘K
Overview
Steps Overview
AI-Powered Steps
AI Assert
Actions
Click
Type
Hover
Scroll
Select
Copy
Paste
File Upload
Assertions
Assert Text
Element Check
Navigation
Navigate
Go Back
Go Forward
Wait for URL
Email Testing
Email Inbox Testing
Email Create Inbox
Wait for Email
Email extract
Log in
Support
Keystone home page
Search...
⌘K
Ask AI
Log in
Support
Support
Search...
Navigation
Actions
File Upload
Documentation
Steps
CLI
Roadmap
Documentation
Steps
CLI
Roadmap
Actions
File Upload
Upload files to a file input element
Overview
The
FILE_UPLOAD
step allows you to upload files to file input elements. It bypasses native file dialogs to directly set files on the input element, making file upload testing reliable and automated.
Parameters
targetDescription
string
required
File input element selector. Must target an input element with type=“file”.
files
array
required
Array of file references to upload. Each file reference should include the file path or content.
waitForProcessing
boolean
default:
"false"
Wait for the file upload to be processed by the application
Behavior
Element Location
: Finds the file input element using the selector
Input Validation
: Validates that the element is a file input (input[type=“file”])
File Setting
: Sets the files on the input element
Event Firing
: Fires appropriate change and input events
Optional Processing Wait
: Waits for file processing if configured
Common Use Cases
Uploading profile pictures or avatars
Submitting documents for verification
Testing file size and type validation
Uploading multiple files at once
Testing drag-and-drop file upload areas
Error Handling
The step will fail if:
The element cannot be found using the selector
The element is not a file input element
The specified files do not exist
The input element is disabled
The input does not accept the file type being uploaded
Clear error messages help identify whether the issue is with the selector, element type, or file availability.
Previous
Assert Text
Verify text content is present on your page
Next
On this page
Overview
Parameters
Behavior
Common Use Cases
Error Handling
Assistant
Responses are generated using AI and may contain mistakes.