Skip to content

Commit

Permalink
fix: speed up clear command
Browse files Browse the repository at this point in the history
  • Loading branch information
kirillzyusko committed Nov 21, 2024
1 parent dd3a7e5 commit bddc192
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/e2e/nativeCommands/adbClear.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ const adbClear = (): Promise<boolean> => {
return execAsync(`
function clear_input() {
adb shell input keyevent KEYCODE_MOVE_END
adb shell input keyevent --longpress $(printf 'KEYCODE_DEL %.0s' {1..250})
# delete up to 2 characters per 1 press, so 1..3 will delete up to 6 characters
adb shell input keyevent --longpress $(printf 'KEYCODE_DEL %.0s' {1..3})
}
clear_input
Expand Down

0 comments on commit bddc192

Please sign in to comment.