agent-device 0.21.37 → 0.21.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/ime-helper/dist/{agent-device-android-ime-helper-0.21.37.apk → agent-device-android-ime-helper-0.21.38.apk} +0 -0
- package/android/ime-helper/dist/agent-device-android-ime-helper-0.21.38.apk.sha256 +1 -0
- package/android/ime-helper/dist/{agent-device-android-ime-helper-0.21.37.manifest.json → agent-device-android-ime-helper-0.21.38.manifest.json} +4 -4
- package/android/snapshot-helper/dist/{agent-device-android-snapshot-helper-0.21.37.apk → agent-device-android-snapshot-helper-0.21.38.apk} +0 -0
- package/android/snapshot-helper/dist/agent-device-android-snapshot-helper-0.21.38.apk.sha256 +1 -0
- package/android/snapshot-helper/dist/{agent-device-android-snapshot-helper-0.21.37.manifest.json → agent-device-android-snapshot-helper-0.21.38.manifest.json} +7 -7
- package/apple/fold-helper/Fold.m +8 -4
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerKeyboardReturnKey.swift +53 -0
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+AXSnapshotFallback.swift +42 -4
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+CommandExecution.swift +26 -18
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Interaction.swift +42 -11
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Keyboard.swift +123 -22
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Models.swift +7 -0
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Navigation.swift +570 -53
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests.swift +41 -0
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerXCTestEventBridge.h +7 -0
- package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerXCTestEventBridge.m +17 -1
- package/dist/src/THIRD_PARTY_NOTICES.txt +2 -2
- package/dist/src/absence-observation-errors.js +1 -1
- package/dist/src/absence-observation.js +1 -1
- package/dist/src/adapter.js +1 -1
- package/dist/src/adb-executor.js +1 -1
- package/dist/src/adb-failure.js +2 -2
- package/dist/src/adb-transport.js +1 -1
- package/dist/src/agent-browser-lifecycle.js +1 -1
- package/dist/src/agent-browser-process-record.js +1 -1
- package/dist/src/agent-browser-provider.js +1 -1
- package/dist/src/agent-browser-tool.js +1 -1
- package/dist/src/ai-sdk.d.ts +1 -1
- package/dist/src/ai-sdk.js +1 -1
- package/dist/src/alert-contract.js +1 -1
- package/dist/src/alert-tree-driver.js +1 -1
- package/dist/src/alert.js +1 -1
- package/dist/src/android-adb.d.ts +1 -1
- package/dist/src/android.js +1 -1
- package/dist/src/android2.js +1 -1
- package/dist/src/app-backend.js +1 -1
- package/dist/src/app-catalog.js +1 -1
- package/dist/src/app-deployment-resolution.js +1 -1
- package/dist/src/app-inventory.js +1 -1
- package/dist/src/app-launch.js +1 -1
- package/dist/src/app-lifecycle.js +4 -4
- package/dist/src/app-lifecycle2.js +2 -2
- package/dist/src/app-log-files.js +1 -1
- package/dist/src/app-log-runtime2.js +2 -2
- package/dist/src/app-log-session-resource.js +1 -1
- package/dist/src/app-resolution.js +1 -1
- package/dist/src/app-state-read.js +1 -1
- package/dist/src/app-state-runtime.d.ts +1 -1
- package/dist/src/application-lifecycle-interaction.js +1 -1
- package/dist/src/archive.js +1 -1
- package/dist/src/args.js +1 -1
- package/dist/src/artifact-download.js +1 -1
- package/dist/src/artifact-tracking.js +1 -1
- package/dist/src/auth-session.js +1 -1
- package/dist/src/auth.js +1 -1
- package/dist/src/automation-helper-artifact.js +1 -1
- package/dist/src/automation-helper.js +1 -1
- package/dist/src/await-with-signal.js +1 -1
- package/dist/src/backend-snapshot-options.js +1 -1
- package/dist/src/boot-diagnostics.js +1 -1
- package/dist/src/bridge-source.js +1 -1
- package/dist/src/browser-launch.js +1 -1
- package/dist/src/browserstack-device-features.js +1 -1
- package/dist/src/browserstack.js +1 -1
- package/dist/src/cache.js +1 -1
- package/dist/src/capture-disclosure.js +1 -1
- package/dist/src/capture-lifecycle.js +1 -1
- package/dist/src/cli-config.js +1 -1
- package/dist/src/cli-help.js +19 -16
- package/dist/src/cli-output.js +11 -11
- package/dist/src/cli-runner.js +1 -1
- package/dist/src/cli.js +2 -2
- package/dist/src/click-button.js +1 -1
- package/dist/src/client-metro-companion.js +1 -1
- package/dist/src/client-metro.js +1 -1
- package/dist/src/client-options.js +1 -1
- package/dist/src/client-port.d.ts +246 -208
- package/dist/src/clipboard-shell-response.js +1 -1
- package/dist/src/cloud-artifacts.d.ts +7 -2
- package/dist/src/code-signature-cache.js +1 -1
- package/dist/src/command-schema.js +6 -4
- package/dist/src/command-tools.js +3 -3
- package/dist/src/command.js +1 -1
- package/dist/src/composed-inventory-gateways.js +1 -1
- package/dist/src/composite-resource-admission.js +1 -1
- package/dist/src/config.js +1 -1
- package/dist/src/connection-lease-transaction.js +1 -1
- package/dist/src/connection-metro-runtime.js +1 -1
- package/dist/src/connection-runtime.js +1 -1
- package/dist/src/connection-verification.js +1 -1
- package/dist/src/connection.js +3 -3
- package/dist/src/context.js +1 -1
- package/dist/src/contract.d.ts +2 -1
- package/dist/src/contracts.d.ts +1 -1
- package/dist/src/contracts.js +1 -1
- package/dist/src/daemon-client-attach.js +1 -1
- package/dist/src/daemon-client-dispatch-disclosure.js +1 -1
- package/dist/src/daemon-client-ensure.js +1 -1
- package/dist/src/daemon-client-ensuring.js +1 -1
- package/dist/src/daemon-client-lease-beat.js +1 -1
- package/dist/src/daemon-client-lifecycle.js +1 -1
- package/dist/src/daemon-client-liveness-probe.js +1 -1
- package/dist/src/daemon-client-remote-health-cache.js +1 -0
- package/dist/src/daemon-client-remote-health-recovery.js +1 -0
- package/dist/src/daemon-client-transport.js +1 -1
- package/dist/src/daemon-command-registry.js +1 -1
- package/dist/src/daemon-composition.js +1 -1
- package/dist/src/daemon-diagnostics-scope.js +1 -1
- package/dist/src/daemon-http.js +1 -1
- package/dist/src/daemon-launch-spec.js +1 -1
- package/dist/src/daemon-lifecycle-errors.js +1 -1
- package/dist/src/daemon-policy-file.js +1 -1
- package/dist/src/daemon-registration-owner.js +3 -3
- package/dist/src/daemon-registration.js +1 -1
- package/dist/src/daemon-resolution.js +1 -1
- package/dist/src/daemon-startup-diagnostics.js +1 -1
- package/dist/src/daemon-stop.js +1 -1
- package/dist/src/daemon.js +1 -1
- package/dist/src/debug-symbols-facade.js +3 -3
- package/dist/src/device-claim-admission.js +1 -0
- package/dist/src/device-claim-reconciliation.js +1 -0
- package/dist/src/device-claim-recovery.js +1 -1
- package/dist/src/device-claim-rule.js +1 -1
- package/dist/src/device-claims.js +1 -1
- package/dist/src/device-input-state.d.ts +1 -1
- package/dist/src/device-inventory-context.js +1 -1
- package/dist/src/device-selection-resolver.js +1 -1
- package/dist/src/device-session.js +1 -1
- package/dist/src/device-shell.js +1 -1
- package/dist/src/device.js +1 -1
- package/dist/src/device3.js +3 -3
- package/dist/src/devicectl.js +1 -1
- package/dist/src/diagnostics.js +1 -1
- package/dist/src/discovery.js +1 -1
- package/dist/src/dispatch-resolve.js +1 -1
- package/dist/src/display-inventory.js +1 -1
- package/dist/src/doctor-facade.js +1 -1
- package/dist/src/doctor2.js +1 -1
- package/dist/src/durable-capture-resource.js +1 -1
- package/dist/src/durable-capture.js +1 -1
- package/dist/src/durable-resource.js +1 -1
- package/dist/src/ended-lease.js +1 -1
- package/dist/src/engine-eval-script.js +1 -1
- package/dist/src/error.js +2 -2
- package/dist/src/errors.js +1 -1
- package/dist/src/explicit-session-resolution.js +1 -1
- package/dist/src/expo-dev-client-launch.js +1 -1
- package/dist/src/failure-output.js +1 -1
- package/dist/src/file.js +1 -1
- package/dist/src/find.js +1 -1
- package/dist/src/finders.js +1 -1
- package/dist/src/flag-registry.js +1 -1
- package/dist/src/focus-runtime.js +1 -1
- package/dist/src/fold-helper.js +1 -1
- package/dist/src/generic-settle.js +1 -1
- package/dist/src/generic.js +1 -1
- package/dist/src/gesture-admission.js +1 -1
- package/dist/src/gesture-plan-types.d.ts +1 -1
- package/dist/src/gesture-plan.js +1 -1
- package/dist/src/gesture-runtime.js +1 -1
- package/dist/src/hdc.js +1 -1
- package/dist/src/helper-artifacts.js +1 -1
- package/dist/src/helper.js +2 -2
- package/dist/src/host-file.js +1 -1
- package/dist/src/host.js +1 -1
- package/dist/src/host2.js +1 -1
- package/dist/src/host3.js +1 -1
- package/dist/src/host4.js +1 -1
- package/dist/src/host5.js +1 -1
- package/dist/src/host6.js +1 -1
- package/dist/src/human-control-contract.js +1 -1
- package/dist/src/human-control.js +1 -1
- package/dist/src/ime-rebind.js +1 -1
- package/dist/src/ime-settings-record.js +1 -1
- package/dist/src/ime-state.js +1 -1
- package/dist/src/index.d.ts +3 -3
- package/dist/src/index.js +1 -1
- package/dist/src/input-actions.js +1 -1
- package/dist/src/input-actions2.js +1 -1
- package/dist/src/install-artifact-facade.js +1 -1
- package/dist/src/install-source-network-transport.js +1 -1
- package/dist/src/install-source2.js +1 -1
- package/dist/src/interaction-error.js +1 -1
- package/dist/src/interaction-positionals.js +1 -1
- package/dist/src/interaction-ref-policy.js +1 -1
- package/dist/src/interaction2.js +1 -1
- package/dist/src/interactor-operation-binding.js +1 -1
- package/dist/src/interactor.js +5 -5
- package/dist/src/interactor2.js +1 -1
- package/dist/src/interactor3.js +1 -1
- package/dist/src/interactor4.js +1 -1
- package/dist/src/interactor5.js +1 -1
- package/dist/src/interactors.js +1 -1
- package/dist/src/internal/bin.js +1 -1
- package/dist/src/internal/companion-tunnel.js +1 -1
- package/dist/src/internal/daemon.js +1 -1
- package/dist/src/internal/png-worker.js +1 -1
- package/dist/src/internal/run-script-child.js +1 -1
- package/dist/src/inventory.js +1 -1
- package/dist/src/inventory2.js +1 -1
- package/dist/src/inventory3.js +1 -1
- package/dist/src/inventory5.js +1 -1
- package/dist/src/ios-node-interpretation.js +1 -1
- package/dist/src/ios-simulator-accessibility.js +1 -1
- package/dist/src/ios-snapshot-acquisition.js +1 -1
- package/dist/src/ios-snapshot-engine.js +1 -1
- package/dist/src/ios-snapshot-runtime.js +1 -1
- package/dist/src/launch-confirmation.js +1 -1
- package/dist/src/launch-services-registration.js +1 -1
- package/dist/src/lease-context.js +1 -1
- package/dist/src/lease-registry-scope.js +1 -1
- package/dist/src/lease-release2.js +1 -1
- package/dist/src/lease-scope.js +1 -1
- package/dist/src/lease.js +1 -1
- package/dist/src/leased-recording-retention.js +1 -1
- package/dist/src/legacy.js +1 -1
- package/dist/src/limrun-download-file.js +1 -1
- package/dist/src/limrun-ios-files.js +1 -1
- package/dist/src/limrun-ios-runner.js +2 -2
- package/dist/src/limrun-runtime-dependencies.js +1 -1
- package/dist/src/limrun.d.ts +1 -1
- package/dist/src/local-interactor-operation-set.js +1 -1
- package/dist/src/local-simulator-apps.js +1 -1
- package/dist/src/local-simulator-files.js +1 -1
- package/dist/src/location-coordinates.js +1 -1
- package/dist/src/manifest.js +1 -1
- package/dist/src/mechanics.js +12 -12
- package/dist/src/merge-flags.js +1 -1
- package/dist/src/metro-reload-endpoints.js +1 -1
- package/dist/src/metro-session-hints.js +1 -1
- package/dist/src/metro.d.ts +1 -1
- package/dist/src/mobile-snapshot-semantics.js +1 -1
- package/dist/src/network-traffic.js +1 -1
- package/dist/src/node-http.js +1 -1
- package/dist/src/node-touch-point.js +1 -1
- package/dist/src/observation.js +1 -1
- package/dist/src/open-script.js +1 -1
- package/dist/src/open-target-device-resolution.js +1 -1
- package/dist/src/orientation.js +1 -1
- package/dist/src/parameterized-recorded-fill.js +1 -1
- package/dist/src/perf-facade.js +1 -1
- package/dist/src/perf-runtime-operation-builder.js +1 -1
- package/dist/src/perf-runtime-plan.js +1 -1
- package/dist/src/perf-target.js +2 -2
- package/dist/src/perf.js +1 -1
- package/dist/src/physical-device-control.js +1 -1
- package/dist/src/platform-runtime-android-adb-host.js +1 -1
- package/dist/src/platform-runtime-app-log-process.js +1 -1
- package/dist/src/platform-runtime-apple-application-tools.js +1 -1
- package/dist/src/platform-runtime-claim-recovery.js +1 -1
- package/dist/src/platform-runtime-host.js +1 -1
- package/dist/src/platform-runtime-open-target.js +1 -1
- package/dist/src/platform-runtime-operation-host.js +3 -3
- package/dist/src/platform-runtime-runtime-hints.js +1 -1
- package/dist/src/platform-runtime-screen-recording-apple-runner-transport.js +1 -1
- package/dist/src/platform-runtime-screen-recording-apple-simulator-host.js +1 -1
- package/dist/src/platform-runtime-screen-recording-finalizer-host.js +1 -1
- package/dist/src/platform-runtime-screen-recording-process-host.js +1 -1
- package/dist/src/platform-runtime-shutdown-error.js +1 -1
- package/dist/src/platform-runtime-unavailable.js +1 -1
- package/dist/src/platform-runtime.js +1 -1
- package/dist/src/platform-runtime2.js +1 -1
- package/dist/src/plist.js +1 -1
- package/dist/src/plugins2.js +1 -1
- package/dist/src/png-crop-bytes.js +1 -1
- package/dist/src/png-resize.js +1 -1
- package/dist/src/png-size.js +1 -1
- package/dist/src/png-worker-client.js +1 -1
- package/dist/src/png.js +1 -1
- package/dist/src/post-gesture-stability.js +1 -1
- package/dist/src/process-executable-path.js +1 -0
- package/dist/src/process-exit.js +1 -1
- package/dist/src/provider-device-runtime.d.ts +2 -2
- package/dist/src/provider-limrun-credentials.js +1 -1
- package/dist/src/provider-plugin.d.ts +1 -1
- package/dist/src/provider-profile-fields.js +1 -1
- package/dist/src/provider-webdriver.js +1 -1
- package/dist/src/provider.js +1 -1
- package/dist/src/proxy.js +2 -2
- package/dist/src/react-devtools-connection.js +1 -1
- package/dist/src/react-devtools-inspect-command.js +1 -1
- package/dist/src/react-native-overlay2.js +2 -2
- package/dist/src/react-native.js +1 -1
- package/dist/src/react-profile-command.js +1 -1
- package/dist/src/record-runtime.js +1 -1
- package/dist/src/record-trace.js +1 -1
- package/dist/src/recording-gestures.js +1 -1
- package/dist/src/recording.js +1 -1
- package/dist/src/rect-center.js +1 -1
- package/dist/src/register-builtins.js +1 -1
- package/dist/src/registry.js +1 -1
- package/dist/src/remote-config-core.js +1 -1
- package/dist/src/remote-config-flags.js +1 -1
- package/dist/src/remote-connection-state.js +1 -1
- package/dist/src/replay-backend-host.js +1 -1
- package/dist/src/replay-divergence.js +1 -1
- package/dist/src/replay-maestro-backend.js +2 -2
- package/dist/src/replay.d.ts +1 -1
- package/dist/src/replay2.js +1 -1
- package/dist/src/reporting.js +1 -1
- package/dist/src/request-dispatch-disclosure.js +1 -1
- package/dist/src/request-ended-leases.js +1 -1
- package/dist/src/request-providers.js +1 -1
- package/dist/src/request-runtime-binding.js +1 -1
- package/dist/src/request.js +1 -1
- package/dist/src/result-serialization.js +2 -2
- package/dist/src/retry.js +1 -1
- package/dist/src/run-script-execution.js +6 -8
- package/dist/src/run-script-http.js +1 -1
- package/dist/src/runner-cache-metadata.js +1 -1
- package/dist/src/runner-cache-retention.js +1 -1
- package/dist/src/runner-client.js +1 -1
- package/dist/src/runner-contract.js +1 -1
- package/dist/src/runner-dev-tools-security.js +1 -1
- package/dist/src/runner-device-readiness.js +1 -1
- package/dist/src/runner-device-set.js +1 -1
- package/dist/src/runner-disposal.js +1 -1
- package/dist/src/runner-error-classification.js +2 -2
- package/dist/src/runner-exchange.js +1 -1
- package/dist/src/runner-io.js +1 -1
- package/dist/src/runner-launched-session.js +1 -1
- package/dist/src/runner-lease.js +1 -1
- package/dist/src/runner-lifecycle.js +1 -1
- package/dist/src/runner-operations-facade.js +1 -1
- package/dist/src/runner-panel.js +1 -1
- package/dist/src/runner-retention.js +1 -1
- package/dist/src/runner-runtime.js +1 -1
- package/dist/src/runner-selector-query.js +1 -1
- package/dist/src/runner-sequence.js +1 -1
- package/dist/src/runner-start-budget.js +1 -1
- package/dist/src/runner-startup-transport.js +1 -1
- package/dist/src/runner-toolchain-identity.js +1 -1
- package/dist/src/runtime-admission.js +1 -1
- package/dist/src/runtime-deployment.js +1 -1
- package/dist/src/runtime-factory.js +1 -1
- package/dist/src/runtime-session.js +1 -1
- package/dist/src/runtime-transport-hints.js +1 -1
- package/dist/src/runtime.js +2 -2
- package/dist/src/runtime10.js +1 -1
- package/dist/src/runtime11.js +1 -1
- package/dist/src/runtime12.js +1 -1
- package/dist/src/runtime13.js +2 -2
- package/dist/src/runtime2.js +2 -2
- package/dist/src/runtime4.js +3 -3
- package/dist/src/runtime5.js +1 -1
- package/dist/src/runtime6.js +1 -1
- package/dist/src/runtime7.js +2 -2
- package/dist/src/runtime8.js +1 -1
- package/dist/src/runtime9.js +1 -1
- package/dist/src/screen-recording-admission-ledger.js +1 -0
- package/dist/src/screen-recording-completion.js +1 -1
- package/dist/src/screen-recording-options.js +1 -1
- package/dist/src/screen-recording-resource-recovery.js +1 -1
- package/dist/src/screen-recording-stop-recovery.js +1 -1
- package/dist/src/screen-recording-transport.js +1 -1
- package/dist/src/screenshot-density.js +1 -1
- package/dist/src/screenshot-image-size.js +1 -1
- package/dist/src/screenshot-image.js +1 -1
- package/dist/src/screenshot-runtime.js +1 -1
- package/dist/src/screenshot-runtime2.js +1 -1
- package/dist/src/screenshot.js +1 -1
- package/dist/src/screenshot2.js +1 -1
- package/dist/src/screenshot4.js +1 -1
- package/dist/src/script-source.js +1 -1
- package/dist/src/script.js +1 -1
- package/dist/src/scroll-command.js +1 -1
- package/dist/src/scroll-gesture.js +1 -1
- package/dist/src/sdk-batch-runner.d.ts +1 -1
- package/dist/src/sdk-batch-runner.js +2 -2
- package/dist/src/sdk-batch.js +2 -2
- package/dist/src/sdk-contracts.d.ts +26 -2
- package/dist/src/sdk-contracts.js +2 -2
- package/dist/src/sdk-device.js +1 -1
- package/dist/src/sdk-finders.d.ts +1 -1
- package/dist/src/sdk-finders.js +1 -1
- package/dist/src/sdk-io.js +5 -5
- package/dist/src/sdk-remote-config.d.ts +1 -1
- package/dist/src/sdk-remote-config.js +1 -1
- package/dist/src/sdk-selectors.d.ts +9 -6
- package/dist/src/sdk-selectors.js +1 -1
- package/dist/src/selection.js +0 -0
- package/dist/src/selector-pipeline-policy.js +1 -1
- package/dist/src/selector-runtime.js +1 -1
- package/dist/src/selectors.js +1 -1
- package/dist/src/server-shutdown.js +1 -1
- package/dist/src/server-startup.js +2 -2
- package/dist/src/server.js +4 -4
- package/dist/src/session-allocation.js +1 -1
- package/dist/src/session-artifact-paths.js +1 -1
- package/dist/src/session-capture-binding.js +1 -1
- package/dist/src/session-device-resolution.js +1 -1
- package/dist/src/session-event-action.js +1 -1
- package/dist/src/session-open.js +1 -1
- package/dist/src/session-repair-tombstone.js +1 -1
- package/dist/src/session-replay-vars.js +1 -1
- package/dist/src/session-routing.js +1 -1
- package/dist/src/session-runtime-admission.js +1 -1
- package/dist/src/session-runtime.js +1 -1
- package/dist/src/session-script-destination.js +1 -0
- package/dist/src/session-selector.js +1 -1
- package/dist/src/session-store.js +3 -3
- package/dist/src/session-teardown.js +1 -1
- package/dist/src/session-tenant-scope.js +1 -1
- package/dist/src/session2.js +5 -5
- package/dist/src/settings-bluetooth.js +1 -1
- package/dist/src/settings-global-toggle.js +1 -1
- package/dist/src/settings.js +1 -1
- package/dist/src/settings2.js +1 -1
- package/dist/src/settle-observation-capture.js +1 -1
- package/dist/src/simctl-execution.js +1 -1
- package/dist/src/simctl-facade.js +1 -1
- package/dist/src/simctl.js +1 -1
- package/dist/src/simulator-app-budget.js +1 -1
- package/dist/src/simulator-boot.js +1 -1
- package/dist/src/simulator-facade.js +1 -1
- package/dist/src/simulator-state.js +1 -1
- package/dist/src/simulator.js +1 -1
- package/dist/src/snapshot-baseline.js +1 -1
- package/dist/src/snapshot-chrome.js +1 -1
- package/dist/src/snapshot-desktop-projection.js +1 -1
- package/dist/src/snapshot-diagnostics.js +1 -1
- package/dist/src/snapshot-helper-install.js +3 -3
- package/dist/src/snapshot-helper-session.js +1 -1
- package/dist/src/snapshot-lines.js +1 -1
- package/dist/src/snapshot-node-lookup.js +1 -1
- package/dist/src/snapshot-occlusion.js +1 -1
- package/dist/src/snapshot-private-evidence.js +1 -1
- package/dist/src/snapshot-runtime-binding.js +1 -1
- package/dist/src/snapshot-runtime-capture-input.js +1 -1
- package/dist/src/snapshot-runtime.js +1 -1
- package/dist/src/snapshot-state.js +1 -1
- package/dist/src/snapshot.js +1 -1
- package/dist/src/snapshot2.js +1 -1
- package/dist/src/snapshot3.js +2 -2
- package/dist/src/snapshot4.js +1 -1
- package/dist/src/source-channel.js +1 -1
- package/dist/src/src.js +1 -1
- package/dist/src/src10.js +1 -1
- package/dist/src/src11.js +1 -1
- package/dist/src/src2.js +1 -1
- package/dist/src/src3.js +5 -5
- package/dist/src/src4.js +2 -2
- package/dist/src/src5.js +1 -1
- package/dist/src/src6.js +1 -1
- package/dist/src/src8.js +1 -1
- package/dist/src/store-legacy.js +1 -1
- package/dist/src/store.js +1 -1
- package/dist/src/string-enum.js +1 -1
- package/dist/src/surface-snapshot.js +1 -1
- package/dist/src/surface-snapshot2.js +1 -1
- package/dist/src/sync-cache.js +1 -1
- package/dist/src/system-surface-foreground.js +2 -2
- package/dist/src/takeover.js +1 -1
- package/dist/src/tap-keyboard-occlusion.js +1 -1
- package/dist/src/target-evidence-tree.js +1 -1
- package/dist/src/target-evidence.js +1 -1
- package/dist/src/telephony-runtime.js +1 -1
- package/dist/src/tool-provider-facade.js +1 -1
- package/dist/src/tool-provider.js +3 -3
- package/dist/src/tool-provider2.js +1 -1
- package/dist/src/tool-provider3.js +1 -1
- package/dist/src/toolchain-probe.js +1 -1
- package/dist/src/touch-runtime.js +1 -1
- package/dist/src/touch-runtime2.js +1 -1
- package/dist/src/transport.js +2 -2
- package/dist/src/tree.js +1 -1
- package/dist/src/tv-remote-runtime.js +1 -1
- package/dist/src/tv-remote.js +1 -1
- package/dist/src/type-text-runtime.js +1 -1
- package/dist/src/unsupported-interactor.js +1 -1
- package/dist/src/update-check.js +1 -1
- package/dist/src/validation.js +1 -1
- package/dist/src/vars.js +1 -1
- package/dist/src/vega-executable.js +1 -1
- package/dist/src/verified-file.js +1 -1
- package/dist/src/video.js +2 -2
- package/dist/src/viewport.js +1 -1
- package/dist/src/web.js +1 -1
- package/dist/src/webdriver-source.js +1 -1
- package/package.json +2 -2
- package/server.json +2 -2
- package/android/ime-helper/dist/agent-device-android-ime-helper-0.21.37.apk.sha256 +0 -1
- package/android/snapshot-helper/dist/agent-device-android-snapshot-helper-0.21.37.apk.sha256 +0 -1
- package/dist/src/capture-output-ownership.js +0 -1
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
72caf8771f85319c0aa1e0408a388e7b63f89fd14c4f2d863aca6932cc8f0c78 agent-device-android-ime-helper-0.21.38.apk
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "android-ime-helper",
|
|
3
|
-
"version": "0.21.
|
|
4
|
-
"assetName": "agent-device-android-ime-helper-0.21.
|
|
5
|
-
"sha256": "
|
|
3
|
+
"version": "0.21.38",
|
|
4
|
+
"assetName": "agent-device-android-ime-helper-0.21.38.apk",
|
|
5
|
+
"sha256": "72caf8771f85319c0aa1e0408a388e7b63f89fd14c4f2d863aca6932cc8f0c78",
|
|
6
6
|
"packageName": "com.callstack.agentdevice.imehelper",
|
|
7
|
-
"versionCode":
|
|
7
|
+
"versionCode": 21038,
|
|
8
8
|
"serviceComponent": "com.callstack.agentdevice.imehelper/.TestInputMethodService",
|
|
9
9
|
"broadcastProtocol": "android-ime-helper-v1"
|
|
10
10
|
}
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
96df633fd6d6870d8689e922f233513564bbf326e2c59c233a1d88fc26d52715 agent-device-android-snapshot-helper-0.21.38.apk
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "android-snapshot-helper",
|
|
3
|
-
"version": "0.21.
|
|
4
|
-
"releaseTag": "v0.21.
|
|
5
|
-
"assetName": "agent-device-android-snapshot-helper-0.21.
|
|
6
|
-
"apkUrl": "https://github.com/callstack/agent-device/releases/download/v0.21.
|
|
7
|
-
"sha256": "
|
|
8
|
-
"checksumName": "agent-device-android-snapshot-helper-0.21.
|
|
3
|
+
"version": "0.21.38",
|
|
4
|
+
"releaseTag": "v0.21.38",
|
|
5
|
+
"assetName": "agent-device-android-snapshot-helper-0.21.38.apk",
|
|
6
|
+
"apkUrl": "https://github.com/callstack/agent-device/releases/download/v0.21.38/agent-device-android-snapshot-helper-0.21.38.apk",
|
|
7
|
+
"sha256": "96df633fd6d6870d8689e922f233513564bbf326e2c59c233a1d88fc26d52715",
|
|
8
|
+
"checksumName": "agent-device-android-snapshot-helper-0.21.38.apk.sha256",
|
|
9
9
|
"packageName": "com.callstack.agentdevice.snapshothelper",
|
|
10
|
-
"versionCode":
|
|
10
|
+
"versionCode": 21038,
|
|
11
11
|
"instrumentationRunner": "com.callstack.agentdevice.snapshothelper/.SnapshotInstrumentation",
|
|
12
12
|
"minSdk": 23,
|
|
13
13
|
"targetSdk": 36,
|
package/apple/fold-helper/Fold.m
CHANGED
|
@@ -106,14 +106,18 @@ static int runSet(NSString *argument) {
|
|
|
106
106
|
return dispatchEvents(^BOOL(CFTypeRef client) { return runFrames(client, frames); });
|
|
107
107
|
}
|
|
108
108
|
|
|
109
|
-
// The
|
|
109
|
+
// The upside-down picker value is spelled "pud" on the wire; "portrait-upside-down" is
|
|
110
|
+
// ignored by the guest. It matters because each picker event rotates the display by
|
|
111
|
+
// (new - previous) picker value: without a 180 value, one of the four display orientations
|
|
112
|
+
// can never be landed (measured on iPhone Duo).
|
|
110
113
|
static int runRotate(NSString *orientation) {
|
|
111
|
-
|
|
112
|
-
|
|
114
|
+
NSString *value = [orientation isEqualToString:@"portrait-upside-down"] ? @"pud" : orientation;
|
|
115
|
+
if (![@[@"portrait", @"landscape-left", @"landscape-right", @"pud"] containsObject:value]) {
|
|
116
|
+
fprintf(stderr, "Expected orientation portrait, landscape-left, landscape-right or portrait-upside-down\n");
|
|
113
117
|
return 2;
|
|
114
118
|
}
|
|
115
119
|
return dispatchEvents(^BOOL(CFTypeRef client) {
|
|
116
|
-
return sendControl(client, @"orientation-picker-control", @"enum",
|
|
120
|
+
return sendControl(client, @"orientation-picker-control", @"enum", value);
|
|
117
121
|
});
|
|
118
122
|
}
|
|
119
123
|
|
package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerKeyboardReturnKey.swift
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import Foundation
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
enum RunnerKeyboardReturnKey: String {
|
|
23
|
+
case go
|
|
24
|
+
case search
|
|
25
|
+
case send
|
|
26
|
+
case next
|
|
27
|
+
case done
|
|
28
|
+
case join
|
|
29
|
+
case route
|
|
30
|
+
case `continue`
|
|
31
|
+
case enter
|
|
32
|
+
case unknown
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
static let probeLabels = ["return", "Return", "Enter", "Go", "Search", "Next", "Done", "Send", "Join"]
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
static func kind(of text: String) -> RunnerKeyboardReturnKey {
|
|
40
|
+
switch text.trimmingCharacters(in: .whitespacesAndNewlines).lowercased() {
|
|
41
|
+
case "go": return .go
|
|
42
|
+
case "search": return .search
|
|
43
|
+
case "send": return .send
|
|
44
|
+
case "next": return .next
|
|
45
|
+
case "done": return .done
|
|
46
|
+
case "join": return .join
|
|
47
|
+
case "route": return .route
|
|
48
|
+
case "continue": return .continue
|
|
49
|
+
case "return", "enter": return .enter
|
|
50
|
+
default: return .unknown
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
@@ -281,9 +281,25 @@ extension RunnerTests {
|
|
|
281
281
|
bundleId: String?,
|
|
282
282
|
rootFrame: CGRect
|
|
283
283
|
) -> SnapshotViewport {
|
|
284
|
-
let fallback =
|
|
284
|
+
let fallback = {
|
|
285
|
+
let fullScreenFrame = Self.fullScreenFrame(of: app)
|
|
286
|
+
let viewport = Self.privateAXRootViewport(rootFrame: rootFrame, fullScreenFrame: fullScreenFrame)
|
|
287
|
+
let kind: String
|
|
288
|
+
switch viewport {
|
|
289
|
+
case .reported: kind = "reported"
|
|
290
|
+
case .derived: kind = "derived"
|
|
291
|
+
case .missing: kind = "missing"
|
|
292
|
+
}
|
|
293
|
+
NSLog(
|
|
294
|
+
"AGENT_DEVICE_RUNNER_PRIVATE_AX_ROOT_VIEWPORT kind=%@ root=%@ fullScreen=%@",
|
|
295
|
+
kind,
|
|
296
|
+
String(describing: rootFrame),
|
|
297
|
+
fullScreenFrame.isNull ? "none" : String(describing: fullScreenFrame)
|
|
298
|
+
)
|
|
299
|
+
return viewport
|
|
300
|
+
}
|
|
285
301
|
guard shouldReadPrivateAXViewportViaXCTest(bundleId: bundleId) else {
|
|
286
|
-
return fallback
|
|
302
|
+
return fallback()
|
|
287
303
|
}
|
|
288
304
|
do {
|
|
289
305
|
let reported = try runMainThreadWork(
|
|
@@ -294,13 +310,35 @@ extension RunnerTests {
|
|
|
294
310
|
try self.safeSnapshotViewport(app: app, readingOrientation: true)
|
|
295
311
|
}
|
|
296
312
|
if case .missing = reported {
|
|
297
|
-
return fallback
|
|
313
|
+
return fallback()
|
|
298
314
|
}
|
|
299
315
|
return reported
|
|
300
316
|
} catch {
|
|
301
317
|
NSLog("AGENT_DEVICE_RUNNER_PRIVATE_AX_VIEWPORT_FALLBACK=%@", String(describing: error))
|
|
302
|
-
return fallback
|
|
318
|
+
return fallback()
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
|
|
323
|
+
private static func fullScreenFrame(of app: XCUIApplication) -> CGRect {
|
|
324
|
+
#if os(iOS)
|
|
325
|
+
return RunnerFullScreenApplicationFrame(app)
|
|
326
|
+
#else
|
|
327
|
+
return .null
|
|
328
|
+
#endif
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
|
|
332
|
+
|
|
333
|
+
|
|
334
|
+
|
|
335
|
+
static func privateAXRootViewport(rootFrame: CGRect, fullScreenFrame: CGRect) -> SnapshotViewport {
|
|
336
|
+
|
|
337
|
+
|
|
338
|
+
guard !fullScreenFrame.isNull, rootFrame.origin == .zero, rootFrame == fullScreenFrame else {
|
|
339
|
+
return .derived(box: rootFrame)
|
|
303
340
|
}
|
|
341
|
+
return .reported(box: rootFrame, interfaceOrientation: RunnerInterfaceOrientation.unknown)
|
|
304
342
|
}
|
|
305
343
|
|
|
306
344
|
func privateAXRect(_ value: Any?) -> CGRect {
|
|
@@ -425,7 +425,11 @@ extension RunnerTests {
|
|
|
425
425
|
guard pressTvRemote(button, duration: duration) else {
|
|
426
426
|
return Response(
|
|
427
427
|
ok: false,
|
|
428
|
-
error: ErrorPayload(
|
|
428
|
+
error: ErrorPayload(
|
|
429
|
+
code: RunnerWireErrorCode.hardwareControlUnavailable,
|
|
430
|
+
message: "remotePress is only supported on tvOS",
|
|
431
|
+
hint: "Only a tvOS target has a Siri Remote. On a TV target use tv-remote; on a phone or Mac, press the app's own control by its ref."
|
|
432
|
+
)
|
|
429
433
|
)
|
|
430
434
|
}
|
|
431
435
|
return Response(ok: true, data: DataPayload(message: "remote pressed"))
|
|
@@ -461,6 +465,9 @@ extension RunnerTests {
|
|
|
461
465
|
guard let selectorKey = command.selectorKey, let selectorValue = command.selectorValue else {
|
|
462
466
|
return Response(ok: false, error: ErrorPayload(message: "querySelector requires selectorKey and selectorValue"))
|
|
463
467
|
}
|
|
468
|
+
if command.hittabilityProbe == true {
|
|
469
|
+
return try probeElementHittability(app: activeApp, selectorKey: selectorKey, selectorValue: selectorValue)
|
|
470
|
+
}
|
|
464
471
|
return try queryElement(app: activeApp, selectorKey: selectorKey, selectorValue: selectorValue)
|
|
465
472
|
case .readText:
|
|
466
473
|
guard let x = command.x, let y = command.y else {
|
|
@@ -567,7 +574,7 @@ extension RunnerTests {
|
|
|
567
574
|
return Response(
|
|
568
575
|
ok: false,
|
|
569
576
|
error: ErrorPayload(
|
|
570
|
-
code:
|
|
577
|
+
code: RunnerWireErrorCode.hardwareControlUnavailable,
|
|
571
578
|
message: "actionButton requires a device model with an Action Button",
|
|
572
579
|
hint: "The Action Button is on iPhone 15 Pro and later and iPad Pro (M4) and later. Assign a Shortcut or App Intent to it in Settings > Action Button."
|
|
573
580
|
)
|
|
@@ -579,7 +586,7 @@ extension RunnerTests {
|
|
|
579
586
|
return Response(
|
|
580
587
|
ok: false,
|
|
581
588
|
error: ErrorPayload(
|
|
582
|
-
code:
|
|
589
|
+
code: RunnerWireErrorCode.hardwareControlUnavailable,
|
|
583
590
|
message: "\(command.command) requires a physical iPhone or iPad; XCUIDevice exposes no volume press on a simulator",
|
|
584
591
|
hint: "hardware-button volume-up/volume-down is supported on physical iOS devices through the runner or Appium; iOS Simulators have no pressable volume key."
|
|
585
592
|
)
|
|
@@ -587,17 +594,15 @@ extension RunnerTests {
|
|
|
587
594
|
}
|
|
588
595
|
return Response(ok: true, data: DataPayload(message: command.command.rawValue))
|
|
589
596
|
case .keyboardDismiss:
|
|
590
|
-
|
|
597
|
+
var dismissal: RunnerKeyboardDismissOutcome?
|
|
598
|
+
withBoundedInteractionIdleTimeoutIfSupported(activeApp, waits: .bothSkipped) {
|
|
599
|
+
dismissal = dismissKeyboard(app: activeApp)
|
|
600
|
+
}
|
|
601
|
+
guard let result = dismissal else {
|
|
602
|
+
return Response(ok: false, error: ErrorPayload(message: "keyboardDismiss produced no result"))
|
|
603
|
+
}
|
|
591
604
|
if result.wasVisible && !result.dismissed {
|
|
592
|
-
return Response(
|
|
593
|
-
ok: false,
|
|
594
|
-
error: ErrorPayload(
|
|
595
|
-
code: "UNSUPPORTED_OPERATION",
|
|
596
|
-
message: "Unable to dismiss the iOS keyboard: the keyboard exposes no dismiss key, and background taps are never attempted (no tap outside the keyboard can be proven side-effect-free)",
|
|
597
|
-
hint:
|
|
598
|
-
"An element whose center sits behind the on-screen keyboard is refused with tap_keyboard_occludes_target; one whose center stays above the keys presses normally. To end editing, tap the app's own Done/Cancel control, or use keyboard enter to press the return key when submission is wanted."
|
|
599
|
-
)
|
|
600
|
-
)
|
|
605
|
+
return Response(ok: false, error: keyboardDismissRefusal(dispatchedDismissal: result.dispatchedDismissal))
|
|
601
606
|
}
|
|
602
607
|
return Response(
|
|
603
608
|
ok: true,
|
|
@@ -610,14 +615,17 @@ extension RunnerTests {
|
|
|
610
615
|
)
|
|
611
616
|
)
|
|
612
617
|
case .keyboardReturn:
|
|
613
|
-
|
|
618
|
+
var press: (wasVisible: Bool, pressed: Bool, visible: Bool, fieldAttempted: Bool)?
|
|
619
|
+
withBoundedInteractionIdleTimeoutIfSupported(activeApp, waits: .preEventSkipped) {
|
|
620
|
+
press = pressKeyboardReturn(app: activeApp)
|
|
621
|
+
}
|
|
622
|
+
guard let result = press else {
|
|
623
|
+
return Response(ok: false, error: ErrorPayload(message: "keyboardReturn produced no result"))
|
|
624
|
+
}
|
|
614
625
|
if !result.pressed {
|
|
615
626
|
return Response(
|
|
616
627
|
ok: false,
|
|
617
|
-
error:
|
|
618
|
-
code: "UNSUPPORTED_OPERATION",
|
|
619
|
-
message: "Unable to press the iOS keyboard return key"
|
|
620
|
-
)
|
|
628
|
+
error: result.fieldAttempted ? keyboardReturnFieldAttemptFailure : keyboardReturnRefusal
|
|
621
629
|
)
|
|
622
630
|
}
|
|
623
631
|
return Response(
|
package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Interaction.swift
CHANGED
|
@@ -334,17 +334,7 @@ extension RunnerTests {
|
|
|
334
334
|
guard !value.isEmpty else {
|
|
335
335
|
return SelectorElementMatch(element: nil, isAmbiguous: false, usedNonHittableFallback: false)
|
|
336
336
|
}
|
|
337
|
-
let predicate:
|
|
338
|
-
switch selectorKey {
|
|
339
|
-
case "id":
|
|
340
|
-
predicate = NSPredicate(format: "identifier ==[c] %@", value)
|
|
341
|
-
case "label":
|
|
342
|
-
predicate = NSPredicate(format: "label ==[c] %@", value)
|
|
343
|
-
case "value":
|
|
344
|
-
predicate = NSPredicate(format: "value ==[c] %@", value)
|
|
345
|
-
case "text":
|
|
346
|
-
predicate = NSPredicate(format: "label ==[c] %@ OR identifier ==[c] %@ OR value ==[c] %@", value, value, value)
|
|
347
|
-
default:
|
|
337
|
+
guard let predicate = Self.selectorPredicate(key: selectorKey, value: value) else {
|
|
348
338
|
return SelectorElementMatch(element: nil, isAmbiguous: false, usedNonHittableFallback: false)
|
|
349
339
|
}
|
|
350
340
|
|
|
@@ -493,6 +483,47 @@ extension RunnerTests {
|
|
|
493
483
|
try resolveRunnerWindow(app: app).frame
|
|
494
484
|
}
|
|
495
485
|
|
|
486
|
+
static func selectorPredicate(key: String, value: String) -> NSPredicate? {
|
|
487
|
+
switch key {
|
|
488
|
+
case "id":
|
|
489
|
+
return NSPredicate(format: "identifier ==[c] %@", value)
|
|
490
|
+
case "label":
|
|
491
|
+
return NSPredicate(format: "label ==[c] %@", value)
|
|
492
|
+
case "value":
|
|
493
|
+
return NSPredicate(format: "value ==[c] %@", value)
|
|
494
|
+
case "text":
|
|
495
|
+
return NSPredicate(format: "label ==[c] %@ OR identifier ==[c] %@ OR value ==[c] %@", value, value, value)
|
|
496
|
+
default:
|
|
497
|
+
return nil
|
|
498
|
+
}
|
|
499
|
+
}
|
|
500
|
+
|
|
501
|
+
|
|
502
|
+
|
|
503
|
+
|
|
504
|
+
|
|
505
|
+
func probeElementHittability(app: XCUIApplication, selectorKey: String, selectorValue: String) throws -> Response {
|
|
506
|
+
let value = selectorValue.trimmingCharacters(in: .whitespacesAndNewlines)
|
|
507
|
+
guard !value.isEmpty, let predicate = Self.selectorPredicate(key: selectorKey, value: value) else {
|
|
508
|
+
return Response(ok: true, data: DataPayload(found: false, matchCount: 0))
|
|
509
|
+
}
|
|
510
|
+
let matches = try elementQueries(app: app, matching: .any)
|
|
511
|
+
.flatMap { $0.matching(predicate).allElementsBoundByIndex }
|
|
512
|
+
.filter(\.exists)
|
|
513
|
+
guard matches.count == 1, let element = matches.first else {
|
|
514
|
+
return Response(ok: true, data: DataPayload(found: !matches.isEmpty, matchCount: matches.count))
|
|
515
|
+
}
|
|
516
|
+
return Response(
|
|
517
|
+
ok: true,
|
|
518
|
+
data: DataPayload(
|
|
519
|
+
found: true,
|
|
520
|
+
matchCount: 1,
|
|
521
|
+
hittable: element.isHittable,
|
|
522
|
+
rect: SnapshotRect(element.frame)
|
|
523
|
+
)
|
|
524
|
+
)
|
|
525
|
+
}
|
|
526
|
+
|
|
496
527
|
func queryElement(app: XCUIApplication, selectorKey: String, selectorValue: String) throws -> Response {
|
|
497
528
|
|
|
498
529
|
|
package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Keyboard.swift
CHANGED
|
@@ -33,6 +33,18 @@ enum RunnerKeyboardDismissMechanism: String {
|
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
|
|
36
|
+
struct RunnerKeyboardDismissOutcome {
|
|
37
|
+
let wasVisible: Bool
|
|
38
|
+
let dismissed: Bool
|
|
39
|
+
let visible: Bool
|
|
40
|
+
let mechanism: RunnerKeyboardDismissMechanism?
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
let dispatchedDismissal: Bool
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
|
|
36
48
|
|
|
37
49
|
enum RunnerKeyboardBandFact: Equatable {
|
|
38
50
|
case visible(CGRect)
|
|
@@ -189,20 +201,32 @@ extension RunnerTests {
|
|
|
189
201
|
return visibleKeyboardFrame(app: app) != nil
|
|
190
202
|
}
|
|
191
203
|
|
|
192
|
-
func dismissKeyboard(
|
|
193
|
-
app: XCUIApplication
|
|
194
|
-
) -> (wasVisible: Bool, dismissed: Bool, visible: Bool, mechanism: RunnerKeyboardDismissMechanism?) {
|
|
204
|
+
func dismissKeyboard(app: XCUIApplication) -> RunnerKeyboardDismissOutcome {
|
|
195
205
|
let keyboard = app.keyboards.firstMatch
|
|
196
206
|
let wasVisible = isKeyboardVisible(app: app)
|
|
197
207
|
guard wasVisible else {
|
|
198
|
-
return (
|
|
208
|
+
return RunnerKeyboardDismissOutcome(
|
|
209
|
+
wasVisible: false,
|
|
210
|
+
dismissed: false,
|
|
211
|
+
visible: false,
|
|
212
|
+
mechanism: nil,
|
|
213
|
+
dispatchedDismissal: false
|
|
214
|
+
)
|
|
199
215
|
}
|
|
200
216
|
|
|
201
217
|
#if os(tvOS)
|
|
202
218
|
_ = pressTvRemote(.menu)
|
|
203
219
|
sleepFor(0.2)
|
|
204
|
-
let
|
|
205
|
-
return (
|
|
220
|
+
let tvVisible = isKeyboardVisible(app: app)
|
|
221
|
+
return RunnerKeyboardDismissOutcome(
|
|
222
|
+
wasVisible: true,
|
|
223
|
+
dismissed: !tvVisible,
|
|
224
|
+
visible: tvVisible,
|
|
225
|
+
mechanism: tvVisible ? nil : .dismissKey,
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
dispatchedDismissal: true
|
|
229
|
+
)
|
|
206
230
|
#else
|
|
207
231
|
if tapKeyboardDismissControl(app: app) {
|
|
208
232
|
_ = keyboard.waitForNonExistence(timeout: KeyboardDismissObservationTiming.timeout)
|
|
@@ -213,7 +237,13 @@ extension RunnerTests {
|
|
|
213
237
|
requiredConsecutiveMatches: KeyboardDismissObservationTiming.settleRequiredConsecutiveMatches
|
|
214
238
|
)
|
|
215
239
|
let visible = isKeyboardVisible(app: app)
|
|
216
|
-
return (
|
|
240
|
+
return RunnerKeyboardDismissOutcome(
|
|
241
|
+
wasVisible: true,
|
|
242
|
+
dismissed: !visible,
|
|
243
|
+
visible: visible,
|
|
244
|
+
mechanism: visible ? nil : .dismissKey,
|
|
245
|
+
dispatchedDismissal: true
|
|
246
|
+
)
|
|
217
247
|
}
|
|
218
248
|
|
|
219
249
|
|
|
@@ -222,7 +252,13 @@ extension RunnerTests {
|
|
|
222
252
|
|
|
223
253
|
|
|
224
254
|
|
|
225
|
-
return (
|
|
255
|
+
return RunnerKeyboardDismissOutcome(
|
|
256
|
+
wasVisible: true,
|
|
257
|
+
dismissed: false,
|
|
258
|
+
visible: isKeyboardVisible(app: app),
|
|
259
|
+
mechanism: nil,
|
|
260
|
+
dispatchedDismissal: false
|
|
261
|
+
)
|
|
226
262
|
#endif
|
|
227
263
|
}
|
|
228
264
|
|
|
@@ -231,6 +267,53 @@ extension RunnerTests {
|
|
|
231
267
|
|
|
232
268
|
|
|
233
269
|
|
|
270
|
+
func keyboardDismissRefusal(dispatchedDismissal: Bool) -> ErrorPayload {
|
|
271
|
+
if dispatchedDismissal {
|
|
272
|
+
return ErrorPayload(
|
|
273
|
+
code: "UNSUPPORTED_OPERATION",
|
|
274
|
+
message: "Unable to dismiss the keyboard: a dismiss mechanism ran and the keyboard stayed visible",
|
|
275
|
+
hint: keyboardDismissRefusalHint
|
|
276
|
+
)
|
|
277
|
+
}
|
|
278
|
+
return ErrorPayload(
|
|
279
|
+
code: RunnerWireErrorCode.keyboardDismissUnavailable,
|
|
280
|
+
message: "Unable to dismiss the keyboard: it exposes no dismiss key, and background taps are never attempted (no tap outside the keyboard can be proven side-effect-free)",
|
|
281
|
+
hint: keyboardDismissRefusalHint
|
|
282
|
+
)
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
private var keyboardDismissRefusalHint: String {
|
|
286
|
+
return
|
|
287
|
+
"An element whose center sits behind the on-screen keyboard is refused with tap_keyboard_occludes_target; one whose center stays above the keys presses normally. To end editing, tap the app's own Done/Cancel control, or use keyboard enter to press the return key when submission is wanted."
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
|
|
291
|
+
|
|
292
|
+
|
|
293
|
+
|
|
294
|
+
var keyboardReturnRefusal: ErrorPayload {
|
|
295
|
+
return ErrorPayload(
|
|
296
|
+
code: RunnerWireErrorCode.keyboardReturnUnavailable,
|
|
297
|
+
message: "Unable to press the keyboard return key: the keyboard exposes no return-like key and no text field was available to submit",
|
|
298
|
+
hint: "Tap the app's own submit control by its ref, or focus a text field with fill or type before asking keyboard enter to submit it."
|
|
299
|
+
)
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
|
|
303
|
+
|
|
304
|
+
var keyboardReturnFieldAttemptFailure: ErrorPayload {
|
|
305
|
+
return ErrorPayload(
|
|
306
|
+
code: "UNSUPPORTED_OPERATION",
|
|
307
|
+
message: "Unable to press the keyboard return key: the only text field was found, but tapping it and typing a return failed",
|
|
308
|
+
hint: "Focus the field with fill or type, or tap the app's own submit control by its ref."
|
|
309
|
+
)
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
|
|
313
|
+
|
|
314
|
+
|
|
315
|
+
|
|
316
|
+
|
|
234
317
|
|
|
235
318
|
|
|
236
319
|
|
|
@@ -271,26 +354,30 @@ extension RunnerTests {
|
|
|
271
354
|
return runnerPngData(for: image)
|
|
272
355
|
}
|
|
273
356
|
|
|
274
|
-
|
|
357
|
+
|
|
358
|
+
|
|
359
|
+
func pressKeyboardReturn(
|
|
360
|
+
app: XCUIApplication
|
|
361
|
+
) -> (wasVisible: Bool, pressed: Bool, visible: Bool, fieldAttempted: Bool) {
|
|
275
362
|
#if os(tvOS)
|
|
276
|
-
return (wasVisible: false, pressed: pressTvRemote(.select), visible: false)
|
|
363
|
+
return (wasVisible: false, pressed: pressTvRemote(.select), visible: false, fieldAttempted: false)
|
|
277
364
|
#elseif os(iOS)
|
|
278
365
|
let wasVisible = isKeyboardVisible(app: app)
|
|
279
366
|
if tapKeyboardReturnControl(app: app) {
|
|
280
367
|
sleepFor(0.2)
|
|
281
|
-
return (wasVisible: wasVisible, pressed: true, visible: isKeyboardVisible(app: app))
|
|
368
|
+
return (wasVisible: wasVisible, pressed: true, visible: isKeyboardVisible(app: app), fieldAttempted: false)
|
|
282
369
|
}
|
|
283
370
|
|
|
284
371
|
guard typeKeyboardReturn({ app.typeText(XCUIKeyboardKey.return.rawValue) }) else {
|
|
285
372
|
if let singleTarget = singleTextEntryElement(app: app) {
|
|
286
373
|
return pressKeyboardReturn(on: singleTarget, app: app, wasVisible: wasVisible)
|
|
287
374
|
}
|
|
288
|
-
return (wasVisible: wasVisible, pressed: false, visible: isKeyboardVisible(app: app))
|
|
375
|
+
return (wasVisible: wasVisible, pressed: false, visible: isKeyboardVisible(app: app), fieldAttempted: false)
|
|
289
376
|
}
|
|
290
377
|
sleepFor(0.2)
|
|
291
|
-
return (wasVisible: wasVisible, pressed: true, visible: isKeyboardVisible(app: app))
|
|
378
|
+
return (wasVisible: wasVisible, pressed: true, visible: isKeyboardVisible(app: app), fieldAttempted: false)
|
|
292
379
|
#else
|
|
293
|
-
return (wasVisible: false, pressed: false, visible: false)
|
|
380
|
+
return (wasVisible: false, pressed: false, visible: false, fieldAttempted: false)
|
|
294
381
|
#endif
|
|
295
382
|
}
|
|
296
383
|
|
|
@@ -312,7 +399,7 @@ extension RunnerTests {
|
|
|
312
399
|
on element: XCUIElement,
|
|
313
400
|
app: XCUIApplication,
|
|
314
401
|
wasVisible: Bool
|
|
315
|
-
) -> (wasVisible: Bool, pressed: Bool, visible: Bool) {
|
|
402
|
+
) -> (wasVisible: Bool, pressed: Bool, visible: Bool, fieldAttempted: Bool) {
|
|
316
403
|
#if os(iOS)
|
|
317
404
|
|
|
318
405
|
|
|
@@ -321,12 +408,12 @@ extension RunnerTests {
|
|
|
321
408
|
app.typeText(XCUIKeyboardKey.return.rawValue)
|
|
322
409
|
})
|
|
323
410
|
guard typed else {
|
|
324
|
-
return (wasVisible: wasVisible, pressed: false, visible: isKeyboardVisible(app: app))
|
|
411
|
+
return (wasVisible: wasVisible, pressed: false, visible: isKeyboardVisible(app: app), fieldAttempted: true)
|
|
325
412
|
}
|
|
326
413
|
sleepFor(0.2)
|
|
327
|
-
return (wasVisible: wasVisible, pressed: true, visible: isKeyboardVisible(app: app))
|
|
414
|
+
return (wasVisible: wasVisible, pressed: true, visible: isKeyboardVisible(app: app), fieldAttempted: true)
|
|
328
415
|
#else
|
|
329
|
-
return (wasVisible: wasVisible, pressed: false, visible: false)
|
|
416
|
+
return (wasVisible: wasVisible, pressed: false, visible: false, fieldAttempted: false)
|
|
330
417
|
#endif
|
|
331
418
|
}
|
|
332
419
|
|
|
@@ -406,20 +493,34 @@ extension RunnerTests {
|
|
|
406
493
|
#endif
|
|
407
494
|
}
|
|
408
495
|
|
|
409
|
-
|
|
496
|
+
|
|
497
|
+
|
|
498
|
+
|
|
499
|
+
func findKeyboardReturnControl(app: XCUIApplication) -> XCUIElement? {
|
|
410
500
|
#if os(iOS)
|
|
411
|
-
for label in
|
|
501
|
+
for label in RunnerKeyboardReturnKey.probeLabels {
|
|
412
502
|
let candidates = [
|
|
413
503
|
app.keyboards.buttons[label],
|
|
414
504
|
app.keyboards.keys[label],
|
|
415
505
|
]
|
|
416
506
|
if let hittable = candidates.first(where: { $0.exists && $0.isHittable }) {
|
|
417
|
-
hittable
|
|
418
|
-
return true
|
|
507
|
+
return hittable
|
|
419
508
|
}
|
|
420
509
|
}
|
|
421
510
|
#endif
|
|
511
|
+
return nil
|
|
512
|
+
}
|
|
513
|
+
|
|
514
|
+
private func tapKeyboardReturnControl(app: XCUIApplication) -> Bool {
|
|
515
|
+
#if os(iOS)
|
|
516
|
+
guard let control = findKeyboardReturnControl(app: app) else {
|
|
517
|
+
return false
|
|
518
|
+
}
|
|
519
|
+
control.tap()
|
|
520
|
+
return true
|
|
521
|
+
#else
|
|
422
522
|
return false
|
|
523
|
+
#endif
|
|
423
524
|
}
|
|
424
525
|
|
|
425
526
|
private func isKeyboardAccessoryControl(_ element: XCUIElement, keyboardFrame: CGRect) -> Bool {
|
package/dist/apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Models.swift
CHANGED
|
@@ -246,6 +246,8 @@ struct Command: Codable {
|
|
|
246
246
|
let text: String?
|
|
247
247
|
let selectorKey: String?
|
|
248
248
|
let selectorValue: String?
|
|
249
|
+
|
|
250
|
+
let hittabilityProbe: Bool?
|
|
249
251
|
let allowNonHittableCoordinateFallback: Bool?
|
|
250
252
|
let delayMs: Int?
|
|
251
253
|
let textEntryMode: String?
|
|
@@ -572,6 +574,11 @@ struct DataPayload: Codable {
|
|
|
572
574
|
|
|
573
575
|
|
|
574
576
|
var screenshotMetadata: ScreenshotMetadataPayload?
|
|
577
|
+
|
|
578
|
+
|
|
579
|
+
var matchCount: Int?
|
|
580
|
+
var hittable: Bool?
|
|
581
|
+
var rect: SnapshotRect?
|
|
575
582
|
}
|
|
576
583
|
|
|
577
584
|
|