long-press
Simulate a long press gesture on a mobile app element using a specific selector and duration. Ideal for testing or automating interactions like hold actions in Appium-based mobile automation workflows.
Instructions
Perform a long press gesture on an element
Input Schema
Name | Required | Description | Default |
---|---|---|---|
duration | No | Duration of the long press in milliseconds (default: 1000) | |
selector | Yes | Element selector (e.g., xpath, id) | |
strategy | No | Selector strategy: xpath, id, accessibility id, class name (default: xpath) |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"duration": {
"description": "Duration of the long press in milliseconds (default: 1000)",
"type": "number"
},
"selector": {
"description": "Element selector (e.g., xpath, id)",
"type": "string"
},
"strategy": {
"description": "Selector strategy: xpath, id, accessibility id, class name (default: xpath)",
"type": "string"
}
},
"required": [
"selector"
],
"type": "object"
}