@limrun/appium-xcuitest-driver 10.4.3-lim.1
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/CHANGELOG.md +2600 -0
- package/LICENSE +201 -0
- package/README.md +55 -0
- package/build/index.d.ts +5 -0
- package/build/index.js +41 -0
- package/build/lib/app-infos-cache.d.ts +62 -0
- package/build/lib/app-infos-cache.d.ts.map +1 -0
- package/build/lib/app-infos-cache.js +180 -0
- package/build/lib/app-infos-cache.js.map +1 -0
- package/build/lib/app-utils.d.ts +89 -0
- package/build/lib/app-utils.d.ts.map +1 -0
- package/build/lib/app-utils.js +657 -0
- package/build/lib/app-utils.js.map +1 -0
- package/build/lib/commands/active-app-info.d.ts +9 -0
- package/build/lib/commands/active-app-info.d.ts.map +1 -0
- package/build/lib/commands/active-app-info.js +14 -0
- package/build/lib/commands/active-app-info.js.map +1 -0
- package/build/lib/commands/advanced-battery-types.d.ts +444 -0
- package/build/lib/commands/advanced-battery-types.d.ts.map +1 -0
- package/build/lib/commands/advanced-battery-types.js +8 -0
- package/build/lib/commands/advanced-battery-types.js.map +1 -0
- package/build/lib/commands/alert.d.ts +45 -0
- package/build/lib/commands/alert.d.ts.map +1 -0
- package/build/lib/commands/alert.js +87 -0
- package/build/lib/commands/alert.js.map +1 -0
- package/build/lib/commands/app-management.d.ts +153 -0
- package/build/lib/commands/app-management.d.ts.map +1 -0
- package/build/lib/commands/app-management.js +323 -0
- package/build/lib/commands/app-management.js.map +1 -0
- package/build/lib/commands/app-strings.d.ts +16 -0
- package/build/lib/commands/app-strings.d.ts.map +1 -0
- package/build/lib/commands/app-strings.js +30 -0
- package/build/lib/commands/app-strings.js.map +1 -0
- package/build/lib/commands/appearance.d.ts +22 -0
- package/build/lib/commands/appearance.d.ts.map +1 -0
- package/build/lib/commands/appearance.js +74 -0
- package/build/lib/commands/appearance.js.map +1 -0
- package/build/lib/commands/audit.d.ts +43 -0
- package/build/lib/commands/audit.d.ts.map +1 -0
- package/build/lib/commands/audit.js +31 -0
- package/build/lib/commands/audit.js.map +1 -0
- package/build/lib/commands/battery.d.ts +13 -0
- package/build/lib/commands/battery.d.ts.map +1 -0
- package/build/lib/commands/battery.js +49 -0
- package/build/lib/commands/battery.js.map +1 -0
- package/build/lib/commands/bidi/constants.d.ts +6 -0
- package/build/lib/commands/bidi/constants.d.ts.map +1 -0
- package/build/lib/commands/bidi/constants.js +10 -0
- package/build/lib/commands/bidi/constants.js.map +1 -0
- package/build/lib/commands/bidi/models.d.ts +9 -0
- package/build/lib/commands/bidi/models.d.ts.map +1 -0
- package/build/lib/commands/bidi/models.js +54 -0
- package/build/lib/commands/bidi/models.js.map +1 -0
- package/build/lib/commands/bidi/types.d.ts +26 -0
- package/build/lib/commands/bidi/types.d.ts.map +1 -0
- package/build/lib/commands/bidi/types.js +4 -0
- package/build/lib/commands/bidi/types.js.map +1 -0
- package/build/lib/commands/biometric.d.ts +32 -0
- package/build/lib/commands/biometric.d.ts.map +1 -0
- package/build/lib/commands/biometric.js +54 -0
- package/build/lib/commands/biometric.js.map +1 -0
- package/build/lib/commands/certificate.d.ts +50 -0
- package/build/lib/commands/certificate.d.ts.map +1 -0
- package/build/lib/commands/certificate.js +454 -0
- package/build/lib/commands/certificate.js.map +1 -0
- package/build/lib/commands/clipboard.d.ts +21 -0
- package/build/lib/commands/clipboard.d.ts.map +1 -0
- package/build/lib/commands/clipboard.js +36 -0
- package/build/lib/commands/clipboard.js.map +1 -0
- package/build/lib/commands/condition.d.ts +102 -0
- package/build/lib/commands/condition.d.ts.map +1 -0
- package/build/lib/commands/condition.js +146 -0
- package/build/lib/commands/condition.js.map +1 -0
- package/build/lib/commands/content-size.d.ts +30 -0
- package/build/lib/commands/content-size.d.ts.map +1 -0
- package/build/lib/commands/content-size.js +67 -0
- package/build/lib/commands/content-size.js.map +1 -0
- package/build/lib/commands/context.d.ts +191 -0
- package/build/lib/commands/context.d.ts.map +1 -0
- package/build/lib/commands/context.js +625 -0
- package/build/lib/commands/context.js.map +1 -0
- package/build/lib/commands/deviceInfo.d.ts +12 -0
- package/build/lib/commands/deviceInfo.d.ts.map +1 -0
- package/build/lib/commands/deviceInfo.js +25 -0
- package/build/lib/commands/deviceInfo.js.map +1 -0
- package/build/lib/commands/element.d.ts +108 -0
- package/build/lib/commands/element.d.ts.map +1 -0
- package/build/lib/commands/element.js +395 -0
- package/build/lib/commands/element.js.map +1 -0
- package/build/lib/commands/enum.d.ts +105 -0
- package/build/lib/commands/enum.d.ts.map +1 -0
- package/build/lib/commands/enum.js +113 -0
- package/build/lib/commands/enum.js.map +1 -0
- package/build/lib/commands/execute.d.ts +33 -0
- package/build/lib/commands/execute.d.ts.map +1 -0
- package/build/lib/commands/execute.js +142 -0
- package/build/lib/commands/execute.js.map +1 -0
- package/build/lib/commands/file-movement.d.ts +90 -0
- package/build/lib/commands/file-movement.d.ts.map +1 -0
- package/build/lib/commands/file-movement.js +477 -0
- package/build/lib/commands/file-movement.js.map +1 -0
- package/build/lib/commands/find.d.ts +21 -0
- package/build/lib/commands/find.d.ts.map +1 -0
- package/build/lib/commands/find.js +199 -0
- package/build/lib/commands/find.js.map +1 -0
- package/build/lib/commands/general.d.ts +137 -0
- package/build/lib/commands/general.d.ts.map +1 -0
- package/build/lib/commands/general.js +270 -0
- package/build/lib/commands/general.js.map +1 -0
- package/build/lib/commands/geolocation.d.ts +57 -0
- package/build/lib/commands/geolocation.d.ts.map +1 -0
- package/build/lib/commands/geolocation.js +58 -0
- package/build/lib/commands/geolocation.js.map +1 -0
- package/build/lib/commands/gesture.d.ts +283 -0
- package/build/lib/commands/gesture.d.ts.map +1 -0
- package/build/lib/commands/gesture.js +565 -0
- package/build/lib/commands/gesture.js.map +1 -0
- package/build/lib/commands/hid-event.d.ts +2773 -0
- package/build/lib/commands/hid-event.d.ts.map +1 -0
- package/build/lib/commands/hid-event.js +1633 -0
- package/build/lib/commands/hid-event.js.map +1 -0
- package/build/lib/commands/increase-contrast.d.ts +24 -0
- package/build/lib/commands/increase-contrast.d.ts.map +1 -0
- package/build/lib/commands/increase-contrast.js +49 -0
- package/build/lib/commands/increase-contrast.js.map +1 -0
- package/build/lib/commands/iohid.d.ts +1372 -0
- package/build/lib/commands/iohid.d.ts.map +1 -0
- package/build/lib/commands/iohid.js +63 -0
- package/build/lib/commands/iohid.js.map +1 -0
- package/build/lib/commands/keyboard.d.ts +32 -0
- package/build/lib/commands/keyboard.d.ts.map +1 -0
- package/build/lib/commands/keyboard.js +67 -0
- package/build/lib/commands/keyboard.js.map +1 -0
- package/build/lib/commands/keychains.d.ts +10 -0
- package/build/lib/commands/keychains.d.ts.map +1 -0
- package/build/lib/commands/keychains.js +22 -0
- package/build/lib/commands/keychains.js.map +1 -0
- package/build/lib/commands/localization.d.ts +17 -0
- package/build/lib/commands/localization.d.ts.map +1 -0
- package/build/lib/commands/localization.js +34 -0
- package/build/lib/commands/localization.js.map +1 -0
- package/build/lib/commands/location.d.ts +40 -0
- package/build/lib/commands/location.d.ts.map +1 -0
- package/build/lib/commands/location.js +121 -0
- package/build/lib/commands/location.js.map +1 -0
- package/build/lib/commands/lock.d.ts +23 -0
- package/build/lib/commands/lock.d.ts.map +1 -0
- package/build/lib/commands/lock.js +49 -0
- package/build/lib/commands/lock.js.map +1 -0
- package/build/lib/commands/log.d.ts +68 -0
- package/build/lib/commands/log.d.ts.map +1 -0
- package/build/lib/commands/log.js +287 -0
- package/build/lib/commands/log.js.map +1 -0
- package/build/lib/commands/memory.d.ts +11 -0
- package/build/lib/commands/memory.d.ts.map +1 -0
- package/build/lib/commands/memory.js +49 -0
- package/build/lib/commands/memory.js.map +1 -0
- package/build/lib/commands/navigation.d.ts +44 -0
- package/build/lib/commands/navigation.d.ts.map +1 -0
- package/build/lib/commands/navigation.js +121 -0
- package/build/lib/commands/navigation.js.map +1 -0
- package/build/lib/commands/notifications.d.ts +28 -0
- package/build/lib/commands/notifications.d.ts.map +1 -0
- package/build/lib/commands/notifications.js +64 -0
- package/build/lib/commands/notifications.js.map +1 -0
- package/build/lib/commands/pasteboard.d.ts +23 -0
- package/build/lib/commands/pasteboard.d.ts.map +1 -0
- package/build/lib/commands/pasteboard.js +43 -0
- package/build/lib/commands/pasteboard.js.map +1 -0
- package/build/lib/commands/pcap.d.ts +54 -0
- package/build/lib/commands/pcap.d.ts.map +1 -0
- package/build/lib/commands/pcap.js +149 -0
- package/build/lib/commands/pcap.js.map +1 -0
- package/build/lib/commands/performance.d.ts +85 -0
- package/build/lib/commands/performance.d.ts.map +1 -0
- package/build/lib/commands/performance.js +331 -0
- package/build/lib/commands/performance.js.map +1 -0
- package/build/lib/commands/permissions.d.ts +36 -0
- package/build/lib/commands/permissions.d.ts.map +1 -0
- package/build/lib/commands/permissions.js +80 -0
- package/build/lib/commands/permissions.js.map +1 -0
- package/build/lib/commands/proxy-helper.d.ts +15 -0
- package/build/lib/commands/proxy-helper.d.ts.map +1 -0
- package/build/lib/commands/proxy-helper.js +117 -0
- package/build/lib/commands/proxy-helper.js.map +1 -0
- package/build/lib/commands/record-audio.d.ts +69 -0
- package/build/lib/commands/record-audio.d.ts.map +1 -0
- package/build/lib/commands/record-audio.js +228 -0
- package/build/lib/commands/record-audio.js.map +1 -0
- package/build/lib/commands/recordscreen.d.ts +89 -0
- package/build/lib/commands/recordscreen.d.ts.map +1 -0
- package/build/lib/commands/recordscreen.js +326 -0
- package/build/lib/commands/recordscreen.js.map +1 -0
- package/build/lib/commands/screenshots.d.ts +16 -0
- package/build/lib/commands/screenshots.d.ts.map +1 -0
- package/build/lib/commands/screenshots.js +129 -0
- package/build/lib/commands/screenshots.js.map +1 -0
- package/build/lib/commands/simctl.d.ts +27 -0
- package/build/lib/commands/simctl.d.ts.map +1 -0
- package/build/lib/commands/simctl.js +65 -0
- package/build/lib/commands/simctl.js.map +1 -0
- package/build/lib/commands/source.d.ts +16 -0
- package/build/lib/commands/source.d.ts.map +1 -0
- package/build/lib/commands/source.js +128 -0
- package/build/lib/commands/source.js.map +1 -0
- package/build/lib/commands/timeouts.d.ts +53 -0
- package/build/lib/commands/timeouts.d.ts.map +1 -0
- package/build/lib/commands/timeouts.js +71 -0
- package/build/lib/commands/timeouts.js.map +1 -0
- package/build/lib/commands/types.d.ts +539 -0
- package/build/lib/commands/types.d.ts.map +1 -0
- package/build/lib/commands/types.js +3 -0
- package/build/lib/commands/types.js.map +1 -0
- package/build/lib/commands/web.d.ts +297 -0
- package/build/lib/commands/web.d.ts.map +1 -0
- package/build/lib/commands/web.js +1029 -0
- package/build/lib/commands/web.js.map +1 -0
- package/build/lib/commands/xctest-record-screen.d.ts +92 -0
- package/build/lib/commands/xctest-record-screen.d.ts.map +1 -0
- package/build/lib/commands/xctest-record-screen.js +193 -0
- package/build/lib/commands/xctest-record-screen.js.map +1 -0
- package/build/lib/commands/xctest.d.ts +71 -0
- package/build/lib/commands/xctest.d.ts.map +1 -0
- package/build/lib/commands/xctest.js +257 -0
- package/build/lib/commands/xctest.js.map +1 -0
- package/build/lib/css-converter.d.ts +10 -0
- package/build/lib/css-converter.d.ts.map +1 -0
- package/build/lib/css-converter.js +258 -0
- package/build/lib/css-converter.js.map +1 -0
- package/build/lib/desired-caps.d.ts +506 -0
- package/build/lib/desired-caps.d.ts.map +1 -0
- package/build/lib/desired-caps.js +400 -0
- package/build/lib/desired-caps.js.map +1 -0
- package/build/lib/device-connections-factory.d.ts +13 -0
- package/build/lib/device-connections-factory.d.ts.map +1 -0
- package/build/lib/device-connections-factory.js +244 -0
- package/build/lib/device-connections-factory.js.map +1 -0
- package/build/lib/device-log/helpers.d.ts +10 -0
- package/build/lib/device-log/helpers.d.ts.map +1 -0
- package/build/lib/device-log/helpers.js +37 -0
- package/build/lib/device-log/helpers.js.map +1 -0
- package/build/lib/device-log/ios-crash-log.d.ts +34 -0
- package/build/lib/device-log/ios-crash-log.d.ts.map +1 -0
- package/build/lib/device-log/ios-crash-log.js +141 -0
- package/build/lib/device-log/ios-crash-log.js.map +1 -0
- package/build/lib/device-log/ios-device-log.d.ts +19 -0
- package/build/lib/device-log/ios-device-log.d.ts.map +1 -0
- package/build/lib/device-log/ios-device-log.js +42 -0
- package/build/lib/device-log/ios-device-log.js.map +1 -0
- package/build/lib/device-log/ios-log.d.ts +24 -0
- package/build/lib/device-log/ios-log.d.ts.map +1 -0
- package/build/lib/device-log/ios-log.js +50 -0
- package/build/lib/device-log/ios-log.js.map +1 -0
- package/build/lib/device-log/ios-performance-log.d.ts +18 -0
- package/build/lib/device-log/ios-performance-log.d.ts.map +1 -0
- package/build/lib/device-log/ios-performance-log.js +43 -0
- package/build/lib/device-log/ios-performance-log.js.map +1 -0
- package/build/lib/device-log/ios-simulator-log.d.ts +38 -0
- package/build/lib/device-log/ios-simulator-log.d.ts.map +1 -0
- package/build/lib/device-log/ios-simulator-log.js +184 -0
- package/build/lib/device-log/ios-simulator-log.js.map +1 -0
- package/build/lib/device-log/line-consuming-log.d.ts +9 -0
- package/build/lib/device-log/line-consuming-log.d.ts.map +1 -0
- package/build/lib/device-log/line-consuming-log.js +16 -0
- package/build/lib/device-log/line-consuming-log.js.map +1 -0
- package/build/lib/device-log/safari-console-log.d.ts +67 -0
- package/build/lib/device-log/safari-console-log.d.ts.map +1 -0
- package/build/lib/device-log/safari-console-log.js +81 -0
- package/build/lib/device-log/safari-console-log.js.map +1 -0
- package/build/lib/device-log/safari-network-log.d.ts +75 -0
- package/build/lib/device-log/safari-network-log.d.ts.map +1 -0
- package/build/lib/device-log/safari-network-log.js +47 -0
- package/build/lib/device-log/safari-network-log.js.map +1 -0
- package/build/lib/doctor/checks.d.ts +3 -0
- package/build/lib/doctor/checks.d.ts.map +1 -0
- package/build/lib/doctor/checks.js +39 -0
- package/build/lib/doctor/checks.js.map +1 -0
- package/build/lib/doctor/optional-checks.d.ts +46 -0
- package/build/lib/doctor/optional-checks.d.ts.map +1 -0
- package/build/lib/doctor/optional-checks.js +129 -0
- package/build/lib/doctor/optional-checks.js.map +1 -0
- package/build/lib/doctor/required-checks.d.ts +42 -0
- package/build/lib/doctor/required-checks.d.ts.map +1 -0
- package/build/lib/doctor/required-checks.js +94 -0
- package/build/lib/doctor/required-checks.js.map +1 -0
- package/build/lib/doctor/utils.d.ts +8 -0
- package/build/lib/doctor/utils.d.ts.map +1 -0
- package/build/lib/doctor/utils.js +21 -0
- package/build/lib/doctor/utils.js.map +1 -0
- package/build/lib/driver.d.ts +2429 -0
- package/build/lib/driver.d.ts.map +1 -0
- package/build/lib/driver.js +1967 -0
- package/build/lib/driver.js.map +1 -0
- package/build/lib/execute-method-map.d.ts +552 -0
- package/build/lib/execute-method-map.d.ts.map +1 -0
- package/build/lib/execute-method-map.js +586 -0
- package/build/lib/execute-method-map.js.map +1 -0
- package/build/lib/ios-fs-helpers.d.ts +75 -0
- package/build/lib/ios-fs-helpers.d.ts.map +1 -0
- package/build/lib/ios-fs-helpers.js +370 -0
- package/build/lib/ios-fs-helpers.js.map +1 -0
- package/build/lib/ios-generic-simulators.d.ts +6 -0
- package/build/lib/ios-generic-simulators.d.ts.map +1 -0
- package/build/lib/ios-generic-simulators.js +14 -0
- package/build/lib/ios-generic-simulators.js.map +1 -0
- package/build/lib/logger.d.ts +3 -0
- package/build/lib/logger.d.ts.map +1 -0
- package/build/lib/logger.js +6 -0
- package/build/lib/logger.js.map +1 -0
- package/build/lib/method-map.d.ts +229 -0
- package/build/lib/method-map.d.ts.map +1 -0
- package/build/lib/method-map.js +200 -0
- package/build/lib/method-map.js.map +1 -0
- package/build/lib/real-device-clients/base-device-client.d.ts +22 -0
- package/build/lib/real-device-clients/base-device-client.d.ts.map +1 -0
- package/build/lib/real-device-clients/base-device-client.js +14 -0
- package/build/lib/real-device-clients/base-device-client.js.map +1 -0
- package/build/lib/real-device-clients/py-ios-device-client.d.ts +21 -0
- package/build/lib/real-device-clients/py-ios-device-client.d.ts.map +1 -0
- package/build/lib/real-device-clients/py-ios-device-client.js +125 -0
- package/build/lib/real-device-clients/py-ios-device-client.js.map +1 -0
- package/build/lib/real-device-management.d.ts +53 -0
- package/build/lib/real-device-management.d.ts.map +1 -0
- package/build/lib/real-device-management.js +128 -0
- package/build/lib/real-device-management.js.map +1 -0
- package/build/lib/real-device.d.ts +112 -0
- package/build/lib/real-device.d.ts.map +1 -0
- package/build/lib/real-device.js +352 -0
- package/build/lib/real-device.js.map +1 -0
- package/build/lib/simulator-management.d.ts +96 -0
- package/build/lib/simulator-management.d.ts.map +1 -0
- package/build/lib/simulator-management.js +278 -0
- package/build/lib/simulator-management.js.map +1 -0
- package/build/lib/stubs.d.ts +3 -0
- package/build/lib/stubs.d.ts.map +1 -0
- package/build/lib/stubs.js +3 -0
- package/build/lib/stubs.js.map +1 -0
- package/build/lib/types.d.ts +31 -0
- package/build/lib/types.d.ts.map +1 -0
- package/build/lib/types.js +3 -0
- package/build/lib/types.js.map +1 -0
- package/build/lib/utils.d.ts +191 -0
- package/build/lib/utils.d.ts.map +1 -0
- package/build/lib/utils.js +549 -0
- package/build/lib/utils.js.map +1 -0
- package/build/lib/xcrun.d.ts +3 -0
- package/build/lib/xcrun.d.ts.map +1 -0
- package/build/lib/xcrun.js +17 -0
- package/build/lib/xcrun.js.map +1 -0
- package/index.js +7 -0
- package/lib/app-infos-cache.js +187 -0
- package/lib/app-utils.js +710 -0
- package/lib/commands/active-app-info.js +12 -0
- package/lib/commands/advanced-battery-types.ts +454 -0
- package/lib/commands/alert.js +88 -0
- package/lib/commands/app-management.js +346 -0
- package/lib/commands/app-strings.js +30 -0
- package/lib/commands/appearance.js +71 -0
- package/lib/commands/audit.js +31 -0
- package/lib/commands/battery.js +45 -0
- package/lib/commands/bidi/constants.ts +6 -0
- package/lib/commands/bidi/models.ts +55 -0
- package/lib/commands/bidi/types.ts +31 -0
- package/lib/commands/biometric.js +53 -0
- package/lib/commands/certificate.js +497 -0
- package/lib/commands/clipboard.js +35 -0
- package/lib/commands/condition.js +155 -0
- package/lib/commands/content-size.js +68 -0
- package/lib/commands/context.js +705 -0
- package/lib/commands/deviceInfo.js +27 -0
- package/lib/commands/element.js +423 -0
- package/lib/commands/enum.ts +108 -0
- package/lib/commands/execute.js +153 -0
- package/lib/commands/file-movement.js +510 -0
- package/lib/commands/find.js +205 -0
- package/lib/commands/general.js +278 -0
- package/lib/commands/geolocation.js +56 -0
- package/lib/commands/gesture.js +596 -0
- package/lib/commands/hid-event.ts +1634 -0
- package/lib/commands/increase-contrast.js +50 -0
- package/lib/commands/iohid.js +64 -0
- package/lib/commands/keyboard.js +62 -0
- package/lib/commands/keychains.js +18 -0
- package/lib/commands/localization.js +30 -0
- package/lib/commands/location.js +131 -0
- package/lib/commands/lock.js +46 -0
- package/lib/commands/log.js +327 -0
- package/lib/commands/memory.js +51 -0
- package/lib/commands/navigation.js +125 -0
- package/lib/commands/notifications.js +66 -0
- package/lib/commands/pasteboard.js +42 -0
- package/lib/commands/pcap.js +168 -0
- package/lib/commands/performance.js +392 -0
- package/lib/commands/permissions.js +85 -0
- package/lib/commands/proxy-helper.js +122 -0
- package/lib/commands/record-audio.js +264 -0
- package/lib/commands/recordscreen.js +391 -0
- package/lib/commands/screenshots.js +137 -0
- package/lib/commands/simctl.js +71 -0
- package/lib/commands/source.js +131 -0
- package/lib/commands/timeouts.js +68 -0
- package/lib/commands/types.ts +648 -0
- package/lib/commands/web.js +1113 -0
- package/lib/commands/xctest-record-screen.js +204 -0
- package/lib/commands/xctest.js +285 -0
- package/lib/css-converter.js +311 -0
- package/lib/desired-caps.js +396 -0
- package/lib/device-connections-factory.js +269 -0
- package/lib/device-log/helpers.ts +40 -0
- package/lib/device-log/ios-crash-log.ts +166 -0
- package/lib/device-log/ios-device-log.ts +51 -0
- package/lib/device-log/ios-log.ts +70 -0
- package/lib/device-log/ios-performance-log.ts +50 -0
- package/lib/device-log/ios-simulator-log.ts +202 -0
- package/lib/device-log/line-consuming-log.ts +16 -0
- package/lib/device-log/safari-console-log.ts +117 -0
- package/lib/device-log/safari-network-log.ts +120 -0
- package/lib/doctor/checks.ts +3 -0
- package/lib/doctor/optional-checks.ts +173 -0
- package/lib/doctor/required-checks.ts +120 -0
- package/lib/doctor/utils.ts +18 -0
- package/lib/driver.js +2316 -0
- package/lib/execute-method-map.ts +585 -0
- package/lib/ios-fs-helpers.js +355 -0
- package/lib/ios-generic-simulators.js +11 -0
- package/lib/logger.js +5 -0
- package/lib/method-map.js +196 -0
- package/lib/real-device-clients/base-device-client.ts +34 -0
- package/lib/real-device-clients/py-ios-device-client.ts +149 -0
- package/lib/real-device-management.js +133 -0
- package/lib/real-device.js +347 -0
- package/lib/simulator-management.js +324 -0
- package/lib/stubs.ts +3 -0
- package/lib/types.ts +33 -0
- package/lib/utils.js +551 -0
- package/lib/xcrun.js +16 -0
- package/package.json +175 -0
- package/scripts/build-docs.js +56 -0
- package/scripts/build-wda.js +42 -0
- package/scripts/download-wda-sim.mjs +68 -0
- package/scripts/image-mounter.mjs +239 -0
- package/scripts/open-wda.mjs +15 -0
- package/scripts/tunnel-creation.mjs +359 -0
- package/scripts/utils.js +16 -0
|
@@ -0,0 +1,477 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.parseContainerPath = parseContainerPath;
|
|
7
|
+
exports.pushFile = pushFile;
|
|
8
|
+
exports.mobilePushFile = mobilePushFile;
|
|
9
|
+
exports.pullFile = pullFile;
|
|
10
|
+
exports.mobilePullFile = mobilePullFile;
|
|
11
|
+
exports.mobileDeleteFolder = mobileDeleteFolder;
|
|
12
|
+
exports.mobileDeleteFile = mobileDeleteFile;
|
|
13
|
+
exports.pullFolder = pullFolder;
|
|
14
|
+
exports.mobilePullFolder = mobilePullFolder;
|
|
15
|
+
const lodash_1 = __importDefault(require("lodash"));
|
|
16
|
+
const support_1 = require("appium/support");
|
|
17
|
+
const path_1 = __importDefault(require("path"));
|
|
18
|
+
const appium_ios_device_1 = require("appium-ios-device");
|
|
19
|
+
const ios_fs_helpers_1 = require("../ios-fs-helpers");
|
|
20
|
+
const driver_1 = require("appium/driver");
|
|
21
|
+
const CONTAINER_PATH_MARKER = '@';
|
|
22
|
+
// https://regex101.com/r/PLdB0G/2
|
|
23
|
+
const CONTAINER_PATH_PATTERN = new RegExp(`^${CONTAINER_PATH_MARKER}([^/]+)/(.*)`);
|
|
24
|
+
const CONTAINER_TYPE_SEPARATOR = ':';
|
|
25
|
+
const CONTAINER_DOCUMENTS_PATH = 'Documents';
|
|
26
|
+
const OBJECT_NOT_FOUND_ERROR_MESSAGE = 'OBJECT_NOT_FOUND';
|
|
27
|
+
/**
|
|
28
|
+
* Parses the actual path and the bundle identifier from the given path string
|
|
29
|
+
*
|
|
30
|
+
* @this {XCUITestDriver}
|
|
31
|
+
* @param {string} remotePath - The given path string. The string should
|
|
32
|
+
* match `CONTAINER_PATH_PATTERN` regexp, otherwise an error is going
|
|
33
|
+
* to be thrown. A valid string example: `@bundle.identifier:container_type/relative_path_in_container`
|
|
34
|
+
* @param {import('./types').ContainerRootSupplier|string} [containerRootSupplier] - Container root path supplier function or string value
|
|
35
|
+
* @returns {Promise<import('./types').ContainerObject>}
|
|
36
|
+
*/
|
|
37
|
+
async function parseContainerPath(remotePath, containerRootSupplier) {
|
|
38
|
+
const match = CONTAINER_PATH_PATTERN.exec(remotePath);
|
|
39
|
+
if (!match) {
|
|
40
|
+
throw new Error(`It is expected that package identifier ` +
|
|
41
|
+
`starts with '${CONTAINER_PATH_MARKER}' and is separated from the ` +
|
|
42
|
+
`relative path with a single slash. '${remotePath}' is given instead`);
|
|
43
|
+
}
|
|
44
|
+
let [, bundleId, relativePath] = match;
|
|
45
|
+
let containerType = null;
|
|
46
|
+
const typeSeparatorPos = bundleId.indexOf(CONTAINER_TYPE_SEPARATOR);
|
|
47
|
+
// We only consider container type exists if its length is greater than zero
|
|
48
|
+
// not counting the colon
|
|
49
|
+
if (typeSeparatorPos > 0 && typeSeparatorPos < bundleId.length - 1) {
|
|
50
|
+
containerType = bundleId.substring(typeSeparatorPos + 1);
|
|
51
|
+
this.log.debug(`Parsed container type: ${containerType}`);
|
|
52
|
+
bundleId = bundleId.substring(0, typeSeparatorPos);
|
|
53
|
+
}
|
|
54
|
+
if (lodash_1.default.isNil(containerRootSupplier)) {
|
|
55
|
+
const pathInContainer = relativePath;
|
|
56
|
+
return { bundleId, pathInContainer, containerType };
|
|
57
|
+
}
|
|
58
|
+
const containerRoot = lodash_1.default.isFunction(containerRootSupplier)
|
|
59
|
+
? await containerRootSupplier(bundleId, containerType)
|
|
60
|
+
: containerRootSupplier;
|
|
61
|
+
const pathInContainer = path_1.default.posix.resolve(containerRoot, relativePath);
|
|
62
|
+
verifyIsSubPath(pathInContainer, containerRoot);
|
|
63
|
+
return { bundleId, pathInContainer, containerType };
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
*
|
|
67
|
+
* @param {string} originalPath
|
|
68
|
+
* @param {string} root
|
|
69
|
+
* @returns {void}
|
|
70
|
+
*/
|
|
71
|
+
function verifyIsSubPath(originalPath, root) {
|
|
72
|
+
const normalizedRoot = path_1.default.normalize(root);
|
|
73
|
+
const normalizedPath = path_1.default.normalize(path_1.default.dirname(originalPath));
|
|
74
|
+
// If originalPath is root, `/`, originalPath should equal to normalizedRoot
|
|
75
|
+
if (normalizedRoot !== originalPath && !normalizedPath.startsWith(normalizedRoot)) {
|
|
76
|
+
throw new Error(`'${normalizedPath}' is expected to be a subpath of '${normalizedRoot}'`);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
*
|
|
81
|
+
* @this {XCUITestDriver}
|
|
82
|
+
* @param {string} [bundleId]
|
|
83
|
+
* @param {string} [containerType]
|
|
84
|
+
* @returns {Promise<any>}
|
|
85
|
+
*/
|
|
86
|
+
async function createAfcClient(bundleId, containerType) {
|
|
87
|
+
const udid = this.device.udid;
|
|
88
|
+
if (!bundleId) {
|
|
89
|
+
return await appium_ios_device_1.services.startAfcService(udid);
|
|
90
|
+
}
|
|
91
|
+
const service = await appium_ios_device_1.services.startHouseArrestService(udid);
|
|
92
|
+
const { skipDocumentsContainerCheck = false, } = await this.settings.getSettings();
|
|
93
|
+
if (skipDocumentsContainerCheck) {
|
|
94
|
+
return service.vendContainer(bundleId);
|
|
95
|
+
}
|
|
96
|
+
return isDocumentsContainer(containerType)
|
|
97
|
+
? await service.vendDocuments(bundleId)
|
|
98
|
+
: await service.vendContainer(bundleId);
|
|
99
|
+
}
|
|
100
|
+
/**
|
|
101
|
+
*
|
|
102
|
+
* @param {string} [containerType]
|
|
103
|
+
* @returns {boolean}
|
|
104
|
+
*/
|
|
105
|
+
function isDocumentsContainer(containerType) {
|
|
106
|
+
return lodash_1.default.toLower(containerType) === lodash_1.default.toLower(CONTAINER_DOCUMENTS_PATH);
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
*
|
|
110
|
+
* @this {XCUITestDriver}
|
|
111
|
+
* @param {string} remotePath
|
|
112
|
+
* @returns {Promise<{service: any, relativePath: string}>}
|
|
113
|
+
*/
|
|
114
|
+
async function createService(remotePath) {
|
|
115
|
+
if (CONTAINER_PATH_PATTERN.test(remotePath)) {
|
|
116
|
+
const { bundleId, pathInContainer, containerType } = await parseContainerPath.bind(this)(remotePath);
|
|
117
|
+
const service = await createAfcClient.bind(this)(bundleId, containerType);
|
|
118
|
+
const relativePath = isDocumentsContainer(containerType)
|
|
119
|
+
? path_1.default.join(CONTAINER_DOCUMENTS_PATH, pathInContainer)
|
|
120
|
+
: pathInContainer;
|
|
121
|
+
return { service, relativePath };
|
|
122
|
+
}
|
|
123
|
+
else {
|
|
124
|
+
const service = await createAfcClient.bind(this)();
|
|
125
|
+
return { service, relativePath: remotePath };
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Save the given base64 data chunk as a binary file on the Simulator under test.
|
|
130
|
+
*
|
|
131
|
+
* @this {XCUITestDriver}
|
|
132
|
+
* @param {string} remotePath - The remote path on the device. This variable can be prefixed with
|
|
133
|
+
* bundle id, so then the file will be uploaded to the corresponding
|
|
134
|
+
* application container instead of the default media folder, for example
|
|
135
|
+
* '@com.myapp.bla:data/RelativePathInContainer/111.png'. The '@' character at the
|
|
136
|
+
* beginning of the argument is mandatory in such case. The colon at the end of bundle identifier
|
|
137
|
+
* is optional and is used to distinguish the container type.
|
|
138
|
+
* Possible values there are 'app', 'data', 'groups', '<A specific App Group container>'.
|
|
139
|
+
* The default value is 'app'.
|
|
140
|
+
* The relative folder path is ignored if the file is going to be uploaded
|
|
141
|
+
* to the default media folder and only the file name is considered important.
|
|
142
|
+
* @param {string} base64Data - Base-64 encoded content of the file to be uploaded.
|
|
143
|
+
*/
|
|
144
|
+
async function pushFileToSimulator(remotePath, base64Data) {
|
|
145
|
+
const buffer = Buffer.from(base64Data, 'base64');
|
|
146
|
+
const device = /** @type {import('../driver').Simulator} */ (this.device);
|
|
147
|
+
if (CONTAINER_PATH_PATTERN.test(remotePath)) {
|
|
148
|
+
const { bundleId, pathInContainer: dstPath } = await parseContainerPath.bind(this)(remotePath, async (appBundle, containerType) => await device.simctl.getAppContainer(appBundle, containerType));
|
|
149
|
+
this.log.info(`Parsed bundle identifier '${bundleId}' from '${remotePath}'. ` +
|
|
150
|
+
`Will put the data into '${dstPath}'`);
|
|
151
|
+
if (!(await support_1.fs.exists(path_1.default.dirname(dstPath)))) {
|
|
152
|
+
this.log.debug(`The destination folder '${path_1.default.dirname(dstPath)}' does not exist. Creating...`);
|
|
153
|
+
await (0, support_1.mkdirp)(path_1.default.dirname(dstPath));
|
|
154
|
+
}
|
|
155
|
+
await support_1.fs.writeFile(dstPath, buffer);
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
158
|
+
const dstFolder = await support_1.tempDir.openDir();
|
|
159
|
+
const dstPath = path_1.default.resolve(dstFolder, path_1.default.basename(remotePath));
|
|
160
|
+
try {
|
|
161
|
+
await support_1.fs.writeFile(dstPath, buffer);
|
|
162
|
+
await device.simctl.addMedia(dstPath);
|
|
163
|
+
}
|
|
164
|
+
finally {
|
|
165
|
+
await support_1.fs.rimraf(dstFolder);
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Save the given base64 data chunk as a binary file on the device under test.
|
|
170
|
+
*
|
|
171
|
+
* @this {XCUITestDriver}
|
|
172
|
+
* @param {string} remotePath - The remote path on the device. This variable can be prefixed with
|
|
173
|
+
* bundle id, so then the file will be uploaded to the corresponding
|
|
174
|
+
* application container instead of the default media folder. Use
|
|
175
|
+
* `@<app_bundle_id>:<optional_container_type>/<path_to_the_file_or_folder_inside_container>`
|
|
176
|
+
* format to pull a file or a folder from an application container of the given type.
|
|
177
|
+
* The only supported container type is 'documents'. If the container type is not set
|
|
178
|
+
* explicitly for a bundle id, then the default application container is going to be mounted
|
|
179
|
+
* (aka --container ifuse argument)
|
|
180
|
+
* e.g. If `@com.myapp.bla:documents/111.png` is provided,
|
|
181
|
+
* `On My iPhone/<app name>` in Files app will be mounted in the host machine.
|
|
182
|
+
* Base64 encoded `111.png` will be pushed into `On My iPhone/<app name>/111.png`
|
|
183
|
+
* as base64 decoded data.
|
|
184
|
+
* @param {string} base64Data - Base-64 encoded content of the file to be uploaded.
|
|
185
|
+
*/
|
|
186
|
+
async function pushFileToRealDevice(remotePath, base64Data) {
|
|
187
|
+
const { service, relativePath } = await createService.bind(this)(remotePath);
|
|
188
|
+
try {
|
|
189
|
+
await (0, ios_fs_helpers_1.pushFile)(service, Buffer.from(base64Data, 'base64'), relativePath);
|
|
190
|
+
}
|
|
191
|
+
catch (e) {
|
|
192
|
+
this.log.debug(e.stack);
|
|
193
|
+
throw new Error(`Could not push the file to '${remotePath}'. Original error: ${e.message}`);
|
|
194
|
+
}
|
|
195
|
+
finally {
|
|
196
|
+
service.close();
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
/**
|
|
200
|
+
*
|
|
201
|
+
* @this {XCUITestDriver}
|
|
202
|
+
* @param {string} remotePath
|
|
203
|
+
* @returns {Promise<void>}
|
|
204
|
+
*/
|
|
205
|
+
async function deleteFileOrFolder(remotePath) {
|
|
206
|
+
return this.isSimulator()
|
|
207
|
+
? await deleteFromSimulator.bind(this)(remotePath)
|
|
208
|
+
: await deleteFromRealDevice.bind(this)(remotePath);
|
|
209
|
+
}
|
|
210
|
+
/**
|
|
211
|
+
* Get the content of given file or folder from iOS Simulator and return it as base-64 encoded string.
|
|
212
|
+
* Folder content is recursively packed into a zip archive.
|
|
213
|
+
*
|
|
214
|
+
* @this {XCUITestDriver}
|
|
215
|
+
* @param {string} remotePath - The path to a file or a folder, which exists in the corresponding application
|
|
216
|
+
* container on Simulator. Use
|
|
217
|
+
* `@<app_bundle_id>:<optional_container_type>/<path_to_the_file_or_folder_inside_container>`
|
|
218
|
+
* format to pull a file or a folder from an application container of the given type.
|
|
219
|
+
* Possible container types are `app`, `data`, `groups`, `<A specific App Group container>`.
|
|
220
|
+
* The default type is `app`.
|
|
221
|
+
* @param {boolean} isFile - Whether the destination item is a file or a folder
|
|
222
|
+
* @returns {Promise<string>} Base-64 encoded content of the file.
|
|
223
|
+
*/
|
|
224
|
+
async function pullFromSimulator(remotePath, isFile) {
|
|
225
|
+
let pathOnServer;
|
|
226
|
+
const device = /** @type {import('../driver').Simulator} */ (this.device);
|
|
227
|
+
if (CONTAINER_PATH_PATTERN.test(remotePath)) {
|
|
228
|
+
const { bundleId, pathInContainer: dstPath } = await parseContainerPath.bind(this)(remotePath, async (appBundle, containerType) => await device.simctl.getAppContainer(appBundle, containerType));
|
|
229
|
+
this.log.info(`Parsed bundle identifier '${bundleId}' from '${remotePath}'. ` +
|
|
230
|
+
`Will get the data from '${dstPath}'`);
|
|
231
|
+
pathOnServer = dstPath;
|
|
232
|
+
}
|
|
233
|
+
else {
|
|
234
|
+
const simRoot = device.getDir();
|
|
235
|
+
pathOnServer = path_1.default.posix.join(simRoot, remotePath);
|
|
236
|
+
verifyIsSubPath(pathOnServer, simRoot);
|
|
237
|
+
this.log.info(`Got the full item path: ${pathOnServer}`);
|
|
238
|
+
}
|
|
239
|
+
if (!(await support_1.fs.exists(pathOnServer))) {
|
|
240
|
+
throw this.log.errorWithException(`The remote ${isFile ? 'file' : 'folder'} at '${pathOnServer}' does not exist`);
|
|
241
|
+
}
|
|
242
|
+
const buffer = isFile
|
|
243
|
+
? await support_1.util.toInMemoryBase64(pathOnServer)
|
|
244
|
+
: await support_1.zip.toInMemoryZip(pathOnServer, { encodeToBase64: true });
|
|
245
|
+
return buffer.toString();
|
|
246
|
+
}
|
|
247
|
+
/**
|
|
248
|
+
* Get the content of given file or folder from the real device under test and return it as base-64 encoded string.
|
|
249
|
+
* Folder content is recursively packed into a zip archive.
|
|
250
|
+
*
|
|
251
|
+
* @this {XCUITestDriver}
|
|
252
|
+
* @param {string} remotePath - The path to an existing remote file on the device. This variable can be prefixed with
|
|
253
|
+
* bundle id, so then the file will be downloaded from the corresponding
|
|
254
|
+
* application container instead of the default media folder. Use
|
|
255
|
+
* `@<app_bundle_id>:<optional_container_type>/<path_to_the_file_or_folder_inside_container>`
|
|
256
|
+
* format to pull a file or a folder from an application container of the given type.
|
|
257
|
+
* The only supported container type is 'documents'. If the container type is not set
|
|
258
|
+
* explicitly for a bundle id, then the default application container is going to be mounted
|
|
259
|
+
* (aka --container ifuse argument)
|
|
260
|
+
* e.g. If `@com.myapp.bla:documents/111.png` is provided,
|
|
261
|
+
* `On My iPhone/<app name>` in Files app will be mounted in the host machine.
|
|
262
|
+
* `On My iPhone/<app name>/111.png` will be pulled into the mounted host machine
|
|
263
|
+
* and Appium returns the data as base64-encoded string to client.
|
|
264
|
+
* `@com.myapp.bla:documents/` means `On My iPhone/<app name>`.
|
|
265
|
+
* @param {boolean} isFile - Whether the destination item is a file or a folder
|
|
266
|
+
* @returns {Promise<string>} Base-64 encoded content of the remote file
|
|
267
|
+
*/
|
|
268
|
+
async function pullFromRealDevice(remotePath, isFile) {
|
|
269
|
+
const { service, relativePath } = await createService.bind(this)(remotePath);
|
|
270
|
+
try {
|
|
271
|
+
const fileInfo = await service.getFileInfo(relativePath);
|
|
272
|
+
if (isFile && fileInfo.isDirectory()) {
|
|
273
|
+
throw new Error(`The requested path is not a file. Path: '${remotePath}'`);
|
|
274
|
+
}
|
|
275
|
+
if (!isFile && !fileInfo.isDirectory()) {
|
|
276
|
+
throw new Error(`The requested path is not a folder. Path: '${remotePath}'`);
|
|
277
|
+
}
|
|
278
|
+
return fileInfo.isFile()
|
|
279
|
+
? (await (0, ios_fs_helpers_1.pullFile)(service, relativePath)).toString('base64')
|
|
280
|
+
: (await (0, ios_fs_helpers_1.pullFolder)(service, relativePath)).toString();
|
|
281
|
+
}
|
|
282
|
+
finally {
|
|
283
|
+
service.close();
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
/**
|
|
287
|
+
* Remove the file or folder from the device
|
|
288
|
+
*
|
|
289
|
+
* @this {XCUITestDriver}
|
|
290
|
+
* @param {string} remotePath - The path to a file or a folder, which exists in the corresponding application
|
|
291
|
+
* container on Simulator. Use
|
|
292
|
+
* `@<app_bundle_id>:<optional_container_type>/<path_to_the_file_or_folder_inside_container>`
|
|
293
|
+
* format to pull a file or a folder from an application container of the given type.
|
|
294
|
+
* Possible container types are 'app', 'data', 'groups', '<A specific App Group container>'.
|
|
295
|
+
* The default type is 'app'.
|
|
296
|
+
* @returns {Promise<void>}
|
|
297
|
+
*/
|
|
298
|
+
async function deleteFromSimulator(remotePath) {
|
|
299
|
+
let pathOnServer;
|
|
300
|
+
const device = /** @type {import('../driver').Simulator} */ (this.device);
|
|
301
|
+
if (CONTAINER_PATH_PATTERN.test(remotePath)) {
|
|
302
|
+
const { bundleId, pathInContainer: dstPath } = await parseContainerPath.bind(this)(remotePath, async (appBundle, containerType) => await device.simctl.getAppContainer(appBundle, containerType));
|
|
303
|
+
this.log.info(`Parsed bundle identifier '${bundleId}' from '${remotePath}'. ` +
|
|
304
|
+
`'${dstPath}' will be deleted`);
|
|
305
|
+
pathOnServer = dstPath;
|
|
306
|
+
}
|
|
307
|
+
else {
|
|
308
|
+
const simRoot = device.getDir();
|
|
309
|
+
pathOnServer = path_1.default.posix.join(simRoot, remotePath);
|
|
310
|
+
verifyIsSubPath(pathOnServer, simRoot);
|
|
311
|
+
this.log.info(`Got the full path: ${pathOnServer}`);
|
|
312
|
+
}
|
|
313
|
+
if (!(await support_1.fs.exists(pathOnServer))) {
|
|
314
|
+
throw new driver_1.errors.InvalidArgumentError(`The remote path at '${pathOnServer}' does not exist`);
|
|
315
|
+
}
|
|
316
|
+
await support_1.fs.rimraf(pathOnServer);
|
|
317
|
+
}
|
|
318
|
+
/**
|
|
319
|
+
* Remove the file or folder from the device
|
|
320
|
+
*
|
|
321
|
+
* @this {XCUITestDriver}
|
|
322
|
+
* @param {string} remotePath - The path to an existing remote file on the device. This variable can be prefixed with
|
|
323
|
+
* bundle id, so then the file will be downloaded from the corresponding
|
|
324
|
+
* application container instead of the default media folder. Use
|
|
325
|
+
* `@<app_bundle_id>:<optional_container_type>/<path_to_the_file_or_folder_inside_container>`
|
|
326
|
+
* format to pull a file or a folder from an application container of the given type.
|
|
327
|
+
* The only supported container type is 'documents'. If the container type is not set
|
|
328
|
+
* explicitly for a bundle id, then the default application container is going to be mounted
|
|
329
|
+
* (aka --container ifuse argument)
|
|
330
|
+
* e.g. If `@com.myapp.bla:documents/111.png` is provided,
|
|
331
|
+
* `On My iPhone/<app name>` in Files app will be mounted in the host machine.
|
|
332
|
+
* `On My iPhone/<app name>/111.png` will be pulled into the mounted host machine
|
|
333
|
+
* and Appium returns the data as base64-encoded string to client.
|
|
334
|
+
* `@com.myapp.bla:documents/` means `On My iPhone/<app name>`.
|
|
335
|
+
* @returns {Promise<void>}
|
|
336
|
+
*/
|
|
337
|
+
async function deleteFromRealDevice(remotePath) {
|
|
338
|
+
const { service, relativePath } = await createService.bind(this)(remotePath);
|
|
339
|
+
try {
|
|
340
|
+
await service.deleteDirectory(relativePath);
|
|
341
|
+
}
|
|
342
|
+
catch (e) {
|
|
343
|
+
if (e.message.includes(OBJECT_NOT_FOUND_ERROR_MESSAGE)) {
|
|
344
|
+
throw new Error(`Path '${remotePath}' does not exist on the device`);
|
|
345
|
+
}
|
|
346
|
+
throw e;
|
|
347
|
+
}
|
|
348
|
+
finally {
|
|
349
|
+
service.close();
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
/**
|
|
353
|
+
* Pushes the given data to a file on the remote device
|
|
354
|
+
*
|
|
355
|
+
* @param {string} remotePath The full path to the remote file or
|
|
356
|
+
* a file inside a package bundle. Check the documentation on
|
|
357
|
+
* `pushFileToRealDevice` and `pushFileToSimulator` for more information
|
|
358
|
+
* on acceptable values.
|
|
359
|
+
* @param {string} base64Data Base64 encoded data to be written to the
|
|
360
|
+
* remote file. The remote file will be silently overridden if it already exists.
|
|
361
|
+
* @throws {Error} If there was an error while pushing the data
|
|
362
|
+
* @this {XCUITestDriver}
|
|
363
|
+
*/
|
|
364
|
+
async function pushFile(remotePath, base64Data) {
|
|
365
|
+
if (remotePath.endsWith('/')) {
|
|
366
|
+
throw new driver_1.errors.InvalidArgumentError(`It is expected that remote path points to a file and not to a folder. ` +
|
|
367
|
+
`'${remotePath}' is given instead`);
|
|
368
|
+
}
|
|
369
|
+
if (lodash_1.default.isArray(base64Data)) {
|
|
370
|
+
// some clients (ahem) java, send a byte array encoding utf8 characters
|
|
371
|
+
// instead of a string, which would be infinitely better!
|
|
372
|
+
base64Data = Buffer.from(base64Data).toString('utf8');
|
|
373
|
+
}
|
|
374
|
+
return this.isSimulator()
|
|
375
|
+
? await pushFileToSimulator.bind(this)(remotePath, base64Data)
|
|
376
|
+
: await pushFileToRealDevice.bind(this)(remotePath, base64Data);
|
|
377
|
+
}
|
|
378
|
+
/**
|
|
379
|
+
* Pushes the given data to a file on the remote device.
|
|
380
|
+
*
|
|
381
|
+
* @param {string} remotePath - The full path to the remote file
|
|
382
|
+
* or a specially formatted path, which points to an item inside an app bundle.
|
|
383
|
+
* @param {string} payload - Base64-encoded content of the file to be pushed.
|
|
384
|
+
* @this {XCUITestDriver}
|
|
385
|
+
*/
|
|
386
|
+
async function mobilePushFile(remotePath, payload) {
|
|
387
|
+
return await this.pushFile(remotePath, payload);
|
|
388
|
+
}
|
|
389
|
+
/**
|
|
390
|
+
* Pulls a remote file from the device.
|
|
391
|
+
*
|
|
392
|
+
* @param {string} remotePath The full path to the remote file
|
|
393
|
+
* or a specially formatted path, which points to an item inside app bundle.
|
|
394
|
+
* See the documentation for `pullFromRealDevice` and `pullFromSimulator`
|
|
395
|
+
* to get more information on acceptable values.
|
|
396
|
+
* @returns {Promise<string>} Base64 encoded content of the pulled file
|
|
397
|
+
* @throws {Error} If the pull operation failed
|
|
398
|
+
* @this {XCUITestDriver}
|
|
399
|
+
*/
|
|
400
|
+
async function pullFile(remotePath) {
|
|
401
|
+
if (remotePath.endsWith('/')) {
|
|
402
|
+
throw new driver_1.errors.InvalidArgumentError(`It is expected that remote path points to a file and not to a folder. ` +
|
|
403
|
+
`'${remotePath}' is given instead`);
|
|
404
|
+
}
|
|
405
|
+
return this.isSimulator()
|
|
406
|
+
? await pullFromSimulator.bind(this)(remotePath, true)
|
|
407
|
+
: await pullFromRealDevice.bind(this)(remotePath, true);
|
|
408
|
+
}
|
|
409
|
+
/**
|
|
410
|
+
* Pulls a remote file from the device.
|
|
411
|
+
*
|
|
412
|
+
* @param {string} remotePath - The full path to the remote file
|
|
413
|
+
* or a specially formatted path, which points to an item inside app bundle. See the documentation for `pullFromRealDevice` and `pullFromSimulator` to get more information on acceptable values.
|
|
414
|
+
* @returns {Promise<string>} The same as in `pullFile`
|
|
415
|
+
* @this {XCUITestDriver}
|
|
416
|
+
*/
|
|
417
|
+
async function mobilePullFile(remotePath) {
|
|
418
|
+
return await this.pullFile(remotePath);
|
|
419
|
+
}
|
|
420
|
+
/**
|
|
421
|
+
* Delete a remote folder from the device.
|
|
422
|
+
*
|
|
423
|
+
* @param {string} remotePath - The full path to the remote folder or a specially formatted path, which points to an item inside app bundle. See the documentation for `pullFromRealDevice` and `pullFromSimulator` to get more information on acceptable values.
|
|
424
|
+
* @this {XCUITestDriver}
|
|
425
|
+
* @returns {Promise<void>}
|
|
426
|
+
*/
|
|
427
|
+
async function mobileDeleteFolder(remotePath) {
|
|
428
|
+
if (!remotePath.endsWith('/')) {
|
|
429
|
+
remotePath = `${remotePath}/`;
|
|
430
|
+
}
|
|
431
|
+
await deleteFileOrFolder.bind(this)(remotePath);
|
|
432
|
+
}
|
|
433
|
+
/**
|
|
434
|
+
* Delete a remote file from the device.
|
|
435
|
+
*
|
|
436
|
+
* @param {string} remotePath - The full path to the remote file or a specially formatted path, which points to an item inside app bundle. See the documentation for `pullFromRealDevice` and `pullFromSimulator` to get more information on acceptable values.
|
|
437
|
+
* @this {XCUITestDriver}
|
|
438
|
+
* @returns {Promise<void>}
|
|
439
|
+
*/
|
|
440
|
+
async function mobileDeleteFile(remotePath) {
|
|
441
|
+
if (remotePath.endsWith('/')) {
|
|
442
|
+
throw new driver_1.errors.InvalidArgumentError(`It is expected that remote path points to a file and not to a folder. ` +
|
|
443
|
+
`'${remotePath}' is given instead`);
|
|
444
|
+
}
|
|
445
|
+
await deleteFileOrFolder.bind(this)(remotePath);
|
|
446
|
+
}
|
|
447
|
+
/**
|
|
448
|
+
* Pulls the whole folder from the remote device
|
|
449
|
+
*
|
|
450
|
+
* @param {string} remotePath The full path to a folder on the
|
|
451
|
+
* remote device or a folder inside an application bundle
|
|
452
|
+
* @returns {Promise<string>} Zipped and base64-encoded content of the folder
|
|
453
|
+
* @throws {Error} If there was a failure while getting the folder content
|
|
454
|
+
* @this {XCUITestDriver}
|
|
455
|
+
*/
|
|
456
|
+
async function pullFolder(remotePath) {
|
|
457
|
+
if (!remotePath.endsWith('/')) {
|
|
458
|
+
remotePath = `${remotePath}/`;
|
|
459
|
+
}
|
|
460
|
+
return this.isSimulator()
|
|
461
|
+
? await pullFromSimulator.bind(this)(remotePath, false)
|
|
462
|
+
: await pullFromRealDevice.bind(this)(remotePath, false);
|
|
463
|
+
}
|
|
464
|
+
/**
|
|
465
|
+
* Pulls the whole folder from the device under test.
|
|
466
|
+
*
|
|
467
|
+
* @param {string} remotePath - The full path to the remote folder
|
|
468
|
+
* @returns {Promise<string>} The same as `pullFolder`
|
|
469
|
+
* @this {XCUITestDriver}
|
|
470
|
+
*/
|
|
471
|
+
async function mobilePullFolder(remotePath) {
|
|
472
|
+
return await this.pullFolder(remotePath);
|
|
473
|
+
}
|
|
474
|
+
/**
|
|
475
|
+
* @typedef {import('../driver').XCUITestDriver} XCUITestDriver
|
|
476
|
+
*/
|
|
477
|
+
//# sourceMappingURL=file-movement.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"file-movement.js","sourceRoot":"","sources":["../../../lib/commands/file-movement.js"],"names":[],"mappings":";;;;;AAwBA,gDA6BC;AA0UD,4BAeC;AAUD,wCAEC;AAaD,4BAUC;AAUD,wCAEC;AASD,gDAKC;AASD,4CAQC;AAWD,gCAOC;AASD,4CAEC;AAzfD,oDAAuB;AACvB,4CAA8D;AAC9D,gDAAwB;AACxB,yDAA2C;AAC3C,sDAAgH;AAChH,0CAAqC;AAErC,MAAM,qBAAqB,GAAG,GAAG,CAAC;AAClC,kCAAkC;AAClC,MAAM,sBAAsB,GAAG,IAAI,MAAM,CAAC,IAAI,qBAAqB,cAAc,CAAC,CAAC;AACnF,MAAM,wBAAwB,GAAG,GAAG,CAAC;AACrC,MAAM,wBAAwB,GAAG,WAAW,CAAC;AAC7C,MAAM,8BAA8B,GAAG,kBAAkB,CAAC;AAE1D;;;;;;;;;GASG;AACI,KAAK,UAAU,kBAAkB,CAAC,UAAU,EAAE,qBAAqB;IACxE,MAAM,KAAK,GAAG,sBAAsB,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IACtD,IAAI,CAAC,KAAK,EAAE,CAAC;QACX,MAAM,IAAI,KAAK,CACb,yCAAyC;YACvC,gBAA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GAAG,CAAC,EAAE,CAAC;QAC9B,UAAU,GAAG,GAAG,UAAU,GAAG,CAAC;IAChC,CAAC;IACD,MAAM,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,UAAU,CAAC,CAAC;AAClD,CAAC;AAED;;;;;;GAMG;AACI,KAAK,UAAU,gBAAgB,CAAC,UAAU;IAC/C,IAAI,UAAU,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC7B,MAAM,IAAI,eAAM,CAAC,oBAAoB,CACnC,wEAAwE;YACtE,IAAI,UAAU,oBAAoB,CACrC,CAAC;IACJ,CAAC;IACD,MAAM,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,UAAU,CAAC,CAAC;AAClD,CAAC;AAED;;;;;;;;GAQG;AACI,KAAK,UAAU,UAAU,CAAC,UAAU;IACzC,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC9B,UAAU,GAAG,GAAG,UAAU,GAAG,CAAC;IAChC,CAAC;IACD,OAAO,IAAI,CAAC,WAAW,EAAE;QACvB,CAAC,CAAC,MAAM,iBAAiB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,KAAK,CAAC;QACvD,CAAC,CAAC,MAAM,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,KAAK,CAAC,CAAC;AAC7D,CAAC;AAED;;;;;;GAMG;AACI,KAAK,UAAU,gBAAgB,CAAC,UAAU;IAC/C,OAAO,MAAM,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC;AAC3C,CAAC;AAED;;GAEG"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @this {XCUITestDriver}
|
|
3
|
+
*/
|
|
4
|
+
export function findElOrEls(this: import("../driver").XCUITestDriver, strategy: any, selector: any, mult: any, context: any): Promise<any>;
|
|
5
|
+
/**
|
|
6
|
+
* @this {XCUITestDriver}
|
|
7
|
+
* @privateRemarks I'm not sure what these objects are; they aren't `Element`.
|
|
8
|
+
* @returns {Promise<any|any[]|undefined>}
|
|
9
|
+
*/
|
|
10
|
+
export function findNativeElementOrElements(this: import("../driver").XCUITestDriver, strategy: any, selector: any, mult: any, context: any): Promise<any | any[] | undefined>;
|
|
11
|
+
/**
|
|
12
|
+
* @this {XCUITestDriver}
|
|
13
|
+
*/
|
|
14
|
+
export function doNativeFind(this: import("../driver").XCUITestDriver, strategy: any, selector: any, mult: any, context: any): Promise<import("@appium/types").Element<string>[] | undefined>;
|
|
15
|
+
/**
|
|
16
|
+
* @this {XCUITestDriver}
|
|
17
|
+
*/
|
|
18
|
+
export function getFirstVisibleChild(this: import("../driver").XCUITestDriver, mult: any, context: any): Promise<import("@appium/types").Element<string>[] | undefined>;
|
|
19
|
+
export type XCUITestDriver = import("../driver").XCUITestDriver;
|
|
20
|
+
export type Element = import("@appium/types").Element;
|
|
21
|
+
//# sourceMappingURL=find.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"find.d.ts","sourceRoot":"","sources":["../../../lib/commands/find.js"],"names":[],"mappings":"AAKA;;GAEG;AACH,2IAMC;AAED;;;;GAIG;AACH,8IAFa,OAAO,CAAC,GAAG,GAAC,GAAG,EAAE,GAAC,SAAS,CAAC,CAkDxC;AAED;;GAEG;AACH,8LA4CC;AAED;;GAEG;AACH,wKA0BC;6BAqDY,OAAO,WAAW,EAAE,cAAc;sBAClC,OAAO,eAAe,EAAE,OAAO"}
|