appium-mcp 0.0.1 → 1.1.4
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/.github/workflows/ci.yml +37 -0
- package/.github/workflows/pr-title.yml +15 -0
- package/.github/workflows/publish.yml +31 -0
- package/.gitmodules +9 -0
- package/.prettierignore +29 -0
- package/.prettierrc +10 -0
- package/.releaserc +37 -0
- package/CHANGELOG.md +37 -0
- package/LICENSE +21 -0
- package/README.md +153 -0
- package/dist/devicemanager/adb-manager.d.ts +71 -0
- package/dist/devicemanager/adb-manager.js +140 -0
- package/dist/devicemanager/adb-manager.js.map +1 -0
- package/dist/devicemanager/ios-manager.d.ts +58 -0
- package/dist/devicemanager/ios-manager.js +122 -0
- package/dist/devicemanager/ios-manager.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +40 -0
- package/dist/index.js.map +1 -0
- package/dist/locators/element-filter.d.ts +13 -0
- package/dist/locators/element-filter.js +79 -0
- package/dist/locators/element-filter.js.map +1 -0
- package/dist/locators/generate-all-locators.d.ts +21 -0
- package/dist/locators/generate-all-locators.js +72 -0
- package/dist/locators/generate-all-locators.js.map +1 -0
- package/dist/locators/locator-generation.d.ts +36 -0
- package/dist/locators/locator-generation.js +501 -0
- package/dist/locators/locator-generation.js.map +1 -0
- package/dist/locators/logger.d.ts +5 -0
- package/dist/locators/logger.js +9 -0
- package/dist/locators/logger.js.map +1 -0
- package/dist/locators/source-parsing.d.ts +43 -0
- package/dist/locators/source-parsing.js +100 -0
- package/dist/locators/source-parsing.js.map +1 -0
- package/dist/resources/index.d.ts +1 -0
- package/dist/resources/index.js +7 -0
- package/dist/resources/index.js.map +1 -0
- package/dist/resources/java/template.d.ts +4 -0
- package/dist/resources/java/template.js +82 -0
- package/dist/resources/java/template.js.map +1 -0
- package/dist/schema.d.ts +2 -0
- package/dist/schema.js +5 -0
- package/dist/schema.js.map +1 -0
- package/dist/scripts/simple-index-documentation.d.ts +20 -0
- package/dist/scripts/simple-index-documentation.js +77 -0
- package/dist/scripts/simple-index-documentation.js.map +1 -0
- package/dist/scripts/simple-query-documentation.d.ts +12 -0
- package/dist/scripts/simple-query-documentation.js +52 -0
- package/dist/scripts/simple-query-documentation.js.map +1 -0
- package/dist/server.d.ts +3 -0
- package/dist/server.js +37 -0
- package/dist/server.js.map +1 -0
- package/dist/tests/__mocks__/@appium/support.d.ts +21 -0
- package/dist/tests/__mocks__/@appium/support.js +30 -0
- package/dist/tests/__mocks__/@appium/support.js.map +1 -0
- package/dist/tests/generate-all-locators.test.d.ts +1 -0
- package/dist/tests/generate-all-locators.test.js +140 -0
- package/dist/tests/generate-all-locators.test.js.map +1 -0
- package/dist/tests/test-setup-wda.d.ts +1 -0
- package/dist/tests/test-setup-wda.js +202 -0
- package/dist/tests/test-setup-wda.js.map +1 -0
- package/dist/tools/answer-appium.d.ts +1 -0
- package/dist/tools/answer-appium.js +71 -0
- package/dist/tools/answer-appium.js.map +1 -0
- package/dist/tools/boot-simulator.d.ts +1 -0
- package/dist/tools/boot-simulator.js +71 -0
- package/dist/tools/boot-simulator.js.map +1 -0
- package/dist/tools/create-session.d.ts +1 -0
- package/dist/tools/create-session.js +192 -0
- package/dist/tools/create-session.js.map +1 -0
- package/dist/tools/delete-session.d.ts +1 -0
- package/dist/tools/delete-session.js +47 -0
- package/dist/tools/delete-session.js.map +1 -0
- package/dist/tools/documentation/index.d.ts +28 -0
- package/dist/tools/documentation/index.js +63 -0
- package/dist/tools/documentation/index.js.map +1 -0
- package/dist/tools/documentation/reasoning-rag.d.ts +88 -0
- package/dist/tools/documentation/reasoning-rag.js +281 -0
- package/dist/tools/documentation/reasoning-rag.js.map +1 -0
- package/dist/tools/documentation/sentence-transformers-embeddings.d.ts +34 -0
- package/dist/tools/documentation/sentence-transformers-embeddings.js +111 -0
- package/dist/tools/documentation/sentence-transformers-embeddings.js.map +1 -0
- package/dist/tools/documentation/simple-pdf-indexer.d.ts +45 -0
- package/dist/tools/documentation/simple-pdf-indexer.js +402 -0
- package/dist/tools/documentation/simple-pdf-indexer.js.map +1 -0
- package/dist/tools/documentation/uploads/documents.json +1 -0
- package/dist/tools/generate-tests.d.ts +2 -0
- package/dist/tools/generate-tests.js +46 -0
- package/dist/tools/generate-tests.js.map +1 -0
- package/dist/tools/index.d.ts +16 -0
- package/dist/tools/index.js +112 -0
- package/dist/tools/index.js.map +1 -0
- package/dist/tools/install-wda.d.ts +1 -0
- package/dist/tools/install-wda.js +219 -0
- package/dist/tools/install-wda.js.map +1 -0
- package/dist/tools/interactions/activate-app.d.ts +2 -0
- package/dist/tools/interactions/activate-app.js +44 -0
- package/dist/tools/interactions/activate-app.js.map +1 -0
- package/dist/tools/interactions/click.d.ts +2 -0
- package/dist/tools/interactions/click.js +45 -0
- package/dist/tools/interactions/click.js.map +1 -0
- package/dist/tools/interactions/double-tap.d.ts +2 -0
- package/dist/tools/interactions/double-tap.js +81 -0
- package/dist/tools/interactions/double-tap.js.map +1 -0
- package/dist/tools/interactions/find.d.ts +13 -0
- package/dist/tools/interactions/find.js +55 -0
- package/dist/tools/interactions/find.js.map +1 -0
- package/dist/tools/interactions/get-text.d.ts +2 -0
- package/dist/tools/interactions/get-text.js +45 -0
- package/dist/tools/interactions/get-text.js.map +1 -0
- package/dist/tools/interactions/install-app.d.ts +2 -0
- package/dist/tools/interactions/install-app.js +43 -0
- package/dist/tools/interactions/install-app.js.map +1 -0
- package/dist/tools/interactions/list-apps.d.ts +2 -0
- package/dist/tools/interactions/list-apps.js +59 -0
- package/dist/tools/interactions/list-apps.js.map +1 -0
- package/dist/tools/interactions/screenshot.d.ts +2 -0
- package/dist/tools/interactions/screenshot.js +49 -0
- package/dist/tools/interactions/screenshot.js.map +1 -0
- package/dist/tools/interactions/set-value.d.ts +2 -0
- package/dist/tools/interactions/set-value.js +46 -0
- package/dist/tools/interactions/set-value.js.map +1 -0
- package/dist/tools/interactions/terminate-app.d.ts +2 -0
- package/dist/tools/interactions/terminate-app.js +45 -0
- package/dist/tools/interactions/terminate-app.js.map +1 -0
- package/dist/tools/interactions/uninstall-app.d.ts +2 -0
- package/dist/tools/interactions/uninstall-app.js +45 -0
- package/dist/tools/interactions/uninstall-app.js.map +1 -0
- package/dist/tools/locators.d.ts +1 -0
- package/dist/tools/locators.js +71 -0
- package/dist/tools/locators.js.map +1 -0
- package/dist/tools/scroll-to-element.d.ts +1 -0
- package/dist/tools/scroll-to-element.js +155 -0
- package/dist/tools/scroll-to-element.js.map +1 -0
- package/dist/tools/scroll.d.ts +1 -0
- package/dist/tools/scroll.js +91 -0
- package/dist/tools/scroll.js.map +1 -0
- package/dist/tools/select-device.d.ts +5 -0
- package/dist/tools/select-device.js +222 -0
- package/dist/tools/select-device.js.map +1 -0
- package/dist/tools/select-platform.d.ts +1 -0
- package/dist/tools/select-platform.js +195 -0
- package/dist/tools/select-platform.js.map +1 -0
- package/dist/tools/session-store.d.ts +7 -0
- package/dist/tools/session-store.js +64 -0
- package/dist/tools/session-store.js.map +1 -0
- package/dist/tools/setup-wda.d.ts +1 -0
- package/dist/tools/setup-wda.js +177 -0
- package/dist/tools/setup-wda.js.map +1 -0
- package/docs/CONTRIBUTING.md +424 -0
- package/eslint.config.js +49 -0
- package/examples/android-gmail.md +7 -0
- package/examples/android-todo-app.md +9 -0
- package/jest.config.js +23 -0
- package/package.json +71 -6
- package/scripts/setup-submodules-sparse.sh +53 -0
- package/scripts/update-submodules.sh +14 -0
- package/src/devicemanager/adb-manager.ts +164 -0
- package/src/devicemanager/ios-manager.ts +145 -0
- package/src/index.ts +47 -0
- package/src/locators/element-filter.ts +134 -0
- package/src/locators/generate-all-locators.ts +149 -0
- package/src/locators/locator-generation.ts +657 -0
- package/src/locators/logger.ts +11 -0
- package/src/locators/source-parsing.ts +149 -0
- package/src/resources/caps.json +697 -0
- package/src/resources/index.ts +7 -0
- package/src/resources/java/template.ts +83 -0
- package/src/resources/submodules/appium/.github/PULL_REQUEST_TEMPLATE.md +28 -0
- package/src/resources/submodules/appium/CHANGELOG.md +45 -0
- package/src/resources/submodules/appium/CONDUCT.md +48 -0
- package/src/resources/submodules/appium/GOVERNANCE.md +185 -0
- package/src/resources/submodules/appium/IDEAS.md +16 -0
- package/src/resources/submodules/appium/README.md +221 -0
- package/src/resources/submodules/appium/ROADMAP.md +30 -0
- package/src/resources/submodules/appium/SPONSORS.md +3 -0
- package/src/resources/submodules/appium/docs/README.md +6 -0
- package/src/resources/submodules/appium/docs/payout.md +35 -0
- package/src/resources/submodules/appium/packages/appium/CHANGELOG.md +1437 -0
- package/src/resources/submodules/appium/packages/appium/README.md +221 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/index.md +2 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/posts/announcing-appiumconf2024.md +45 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/posts/announcing-browserstack-as-strategic-partner.md +46 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/posts/announcing-headspin-as-development-partner.md +47 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/posts/announcing-lambdatest-as-strategic-partner.md +42 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/posts/announcing-sauce-labs-as-strategic-partner.md +36 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/posts/announcing-sponsorship-program.md +48 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/posts/appium3.md +40 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/blog/posts/hello-world.md +15 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/contributing/index.md +150 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/developing/build-docs.md +86 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/developing/build-doctor-checks.md +141 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/developing/build-drivers.md +860 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/developing/build-plugins.md +514 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/developing/config-system.md +451 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/developing/index.md +18 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/developing/sensitive.md +49 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/ecosystem/clients.md +132 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/ecosystem/drivers.md +207 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/ecosystem/index.md +45 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/ecosystem/plugins.md +138 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/ecosystem/tools.md +83 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/branch-testing.md +57 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/caching.md +76 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/caps.md +275 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/config.md +98 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/context.md +44 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/event-timing.md +73 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/execute-methods.md +122 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/grid.md +166 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/headers.md +17 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/log-filters.md +86 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/managing-exts.md +87 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/migrating-1-to-2.md +368 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/migrating-2-to-3.md +464 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/security.md +89 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/settings.md +68 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/guides/tls.md +42 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/index.md +59 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/intro/appium.md +202 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/intro/clients.md +127 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/intro/drivers.md +188 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/intro/history.md +196 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/intro/index.md +39 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/index.md +29 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/install.md +50 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/next-steps.md +23 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/requirements.md +29 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/test-dotnet.md +105 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/test-java.md +23 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/test-js.md +75 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/test-py.md +60 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/test-rb.md +83 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/quickstart/uiauto2-driver.md +144 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/api/appium.md +394 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/api/bidi.md +70 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/api/index.md +30 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/api/jsonwp.md +214 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/api/mjsonwp.md +151 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/api/others.md +671 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/api/plugins.md +289 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/api/webdriver.md +1114 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/cli/env-vars.md +31 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/cli/extensions.md +239 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/cli/index.md +35 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/cli/server.md +76 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/cli/setup.md +76 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/reference/index.md +25 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/resources/index.md +28 -0
- package/src/resources/submodules/appium/packages/appium/docs/en/sponsors/index.md +64 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/index.md +2 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/posts/announcing-appiumconf2024.md +45 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/posts/announcing-browserstack-as-strategic-partner.md +46 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/posts/announcing-headspin-as-development-partner.md +47 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/posts/announcing-lambdatest-as-strategic-partner.md +41 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/posts/announcing-sauce-labs-as-strategic-partner.md +36 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/posts/announcing-sponsorship-program.md +48 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/posts/appium3.md +40 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/blog/posts/hello-world.md +15 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/contributing/index.md +158 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/developing/build-docs.md +86 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/developing/build-doctor-checks.md +141 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/developing/build-drivers.md +866 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/developing/build-plugins.md +520 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/developing/config-system.md +468 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/developing/index.md +18 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/developing/sensitive.md +49 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/ecosystem/clients.md +143 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/ecosystem/drivers.md +219 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/ecosystem/index.md +45 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/ecosystem/plugins.md +140 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/ecosystem/tools.md +87 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/branch-testing.md +57 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/caching.md +78 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/caps.md +259 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/config.md +102 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/context.md +44 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/event-timing.md +75 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/execute-methods.md +142 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/grid.md +166 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/headers.md +17 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/log-filters.md +86 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/managing-exts.md +89 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/migrating-1-to-2.md +402 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/migrating-2-to-3.md +458 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/security.md +89 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/settings.md +70 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/guides/tls.md +43 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/index.md +55 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/intro/appium.md +191 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/intro/clients.md +139 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/intro/drivers.md +188 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/intro/history.md +196 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/intro/index.md +39 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/index.md +23 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/install.md +47 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/next-steps.md +19 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/requirements.md +29 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/test-dotnet.md +107 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/test-java.md +23 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/test-js.md +77 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/test-py.md +63 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/test-rb.md +85 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/quickstart/uiauto2-driver.md +148 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/api/appium.md +395 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/api/bidi.md +71 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/api/index.md +30 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/api/jsonwp.md +215 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/api/mjsonwp.md +152 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/api/others.md +672 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/api/plugins.md +291 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/api/webdriver.md +1114 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/cli/env-vars.md +31 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/cli/extensions.md +240 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/cli/index.md +35 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/cli/server.md +76 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/cli/setup.md +78 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/reference/index.md +25 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/resources/index.md +28 -0
- package/src/resources/submodules/appium/packages/appium/docs/ja/sponsors/index.md +61 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/appium-logo-horiz-white.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/appium-logo-horiz.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/appium-logo-white.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/appium-logo.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/sponsor-logo-browserstack-dark.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/sponsor-logo-browserstack-light.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/sponsor-logo-lambdatest-dark.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/sponsor-logo-lambdatest-light.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/overrides/assets/images/sponsor-logo-sauce.png +0 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/index.md +2 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/posts/announcing-appiumconf2024.md +45 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/posts/announcing-browserstack-as-strategic-partner.md +46 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/posts/announcing-headspin-as-development-partner.md +47 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/posts/announcing-lambdatest-as-strategic-partner.md +41 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/posts/announcing-sauce-labs-as-strategic-partner.md +36 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/posts/announcing-sponsorship-program.md +48 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/posts/appium3.md +40 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/blog/posts/hello-world.md +15 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/contributing/index.md +132 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/developing/build-docs.md +86 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/developing/build-doctor-checks.md +141 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/developing/build-drivers.md +866 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/developing/build-plugins.md +520 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/developing/config-system.md +468 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/developing/index.md +18 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/developing/sensitive.md +49 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/ecosystem/clients.md +143 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/ecosystem/drivers.md +219 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/ecosystem/index.md +45 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/ecosystem/plugins.md +140 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/ecosystem/tools.md +87 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/branch-testing.md +57 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/caching.md +78 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/caps.md +284 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/config.md +102 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/context.md +44 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/event-timing.md +75 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/execute-methods.md +142 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/grid.md +166 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/headers.md +17 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/log-filters.md +86 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/managing-exts.md +89 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/migrating-1-to-2.md +410 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/migrating-2-to-3.md +459 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/security.md +89 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/settings.md +70 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/guides/tls.md +43 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/index.md +54 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/intro/appium.md +200 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/intro/clients.md +139 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/intro/drivers.md +188 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/intro/history.md +196 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/intro/index.md +39 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/index.md +23 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/install.md +47 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/next-steps.md +19 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/requirements.md +21 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/test-dotnet.md +99 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/test-java.md +20 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/test-js.md +62 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/test-py.md +57 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/test-rb.md +80 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/quickstart/uiauto2-driver.md +148 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/api/appium.md +395 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/api/bidi.md +71 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/api/index.md +30 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/api/jsonwp.md +215 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/api/mjsonwp.md +152 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/api/others.md +672 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/api/plugins.md +291 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/api/webdriver.md +1114 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/cli/env-vars.md +31 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/cli/extensions.md +240 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/cli/index.md +35 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/cli/server.md +76 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/cli/setup.md +78 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/reference/index.md +25 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/resources/index.md +28 -0
- package/src/resources/submodules/appium/packages/appium/docs/zh/sponsors/index.md +61 -0
- package/src/resources/submodules/appium/packages/appium/types/manifest/README.md +30 -0
- package/src/resources/submodules/appium/packages/base-driver/CHANGELOG.md +1131 -0
- package/src/resources/submodules/appium/packages/base-driver/README.md +15 -0
- package/src/resources/submodules/appium/packages/base-driver/docs/mjsonwp/errors.md +82 -0
- package/src/resources/submodules/appium/packages/base-driver/docs/mjsonwp/protocol-methods.md +182 -0
- package/src/resources/submodules/appium/packages/base-driver/static/appium.png +0 -0
- package/src/resources/submodules/appium/packages/base-plugin/CHANGELOG.md +672 -0
- package/src/resources/submodules/appium/packages/base-plugin/README.md +15 -0
- package/src/resources/submodules/appium/packages/docutils/CHANGELOG.md +948 -0
- package/src/resources/submodules/appium/packages/docutils/README.md +27 -0
- package/src/resources/submodules/appium/packages/driver-test-support/CHANGELOG.md +717 -0
- package/src/resources/submodules/appium/packages/driver-test-support/README.md +112 -0
- package/src/resources/submodules/appium/packages/eslint-config-appium-ts/CHANGELOG.md +168 -0
- package/src/resources/submodules/appium/packages/eslint-config-appium-ts/README.md +33 -0
- package/src/resources/submodules/appium/packages/execute-driver-plugin/CHANGELOG.md +603 -0
- package/src/resources/submodules/appium/packages/execute-driver-plugin/README.md +42 -0
- package/src/resources/submodules/appium/packages/fake-driver/CHANGELOG.md +545 -0
- package/src/resources/submodules/appium/packages/fake-driver/README.md +7 -0
- package/src/resources/submodules/appium/packages/fake-driver/lib/screen.png +0 -0
- package/src/resources/submodules/appium/packages/fake-plugin/CHANGELOG.md +683 -0
- package/src/resources/submodules/appium/packages/fake-plugin/README.md +7 -0
- package/src/resources/submodules/appium/packages/images-plugin/CHANGELOG.md +602 -0
- package/src/resources/submodules/appium/packages/images-plugin/README.md +27 -0
- package/src/resources/submodules/appium/packages/images-plugin/docs/find-by-image.md +65 -0
- package/src/resources/submodules/appium/packages/images-plugin/docs/image-comparison.md +203 -0
- package/src/resources/submodules/appium/packages/images-plugin/test/fixtures/appstore.png +0 -0
- package/src/resources/submodules/appium/packages/images-plugin/test/fixtures/img1.png +0 -0
- package/src/resources/submodules/appium/packages/images-plugin/test/fixtures/img2.png +0 -0
- package/src/resources/submodules/appium/packages/images-plugin/test/fixtures/img2_part.png +0 -0
- package/src/resources/submodules/appium/packages/logger/CHANGELOG.md +162 -0
- package/src/resources/submodules/appium/packages/logger/README.md +31 -0
- package/src/resources/submodules/appium/packages/opencv/CHANGELOG.md +384 -0
- package/src/resources/submodules/appium/packages/opencv/README.md +68 -0
- package/src/resources/submodules/appium/packages/opencv/test/e2e/images/appium-diagram.jpg +0 -0
- package/src/resources/submodules/appium/packages/opencv/test/e2e/images/cc1.png +0 -0
- package/src/resources/submodules/appium/packages/opencv/test/e2e/images/cc2.png +0 -0
- package/src/resources/submodules/appium/packages/opencv/test/e2e/images/cc_rotated.png +0 -0
- package/src/resources/submodules/appium/packages/opencv/test/e2e/images/findwaldo.jpg +0 -0
- package/src/resources/submodules/appium/packages/opencv/test/e2e/images/number5.png +0 -0
- package/src/resources/submodules/appium/packages/opencv/test/e2e/images/waldo.jpg +0 -0
- package/src/resources/submodules/appium/packages/plugin-test-support/CHANGELOG.md +539 -0
- package/src/resources/submodules/appium/packages/plugin-test-support/README.md +49 -0
- package/src/resources/submodules/appium/packages/relaxed-caps-plugin/CHANGELOG.md +154 -0
- package/src/resources/submodules/appium/packages/relaxed-caps-plugin/README.md +35 -0
- package/src/resources/submodules/appium/packages/schema/CHANGELOG.md +271 -0
- package/src/resources/submodules/appium/packages/schema/README.md +50 -0
- package/src/resources/submodules/appium/packages/storage-plugin/CHANGELOG.md +73 -0
- package/src/resources/submodules/appium/packages/storage-plugin/README.md +83 -0
- package/src/resources/submodules/appium/packages/strongbox/CHANGELOG.md +94 -0
- package/src/resources/submodules/appium/packages/strongbox/README.md +96 -0
- package/src/resources/submodules/appium/packages/support/CHANGELOG.md +1054 -0
- package/src/resources/submodules/appium/packages/support/README.md +161 -0
- package/src/resources/submodules/appium/packages/test-support/CHANGELOG.md +712 -0
- package/src/resources/submodules/appium/packages/test-support/README.md +61 -0
- package/src/resources/submodules/appium/packages/tsconfig/CHANGELOG.md +131 -0
- package/src/resources/submodules/appium/packages/tsconfig/README.md +19 -0
- package/src/resources/submodules/appium/packages/types/CHANGELOG.md +793 -0
- package/src/resources/submodules/appium/packages/types/README.md +21 -0
- package/src/resources/submodules/appium/packages/universal-xml-plugin/CHANGELOG.md +435 -0
- package/src/resources/submodules/appium/packages/universal-xml-plugin/README.md +53 -0
- package/src/resources/submodules/appium/renovate/README.md +63 -0
- package/src/resources/submodules/appium-uiautomator2-driver/CHANGELOG.md +1204 -0
- package/src/resources/submodules/appium-uiautomator2-driver/README.md +2077 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/actions.md +72 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/activity-startup.md +47 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/android-appbundle.md +69 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/android-mobile-gestures.md +352 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/bidi.md +50 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/capability-sets.md +136 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/scheduled-actions.md +155 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/uiautomator-uiselector.md +51 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/unlock/main.md +95 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/unlock/screen1.png +0 -0
- package/src/resources/submodules/appium-uiautomator2-driver/docs/unlock/screen2.png +0 -0
- package/src/resources/submodules/appium-uiautomator2-driver/test/functional/assets/checkered-squares.png +0 -0
- package/src/resources/submodules/appium-uiautomator2-driver/test/functional/assets/start-button.png +0 -0
- package/src/resources/submodules/appium-uiautomator2-driver/test/functional/assets/stop-button.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/.github/ISSUE_TEMPLATE.md +4 -0
- package/src/resources/submodules/appium-xcuitest-driver/CHANGELOG.md +2594 -0
- package/src/resources/submodules/appium-xcuitest-driver/README.md +55 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/assets/images/appium-logo-white.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/assets/images/appium-logo.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/assets/images/appium-plus-xctest.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/contributing.md +45 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/endpoints-wda.md +61 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/endpoints.md +98 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/assets/images/ios-xctest-file-movement/keynote.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/assets/images/ios-xctest-file-movement/on_my_iphone.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/assets/images/ios-xctest-file-movement/top_files.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/attach-to-running-wda.md +43 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/audio-capture.md +78 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/capability-sets.md +169 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/ci-setup.md +47 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/clipboard.md +47 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/elements-lookup-troubleshooting.md +158 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/file-transfer.md +147 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/gestures.md +52 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/hybrid.md +137 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/input-events.md +67 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/install-certificate.md +19 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/multiple-xcode-versions.md +37 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/parallel-tests.md +39 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/run-prebuilt-wda.md +135 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/run-preinstalled-wda.md +178 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/touch-id.md +33 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/troubleshooting.md +191 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/tvos.md +114 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/wda-custom-server.md +283 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/guides/wda-slowness.md +231 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/index.md +36 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/installation/index.md +137 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/overview.md +19 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/check-prov-prof.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/create-new-project.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/create-single-page.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/no-prov-prof.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/project-prov-prof.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/set-up-bundle.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/untrusted-dev.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/xcode-bundle-id.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/xcode-config.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/xcode-facebook-fail.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/assets/images/xcode-facebook-succeed.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/index.md +51 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/prov-profile-basic-auto.md +49 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/prov-profile-basic-manual.md +40 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/prov-profile-full-manual.md +50 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/prov-profile-generic-manual.md +49 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/preparation/real-device-config.md +100 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/assets/images/useXctestrunFile.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/bidi.md +75 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/capabilities.md +165 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/commands.md +490 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/element-attributes.md +27 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/execute-methods.md +2206 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/ios-predicate.md +196 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/locator-strategies.md +19 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/scripts.md +29 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/security-flags.md +22 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/server-args.md +16 -0
- package/src/resources/submodules/appium-xcuitest-driver/docs/reference/settings.md +49 -0
- package/src/resources/submodules/appium-xcuitest-driver/test/assets/TestApp-iphonesimulator.app/Default-568h@2x.png +0 -0
- package/src/resources/submodules/appium-xcuitest-driver/test/assets/test.png +0 -0
- package/src/schema.ts +5 -0
- package/src/scripts/simple-index-documentation.ts +93 -0
- package/src/scripts/simple-query-documentation.ts +61 -0
- package/src/server.ts +40 -0
- package/src/tests/README.md +83 -0
- package/src/tests/__mocks__/@appium/support.ts +31 -0
- package/src/tests/generate-all-locators.test.ts +179 -0
- package/src/tests/test-setup-wda.ts +247 -0
- package/src/tools/README.md +170 -0
- package/src/tools/answer-appium.ts +75 -0
- package/src/tools/boot-simulator.ts +87 -0
- package/src/tools/create-session.ts +270 -0
- package/src/tools/delete-session.ts +46 -0
- package/src/tools/documentation/index.ts +97 -0
- package/src/tools/documentation/reasoning-rag.ts +434 -0
- package/src/tools/documentation/sentence-transformers-embeddings.ts +142 -0
- package/src/tools/documentation/simple-pdf-indexer.ts +509 -0
- package/src/tools/documentation/uploads/documents.json +1 -0
- package/src/tools/generate-tests.ts +50 -0
- package/src/tools/index.ts +133 -0
- package/src/tools/install-wda.ts +277 -0
- package/src/tools/interactions/activate-app.ts +46 -0
- package/src/tools/interactions/click.ts +47 -0
- package/src/tools/interactions/double-tap.ts +87 -0
- package/src/tools/interactions/find.ts +58 -0
- package/src/tools/interactions/get-text.ts +47 -0
- package/src/tools/interactions/install-app.ts +45 -0
- package/src/tools/interactions/list-apps.ts +65 -0
- package/src/tools/interactions/screenshot.ts +56 -0
- package/src/tools/interactions/set-value.ts +48 -0
- package/src/tools/interactions/terminate-app.ts +47 -0
- package/src/tools/interactions/uninstall-app.ts +47 -0
- package/src/tools/locators.ts +83 -0
- package/src/tools/scroll-to-element.ts +188 -0
- package/src/tools/scroll.ts +97 -0
- package/src/tools/select-device.ts +298 -0
- package/src/tools/select-platform.ts +243 -0
- package/src/tools/session-store.ts +72 -0
- package/src/tools/setup-wda.ts +218 -0
- package/src/types/appium-ios-device.d.ts +8 -0
- package/src/types/appium-xcuitest-driver.d.ts +5 -0
- package/tsconfig.json +23 -0
- package/index.js +0 -0
|
@@ -0,0 +1,451 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Appium's Config System
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
Appium includes support for [configuration files](../guides/config.md). A configuration file is
|
|
6
|
+
intended to have (nearly) 1:1 parity with command-line arguments. An end user can supply Appium with
|
|
7
|
+
a configuration file, CLI args, or both (the args have precedence over the config file).
|
|
8
|
+
|
|
9
|
+
This document will be a technical overview of how the configuration system works. It is intended
|
|
10
|
+
for Appium contributors, but will also explain the system's fundamental features.
|
|
11
|
+
|
|
12
|
+
## Reading a Config File
|
|
13
|
+
|
|
14
|
+
A config file is a JSON, JavaScript, or YAML file which can be validated against a schema. By
|
|
15
|
+
default, this file will be named `.appiumrc.{json,js,yaml,yml}` and should be in the root of the
|
|
16
|
+
project which depends upon `appium`. Other filenames and locations are supported via the `--config
|
|
17
|
+
<file>` flag. For obvious reasons, the `config` argument is disallowed within config files.
|
|
18
|
+
|
|
19
|
+
In lieu of a separate file, configuration can be embedded in a project's `package.json` using the
|
|
20
|
+
`appiumConfig` property, e.g.,:
|
|
21
|
+
|
|
22
|
+
```json
|
|
23
|
+
{
|
|
24
|
+
"appiumConfig": {
|
|
25
|
+
"server": {
|
|
26
|
+
"port": 12345
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
When an Appium server is started via the `appium` executable, the `init` function in `lib/main.js`
|
|
33
|
+
will call into `lib/config-file.js` to load and/or search for a configuration file and in
|
|
34
|
+
`package.json`.
|
|
35
|
+
|
|
36
|
+
!!! note
|
|
37
|
+
|
|
38
|
+
It is not an error if configuration isn't found!
|
|
39
|
+
|
|
40
|
+
The [`lilconfig`](https://npm.im/lilconfig) package provides the search & load functionality; refer
|
|
41
|
+
to its documentation for more information about the search paths. Additionally, Appium provides
|
|
42
|
+
support for config files written in YAML via the package [`yaml`](https://npm.im/yaml).
|
|
43
|
+
|
|
44
|
+
If a config file is found and successfully [validated](#validation), the result will be merged with
|
|
45
|
+
a set of defaults and any additional CLI arguments. CLI arguments have precedence over config
|
|
46
|
+
files, and config files have precedence over defaults.
|
|
47
|
+
|
|
48
|
+
## Validation
|
|
49
|
+
|
|
50
|
+
The same system is used for _both_ validation of config files _and_ command-line arguments.
|
|
51
|
+
|
|
52
|
+
The package [`ajv`](https://npm.im/ajv) provides validation. Of course, to make `ajv` validate
|
|
53
|
+
anything, it must be provided a _schema_.
|
|
54
|
+
|
|
55
|
+
The _base_ schema is a [JSON Schema
|
|
56
|
+
Draft-7](https://json-schema.org/draft/2020-12/json-schema-core.html)-compliant object exported by
|
|
57
|
+
`lib/schema/appium-config-schema.js`. This schema defines configuration _native to Appium_, and
|
|
58
|
+
only concerns its behavior as a _server_; it does not define configuration for any other
|
|
59
|
+
functionality (e.g., the `plugin` or `driver` subcommands).
|
|
60
|
+
|
|
61
|
+
!!! warning
|
|
62
|
+
|
|
63
|
+
Note that this file is the _base_ schema; this will become painfully relevant.
|
|
64
|
+
|
|
65
|
+
This file is is _not_ a JSON file, because a) JSON is painful to work with for humans, b) is
|
|
66
|
+
especially reviled by @jlipps, and c) `ajv` accepts objects, not JSON files.
|
|
67
|
+
|
|
68
|
+
It is more straightforward to explain how config files are validated, so we'll start there.
|
|
69
|
+
|
|
70
|
+
### Validating Config Files
|
|
71
|
+
|
|
72
|
+
When a config file is found (`lib/config-file.js`), it will call the `validate` function exported
|
|
73
|
+
from `lib/schema/schema.js` with the contents of the config file. In turn, this asks `ajv` to
|
|
74
|
+
validate the data against the schema that Appium has provided it.
|
|
75
|
+
|
|
76
|
+
If the config file is invalid, errors will be generated to be displayed to the user. Finally, the
|
|
77
|
+
`init` function will detect these errors, display them, and the process will exit.
|
|
78
|
+
|
|
79
|
+
I hope that made sense, because this is the easy part.
|
|
80
|
+
|
|
81
|
+
### Validating CLI Arguments
|
|
82
|
+
|
|
83
|
+
As mentioned earlier, the same system is used for validating both config files and CLI arguments.
|
|
84
|
+
|
|
85
|
+
Totally not judging, but Appium uses [`argparse`](https://npm.im/argparse) for its CLI argument
|
|
86
|
+
parsing. This package, and others like it, provides an API to define the arguments a command-line
|
|
87
|
+
Node.js script accepts, and will ultimately return an object representation of the user-supplied
|
|
88
|
+
arguments.
|
|
89
|
+
|
|
90
|
+
Just as the schema defines what's allowed in a config file, it also defines what's allowed on the
|
|
91
|
+
command-line.
|
|
92
|
+
|
|
93
|
+
#### Defining CLI Arguments via Schema
|
|
94
|
+
|
|
95
|
+
CLI arguments must be _defined_ before their values can be validated.
|
|
96
|
+
|
|
97
|
+
A JSON schema isn't a natural fit for defining CLI args--it needs some grease to make it work--but
|
|
98
|
+
it's close enough that we can do so with an adapter and some custom metadata.
|
|
99
|
+
|
|
100
|
+
In `lib/cli/parser.js`, there's a wrapper around `argparse`'s `ArgumentParser`; it's called (wait
|
|
101
|
+
for it)... `ArgParser`. The wrapper exists because we're doing some custom things with `argparse`,
|
|
102
|
+
but is has nothing to do with the schema directly.
|
|
103
|
+
|
|
104
|
+
An `ArgParser` instance is created and its `parseArgs()` method is called with the raw CLI
|
|
105
|
+
arguments. The definition of the accepted arguments comes from `lib/cli/args.js` in part--here, all
|
|
106
|
+
of the arguments _not_ intended for use with the `server` subcommand are hard-coded (e.g., the
|
|
107
|
+
`driver` subcommand and _its_ subcommands). `args.js` also contains a function `getServerArgs()`,
|
|
108
|
+
which in turn calls into `toParserArgs` in `lib/schema/cli-args.js`. `lib/schema/cli-args.js` can
|
|
109
|
+
be considered the "adapter" layer between `argparse` and the schema.
|
|
110
|
+
|
|
111
|
+
`toParserArgs` uses the `flattenSchema` function exported by `lib/schema/schema.js`, which
|
|
112
|
+
"squashes" the schema into a key/value representation. Then, `toParserArgs` iterates over each
|
|
113
|
+
key/value pair and "converts" it into a suitable `ArgumentOption` object for final handoff to
|
|
114
|
+
`ArgParser`.
|
|
115
|
+
|
|
116
|
+
This adapter (`cli-args.js`) is where most of the mess is hidden; let's explore this rat's nest
|
|
117
|
+
a bit further.
|
|
118
|
+
|
|
119
|
+
##### CLI & Schema Incongruities
|
|
120
|
+
|
|
121
|
+
The conversion algorithm (see function `subSchemaToArgDef` in `lib/schema/cli-args.js`) is mostly
|
|
122
|
+
just hacks and special cases neatly packed into a function. Things that don't cleanly map from
|
|
123
|
+
`argparse` to a JSON schema include, but are not limited to:
|
|
124
|
+
|
|
125
|
+
- A schema cannot natively express "store the value of `--foo=<value>` in a property called `bar`" in a schema (this corresponds to the `ArgumentOption['dest']` prop).
|
|
126
|
+
- A schema cannot natively express aliases; e.g., `--verbose` can also be `-v`
|
|
127
|
+
- A schema `enum` is not restricted to multiple types, but `argparse`'s equivalent `ArgumentOption['choices']` prop _is_
|
|
128
|
+
- A schema does not know about `argparse`'s concept of "actions" (note that Appium is not currently using custom actions--though it did, and it could again).
|
|
129
|
+
- `argparse` has no native type for `email`, `hostname`, `ipv4`, `uri` etc., and the schema does
|
|
130
|
+
- Schema validation only _validates_, it does not perform translation, transformation, or coercion (mostly). `argparse` allows this.
|
|
131
|
+
- Schemas allow the `null` type, for whatever reason. Ever pass `null` on the CLI?
|
|
132
|
+
- `argparse` does not understand anything other than primitives; no objects, arrays, etc., and certainly not arrays of a particular type.
|
|
133
|
+
|
|
134
|
+
All of the above cases and others are handled by the adapter.
|
|
135
|
+
|
|
136
|
+
!!! warning
|
|
137
|
+
|
|
138
|
+
Some decisions made in the adapter were arrived at via coin toss. If you are curious about why
|
|
139
|
+
something is the way it is, it's likely that it had to do _something_.
|
|
140
|
+
|
|
141
|
+
Let's look more closely at handling types.
|
|
142
|
+
|
|
143
|
+
#### Argument Types via `ajv`
|
|
144
|
+
|
|
145
|
+
While `argparse` allows consumers, via its API, to define the _type_ of various arguments (e.g.,
|
|
146
|
+
a string, number, boolean flag, etc.), Appium mostly avoids these built-in types. _Why is that?_
|
|
147
|
+
Well:
|
|
148
|
+
|
|
149
|
+
1. We already know the type of an argument, because we've defined it in a schema.
|
|
150
|
+
2. `ajv` provides validation against a schema.
|
|
151
|
+
3. A schema allows for greater expression of types, allowed values, etc., than `argparse` can provide natively.
|
|
152
|
+
4. The expressiveness of a schema allows for better error messaging.
|
|
153
|
+
|
|
154
|
+
To that end, the adapter eschews `argparse`'s built-in types (see allowed string values of
|
|
155
|
+
`ArgumentOption['type']`) and instead abuses the ability to provide a _function_ as a `type`. The
|
|
156
|
+
exception is _boolean_ flags, which do not have a `type`, but rather `action: 'store_true'`. The
|
|
157
|
+
world may never know why.
|
|
158
|
+
|
|
159
|
+
##### Types as Functions
|
|
160
|
+
|
|
161
|
+
When a `type` is a function, the function performs both validation _and_ coercion (if necessary).
|
|
162
|
+
So what are these functions?
|
|
163
|
+
|
|
164
|
+
> Note: `type` is _omitted_ (and thus _not_ a function) from the `ArgumentOption` if the property
|
|
165
|
+
> type is `boolean`, and is instead provided an `action` property of `store_true`. Yes, this is
|
|
166
|
+
> weird. No, I don't know why.
|
|
167
|
+
|
|
168
|
+
Well... it depends upon the schema. But generally speaking, we create a _pipeline_ of functions,
|
|
169
|
+
each corresponding to a keyword in the schema. Let's take the example of the `port` argument. In
|
|
170
|
+
lieu of asking the OS which ports the `appium`-running user can bind to, this argument is expected
|
|
171
|
+
to be an integer between 1 and 65535. This turns out to be two functions which we combine into
|
|
172
|
+
a pipeline:
|
|
173
|
+
|
|
174
|
+
1. Convert the value to an integer, if possible. Because _every value in `process.argv` is a string_, we must coerce if we want a number.
|
|
175
|
+
2. Use `ajv` to validate the integer against the schema for `port`. A schema lets us define a range via the `minimum` and `maximum` keywords. Read more about how this works in
|
|
176
|
+
|
|
177
|
+
Much like the config file validation, if errors are detected, Appium nicely tells the end-user and
|
|
178
|
+
the process exits w/ some help text.
|
|
179
|
+
|
|
180
|
+
For other arguments which are naturally of non-primitive types, things are not so straightforward.
|
|
181
|
+
|
|
182
|
+
##### Transformers
|
|
183
|
+
|
|
184
|
+
Remember how `argparse` doesn't understand arrays? What if the most ergonomic way to express
|
|
185
|
+
a value is, in fact, an array?
|
|
186
|
+
|
|
187
|
+
Well, Appium can't accept an array on the CLI, even though it can accept one in the config file.
|
|
188
|
+
But Appium _can_ accept a comma-delimited string (a CSV "line"). Or a string filepath referring to
|
|
189
|
+
a file which _contains_ a delimited list. Either way: by the time the value gets out of the
|
|
190
|
+
argument parser, it should be an array.
|
|
191
|
+
|
|
192
|
+
And as mentioned above, the native facilities of a JSON schema cannot express this. However, it's
|
|
193
|
+
possible to define a _custom keyword_ which Appium can then detect and handle accordingly. So
|
|
194
|
+
that's what Appium does.
|
|
195
|
+
|
|
196
|
+
In this case, a custom keyword `appiumCliTransformer` is registered with `ajv`. The value of
|
|
197
|
+
`appiumCliTransformer` (at the time of this writing) can be `csv` or `json`. In the base schema
|
|
198
|
+
file, `appium-config-schema.js`, Appium uses `appiumCliTransformer: 'csv'` if this behavior is
|
|
199
|
+
desired.
|
|
200
|
+
|
|
201
|
+
!!! note
|
|
202
|
+
|
|
203
|
+
Any property defined in the schema having type `array` will _automatically_ uses the `csv`
|
|
204
|
+
transformer. Likewise, a property having type `object` will use the `json` transformer. It's
|
|
205
|
+
conceivable that `array` may want to use the `json` transformer, but otherwise, the presence of
|
|
206
|
+
the `appiumCliTransformer` keyword on an `array`-or-`object`-typed property is not strictly
|
|
207
|
+
necessary.
|
|
208
|
+
|
|
209
|
+
The adapter (remember the adapter?) creates a pipeline function including a special "CSV
|
|
210
|
+
transformer" (transformers are defined in `lib/schema/cli-transformers.js`), and uses this function
|
|
211
|
+
as the `type` property of the `ArgumentOption` passed into `argparse`. In this case, the `type:
|
|
212
|
+
'array'` in the schema is ignored.
|
|
213
|
+
|
|
214
|
+
!!! note
|
|
215
|
+
|
|
216
|
+
The config file doesn't _need_ to perform any complex transformation of values, because it
|
|
217
|
+
naturally allows Appium to define exactly what it expects. So Appium does no post-processing of
|
|
218
|
+
config file values.
|
|
219
|
+
|
|
220
|
+
Properties that do not need this special treatment use `ajv` directly for validation. How this
|
|
221
|
+
works requires some explanation, so that's next.
|
|
222
|
+
|
|
223
|
+
#### Validation of Individual Arguments via `ajv`
|
|
224
|
+
|
|
225
|
+
When we think of a JSON schema, we tend to think, "I have this JSON file and I want to validate it
|
|
226
|
+
against the schema". That's valid, and in fact Appium does just that with config files! However,
|
|
227
|
+
Appium does not do this when validating arguments.
|
|
228
|
+
|
|
229
|
+
!!! note
|
|
230
|
+
|
|
231
|
+
During implementation, I was tempted to mash all of the arguments together into
|
|
232
|
+
a config-file-like data structure and then validate it all at once. I think that would have
|
|
233
|
+
been _possible_, but since an object full of CLI arguments is a flat key/value structure and
|
|
234
|
+
the schema is not, this seemed like trouble.
|
|
235
|
+
|
|
236
|
+
Instead, Appium validates a value against a specific property _within_ the schema. To do this, it
|
|
237
|
+
maintains a mapping between a CLI argument definition and its corresponding property. The mapping
|
|
238
|
+
itself is a `Map` with a unique identifier for the argument as the key, and an `ArgSpec`
|
|
239
|
+
(`lib/schema/arg-spec.js`) object as the value.
|
|
240
|
+
|
|
241
|
+
An `ArgSpec` object stores the following metadata:
|
|
242
|
+
|
|
243
|
+
| Property Name | Description |
|
|
244
|
+
| --------------- | ------------------------------------------------------------------------------------- |
|
|
245
|
+
| `name` | Canonical name of the argument, corresponding to the property name in the schema. |
|
|
246
|
+
| `extType?` | `driver` or `plugin`, if appropriate |
|
|
247
|
+
| `extName?` | Extension name, if appropriate |
|
|
248
|
+
| `ref` | Computed `$id` of the property in the schema |
|
|
249
|
+
| `arg` | Argument as accepted on CLI, without leading dashes |
|
|
250
|
+
| `dest` | Property name in parsed arguments object (as returned by `argparse`'s `parse_args()`) |
|
|
251
|
+
| `defaultValue?` | Value of the `default` keyword in schema, if appropriate |
|
|
252
|
+
|
|
253
|
+
When a schema is [finalized](#schema-loading), the `Map` is populated with `ArgSpec` objects
|
|
254
|
+
for all known arguments.
|
|
255
|
+
|
|
256
|
+
So when the adapter is creating the pipeline of functions for the argument's `type`, it already has
|
|
257
|
+
an `ArgSpec` for the argument. It creates a function which calls `validate(value, ref)` (in
|
|
258
|
+
`lib/schema/schema.js`) where `value` is whatever the user provided, and `ref` is the `ref`
|
|
259
|
+
property of the `ArgSpec`. The concept is that `ajv` can validate using _any_ `ref` it knows about;
|
|
260
|
+
each property in a schema can be referenced by this `ref` whether it's defined or not. To help
|
|
261
|
+
visualize, if a schema is:
|
|
262
|
+
|
|
263
|
+
```json
|
|
264
|
+
{
|
|
265
|
+
"$id": "my-schema.json",
|
|
266
|
+
"type": "object",
|
|
267
|
+
"properties": {
|
|
268
|
+
"foo": {
|
|
269
|
+
"type": "number"
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
```
|
|
274
|
+
|
|
275
|
+
The `ref` of `foo` would be `my-schema.json#/properties/foo`. Assuming our `Ajv` instance knows
|
|
276
|
+
about this `my-schema.json`, then we can call its `getSchema(ref)` method (which has a `schema`
|
|
277
|
+
property, but is a misnomer nonetheless) to get a validation function; `validate(value, ref)` in
|
|
278
|
+
`schema.js` calls this validation function.
|
|
279
|
+
|
|
280
|
+
!!! note
|
|
281
|
+
|
|
282
|
+
The schema spec says a schema author can supply an explicit `$id` keyword to override this;
|
|
283
|
+
it's unsupported by Appium at this time. If needed, extension authors must carefully use `$ref`
|
|
284
|
+
without custom `$id`s. It's highly unlikely an extension would have a schema so complicated as
|
|
285
|
+
to need this, however; Appium itself doesn't even use `$ref` to define its own properties!
|
|
286
|
+
|
|
287
|
+
Next, let's take a look at how Appium loads schemas. This actually happens _before_ any argument
|
|
288
|
+
validation.
|
|
289
|
+
|
|
290
|
+
## Schema Loading
|
|
291
|
+
|
|
292
|
+
Let's ignore extensions for a moment, and start with the base schema.
|
|
293
|
+
|
|
294
|
+
When something first imports the `lib/schema/schema.js` module, an instance of an `AppiumSchema` is
|
|
295
|
+
created. This is a singleton, and its methods are exported from the module (all of which are bound
|
|
296
|
+
to the instance).
|
|
297
|
+
|
|
298
|
+
The constructor does very little; it instantiates an `Ajv` instance and configures it with Appium's
|
|
299
|
+
[custom keywords](#custom-keyword-reference) and adds support for the `format` keyword via the
|
|
300
|
+
[ajv-formats](https://npm.im/ajv-formats) module.
|
|
301
|
+
|
|
302
|
+
Otherwise, the `AppiumSchema` instance does not interact with the `Ajv` instance until its
|
|
303
|
+
`finalize()` method (exported as `finalizeSchema()`) is called. When this method is called, we're
|
|
304
|
+
saying "we are not going to add any more schemas; go ahead and create `ArgSpec` objects and
|
|
305
|
+
register schemas with `ajv`".
|
|
306
|
+
|
|
307
|
+
When does finalization happen? Well:
|
|
308
|
+
|
|
309
|
+
1. When the `appium` executable begins, it _checks for and configures extensions_ (hand-wave) in `APPIUM_HOME`.
|
|
310
|
+
2. Only then does it start to think about arguments--it instantiates an `ArgParser`, which (as you'll recall) runs the adapter to convert the schema to arguments.
|
|
311
|
+
3. _Finalization happens here_--when creating the parser. Appium need the schema(s) to be registered with `ajv` in order to create validation functions for arguments.
|
|
312
|
+
4. Thereafter, Appium parses the arguments with the `ArgParser`.
|
|
313
|
+
5. Finally, decides what to do with the returned object.
|
|
314
|
+
|
|
315
|
+
Without extensions, `finalize()` still knows about the Appium base schema
|
|
316
|
+
(`appium-config-schema.js`), and just registers that. However, step 1. above is doing a _lot of
|
|
317
|
+
work_, so let's look at how extensions come into play.
|
|
318
|
+
|
|
319
|
+
## Extension Support
|
|
320
|
+
|
|
321
|
+
One of the design goals of this system is the following:
|
|
322
|
+
|
|
323
|
+
_An extension should be able to register custom CLI arguments with the Appium, and a user should be
|
|
324
|
+
able to use them like any other argument_.
|
|
325
|
+
|
|
326
|
+
Previously, Appium accepted arguments in this manner (via `--driverArgs`), but validation was
|
|
327
|
+
hand-rolled and required extension implementors to use a custom API. It also required the user to
|
|
328
|
+
awkwardly pass a JSON string as the configuration on the command-line. Further, no contextual help
|
|
329
|
+
(via `--help`) existed for these arguments.
|
|
330
|
+
|
|
331
|
+
Now, by providing a schema for its options, a driver or plugin can register CLI arguments and
|
|
332
|
+
config file schemas with Appium.
|
|
333
|
+
|
|
334
|
+
To register a schema, an extension must provide the `appium.schema` property in its `package.json`.
|
|
335
|
+
The value may be a schema or a path to a schema. If the latter, the schema should be JSON or
|
|
336
|
+
a CommonJS module (ESM not supported at this time, nor is YAML).
|
|
337
|
+
|
|
338
|
+
For any property in this schema, the property will appear as a CLI argument of the form
|
|
339
|
+
`--<extension-type>-<extension-name>-<property-name>`. For example, if the `fake` driver provides
|
|
340
|
+
a property `foo`, the argument will be `--driver-fake-foo`, and will show in `appium server --help`
|
|
341
|
+
like any other CLI argument.
|
|
342
|
+
|
|
343
|
+
The corresponding property in a config file would be
|
|
344
|
+
`server.<extension-type>.<extension-name>.<property-name>`, e.g.:
|
|
345
|
+
|
|
346
|
+
```json
|
|
347
|
+
{
|
|
348
|
+
"server": {
|
|
349
|
+
"driver": {
|
|
350
|
+
"fake": {
|
|
351
|
+
"foo": "bar"
|
|
352
|
+
}
|
|
353
|
+
}
|
|
354
|
+
}
|
|
355
|
+
}
|
|
356
|
+
```
|
|
357
|
+
|
|
358
|
+
The naming convention described above avoids problems of one extension type having a name conflict
|
|
359
|
+
with a different extension type.
|
|
360
|
+
|
|
361
|
+
!!! note
|
|
362
|
+
|
|
363
|
+
While an extension can provide aliases via `appiumCliAliases`, "short" flags are disallowed,
|
|
364
|
+
since all arguments from extensions are prefixed with `--<extension-type>-<extension-name>-`.
|
|
365
|
+
The extension name and argument name will be kebab-cased for the CLI, according to [Lodash's
|
|
366
|
+
rules](https://lodash.com/docs/4.17.15#kebabCase) around kebab-casing.
|
|
367
|
+
|
|
368
|
+
The schema object will look much like Appium's base schema, but it will only have top-level
|
|
369
|
+
properties (nested properties are currently unsupported). Example:
|
|
370
|
+
|
|
371
|
+
```json
|
|
372
|
+
{
|
|
373
|
+
"title": "my rad schema for the cowabunga driver",
|
|
374
|
+
"type": "object",
|
|
375
|
+
"properties": {
|
|
376
|
+
"fizz": {
|
|
377
|
+
"type": "string",
|
|
378
|
+
"default": "buzz",
|
|
379
|
+
"$comment": "corresponds to CLI --driver-cowabunga-fizz"
|
|
380
|
+
}
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
```
|
|
384
|
+
|
|
385
|
+
As written in a user's config file, this would be the `server.driver.cowabunga.fizz` property.
|
|
386
|
+
|
|
387
|
+
When extensions are loaded, the `schema` property is verified and the schema is registered with the
|
|
388
|
+
`AppiumSchema` (it is _not_ registered with `Ajv` until `finalize()` is called).
|
|
389
|
+
|
|
390
|
+
During finalization, each registered schema is added to the `Ajv` instance. The schema is assigned
|
|
391
|
+
an `$id` based on the extension type and name (which overrides whatever the extension provides, if
|
|
392
|
+
anything). Schemas are also forced to disallowed unknown arguments via the `additionalProperties:
|
|
393
|
+
false` keyword.
|
|
394
|
+
|
|
395
|
+
Behind the scenes, the base schema has `driver` and `plugin` properties which are objects. When
|
|
396
|
+
finalized, a property is added to each--corresponding to an extension name--and the value of this
|
|
397
|
+
property is a reference to the `$id` of a property in the extension schema. For example, the
|
|
398
|
+
`server.driver` property will look like this:
|
|
399
|
+
|
|
400
|
+
```json
|
|
401
|
+
{
|
|
402
|
+
"driver": {
|
|
403
|
+
"cowabunga": {
|
|
404
|
+
"$ref": "driver-cowabunga.json"
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
```
|
|
409
|
+
|
|
410
|
+
This is why we call it the "base" schema--it is _mutated_ when extensions provide schemas. The
|
|
411
|
+
extension schemas are kept separately, but the _references_ are added to the schema before it's
|
|
412
|
+
ultimately added to `ajv`. This works because an `Ajv` instance understands references _from_ any
|
|
413
|
+
schema it knows about _to_ any schema it knows about.
|
|
414
|
+
|
|
415
|
+
!!! note
|
|
416
|
+
|
|
417
|
+
This makes it impossible to provide a complete static schema for Appium _and_ the installed
|
|
418
|
+
extensions (as of Nov 5 2021). A static `.json` schema _is_ generated from the base (via a Gulp
|
|
419
|
+
task), but it does not contain any extension schemas. The static schema also has uses beyond
|
|
420
|
+
Appium; e.g., IDEs can provide contextual error-checking of config files this way. Let's solve
|
|
421
|
+
this?
|
|
422
|
+
|
|
423
|
+
Just like how we look up the reference ID of a particular argument in the base schema, validation
|
|
424
|
+
of arguments from extensions happens the exact same way. If the `cowabunga` driver has the schema
|
|
425
|
+
ID `driver-cowabunga.json`, then the `fizz` property can be referenced from any schema registered
|
|
426
|
+
with `ajv` via `driver-cowabunga.json#/properties/fizz`. "Base" schema arguments begin with
|
|
427
|
+
`appium.json#properties/` instead.
|
|
428
|
+
|
|
429
|
+
## Development Environment Support
|
|
430
|
+
|
|
431
|
+
During the flow of development, a couple extra tasks have been automated to maintain the base
|
|
432
|
+
schema:
|
|
433
|
+
|
|
434
|
+
- As a post-transpilation step, a `lib/appium-config.schema.json` gets generated from
|
|
435
|
+
- `lib/schema/appium-config-schema.js` (in addition to its CJS counterpart generated by Babel).
|
|
436
|
+
- This file is under version control. It ends up being _copied_ to
|
|
437
|
+
- `build/lib/appium-config.schema.json` in this step. A pre-commit hook (see
|
|
438
|
+
- `scripts/generate-schema-declarations.js` in the root monorepo) generates
|
|
439
|
+
- a `types/appium-config-schema.d.ts` from the above JSON file. The types in `types/types.d.ts`
|
|
440
|
+
- depend upon this file. This file is under version control.
|
|
441
|
+
|
|
442
|
+
## Custom Keyword Reference
|
|
443
|
+
|
|
444
|
+
Keywords are defined in `lib/schema/keywords.js`.
|
|
445
|
+
|
|
446
|
+
- `appiumCliAliases`: allows a schema to express aliases (e.g., a CLI argument can be `--verbose` or `-v`). This is an array of strings. Strings shorter than three (3) characters will begin with a single dash (`-`) instead of a double-dash (`--`). Note that any argument provided by an extension will begin with a double-dash, because these are required to have the `--<extension-type>-<extension-name>-` prefix.
|
|
447
|
+
- `appiumCliDest`: allows a schema to specify a custom property name in the post-`argprase` arguments objects. If not set, this becomes a camelCased string.
|
|
448
|
+
- `appiumCliDescription`: allows a schema to override the description of the argument when displayed on the command-line. This is useful paired with `appiumCliTransformer` (or `array`/`object`-typed properties), since there's a substantial difference between what a CLI-using user can provide vs. what a config-file-using user can provide.
|
|
449
|
+
- `appiumCliTransformer`: currently a choice between `csv` and `json`. These are custom functions which post-process a value. They are not used when loading & validating config files, but the idea should be that they result in the same object you'd get if you used whatever the config file wanted (e.g., an array of strings). `csv` is for comma-delimited strings and CSV files; `json` is for raw JSON strings and `.json` files.
|
|
450
|
+
- `appiumCliIgnore`: If `true`, do not support this property on the CLI.
|
|
451
|
+
- `appiumDeprecated`: If `true`, the property is considered "deprecated", and will be displayed as such to the user (e.g., in the `--help` output). Note the JSON Schema draft-2019-09 introduces a new keyword `deprecated` which we should use instead if upgrading to this metaschema. When doing so, `appiumDeprecated` should itself be marked as `deprecated`.
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
---
|
|
2
|
+
hide:
|
|
3
|
+
- toc
|
|
4
|
+
|
|
5
|
+
title: Developing Appium Extensions
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
Appium is built with a modular structure, which means that Appium extensions (drivers and plugins)
|
|
9
|
+
are decoupled from the main Appium module, and you only need to install the extensions that you
|
|
10
|
+
want to use. This modular structure also unlocks the ability to develop entirely new extensions!
|
|
11
|
+
|
|
12
|
+
This section of the Appium documentation is intended to help aspiring developers with creating their
|
|
13
|
+
own Appium extension:
|
|
14
|
+
|
|
15
|
+
* For creating a driver, see the [Build Drivers](./build-drivers.md) page
|
|
16
|
+
* For creating a plugin, take a look at the [Build Plugins](build-plugins.md) page
|
|
17
|
+
* Drivers and plugins both need documentation, so check out the [Build Documentation](./build-docs.md) page
|
|
18
|
+
* For creating a doctor check, see the [Building Doctor Checks](./build-doctor-checks.md) page
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
---
|
|
2
|
+
hide:
|
|
3
|
+
- toc
|
|
4
|
+
|
|
5
|
+
title: Masking Sensitive Log Data
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
Since Appium server version 2.18.0 there is a possibility to mask sensitive
|
|
9
|
+
values in logs. The below tutorial explains how to use this feature in third-party
|
|
10
|
+
extensions.
|
|
11
|
+
|
|
12
|
+
## Why It Might Be Useful
|
|
13
|
+
|
|
14
|
+
It is the right call to hide sensitive information, like passwords, tokens, etc.
|
|
15
|
+
from server logs, so it does not accidentally leak if these logs end up in wrong hands.
|
|
16
|
+
Appium server already provides a way to manipulate logs records via
|
|
17
|
+
[filtering](../guides/log-filters.md), although it has its own limitations.
|
|
18
|
+
The current approach is more sophisticated though, and requires some fine-tuning
|
|
19
|
+
on the driver/plugin side.
|
|
20
|
+
|
|
21
|
+
## How To
|
|
22
|
+
|
|
23
|
+
The assumption is that your extension uses the standard built-in
|
|
24
|
+
[@appium/logger](https://www.npmjs.com/package/@appium/logger).
|
|
25
|
+
In order to get some value in logs replaced by a generic mask it is necessary:
|
|
26
|
+
|
|
27
|
+
- Change the logging expression to wrap sensitive values and format them, for example:
|
|
28
|
+
|
|
29
|
+
```js
|
|
30
|
+
this.log.info(`Value: ${value}`);
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
becomes
|
|
34
|
+
|
|
35
|
+
```js
|
|
36
|
+
import {logger} from '@appium/support';
|
|
37
|
+
|
|
38
|
+
this.log.info('Value: %s', logger.markSensitive(value));
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
The formatting happens via the standard Node.js's
|
|
42
|
+
[util.format](https://nodejs.org/api/util.html#utilformatformat-args) API.
|
|
43
|
+
|
|
44
|
+
- While sending the appropriate server request, where this log line is used and should be masked,
|
|
45
|
+
add the custom header `X-Appium-Is-Sensitive` with its value set to `1` or `true` (case-insensitive).
|
|
46
|
+
Without such header the above log value is not going to be masked.
|
|
47
|
+
This way it is possible to conditionally mask log records depending on which
|
|
48
|
+
request is being handled by the extension if the log expression is used in the
|
|
49
|
+
common section.
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Appium Clients
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
You need a client to write and run Appium scripts. You'll want to become very
|
|
6
|
+
familiar with your client documentation (as well as the documentation of any Selenium client that
|
|
7
|
+
the Appium client depends on) since that will be your primary interface to Appium.
|
|
8
|
+
|
|
9
|
+
To learn more about clients, check out the [Client Intro](../intro/clients.md).
|
|
10
|
+
|
|
11
|
+
!!! note
|
|
12
|
+
|
|
13
|
+
If you maintain an Appium client that you would like to be listed here, feel free to create a PR!
|
|
14
|
+
|
|
15
|
+
## Official Clients
|
|
16
|
+
|
|
17
|
+
These clients are currently maintained by the Appium team:
|
|
18
|
+
|
|
19
|
+
### [Java Client](https://github.com/appium/java-client)
|
|
20
|
+
|
|
21
|
+
Language: :fontawesome-brands-java: Java
|
|
22
|
+
|
|
23
|
+
=== "Setup With Maven"
|
|
24
|
+
|
|
25
|
+
```xml
|
|
26
|
+
<dependency>
|
|
27
|
+
<groupId>io.appium</groupId>
|
|
28
|
+
<artifactId>java-client</artifactId>
|
|
29
|
+
<version>${version.you.require}</version>
|
|
30
|
+
<scope>test</scope>
|
|
31
|
+
</dependency>
|
|
32
|
+
```
|
|
33
|
+
=== "Setup With Gradle"
|
|
34
|
+
|
|
35
|
+
```groovy
|
|
36
|
+
dependencies {
|
|
37
|
+
testImplementation 'io.appium:java-client:${version.you.require}'
|
|
38
|
+
}
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### [Python Client](https://github.com/appium/python-client)
|
|
42
|
+
|
|
43
|
+
Language: :fontawesome-brands-python: Python
|
|
44
|
+
|
|
45
|
+
```sh title="Install From PyPi"
|
|
46
|
+
pip install Appium-Python-Client
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### [Ruby Core Client](https://github.com/appium/ruby_lib_core)
|
|
50
|
+
|
|
51
|
+
Language: :material-language-ruby: Ruby
|
|
52
|
+
|
|
53
|
+
```sh title="Install From RubyGems"
|
|
54
|
+
gem install appium_lib_core
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### [Ruby Client](https://github.com/appium/ruby_lib)
|
|
58
|
+
|
|
59
|
+
Language: :material-language-ruby: Ruby
|
|
60
|
+
|
|
61
|
+
This client is a wrapper for the Ruby Core Client with several helper methods, though this may
|
|
62
|
+
add additional complexity, therefore the Ruby Core Client is recommended instead.
|
|
63
|
+
|
|
64
|
+
```sh title="Install From RubyGems"
|
|
65
|
+
gem install appium_lib
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### [.NET Client](https://github.com/appium/dotnet-client)
|
|
69
|
+
|
|
70
|
+
Language: :simple-dotnet: C#
|
|
71
|
+
|
|
72
|
+
```sh title="Install Using .NET CLI"
|
|
73
|
+
dotnet add package Appium.WebDriver
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
## Other Clients
|
|
77
|
+
|
|
78
|
+
These clients are not maintained by the Appium team and can be used with other languages.
|
|
79
|
+
|
|
80
|
+
In general, any W3C WebDriver spec-compatible client will also integrate well with Appium, though
|
|
81
|
+
some Appium-specific commands may not be implemented in other clients.
|
|
82
|
+
|
|
83
|
+
### [WebdriverIO](https://webdriver.io/docs/appium)
|
|
84
|
+
|
|
85
|
+
Language: :material-language-javascript: :material-language-typescript: JavaScript/TypeScript
|
|
86
|
+
|
|
87
|
+
```sh title="Setup Using npm"
|
|
88
|
+
npm init wdio@latest .
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
### [Nightwatch.js](https://nightwatchjs.org/guide/mobile-app-testing/introduction.html)
|
|
92
|
+
|
|
93
|
+
Language: :material-language-javascript: :material-language-typescript: JavaScript/TypeScript
|
|
94
|
+
|
|
95
|
+
=== "Setup For Android"
|
|
96
|
+
|
|
97
|
+
```sh
|
|
98
|
+
npx @nightwatch/mobile-helper android --appium
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
=== "Setup For iOS"
|
|
102
|
+
|
|
103
|
+
```sh
|
|
104
|
+
npx @nightwatch/mobile-helper ios --appium
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
### [RobotFramework AppiumLibrary](https://github.com/serhatbolsu/robotframework-appiumlibrary)
|
|
108
|
+
|
|
109
|
+
Language: :simple-robotframework: Robot Framework
|
|
110
|
+
|
|
111
|
+
```sh title="Install From PyPi"
|
|
112
|
+
pip install robotframework-appiumlibrary
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
### [multicatch's appium-client](https://github.com/multicatch/appium-client)
|
|
116
|
+
|
|
117
|
+
Language: :simple-rust: Rust
|
|
118
|
+
|
|
119
|
+
```sh title="Install Using Cargo"
|
|
120
|
+
cargo add appium-client
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### [SwiftAppium](https://github.com/milcgroup/swiftappium)
|
|
124
|
+
|
|
125
|
+
Language: :material-language-swift: Swift
|
|
126
|
+
|
|
127
|
+
```sh title="Install and Setup"
|
|
128
|
+
git clone https://github.com/milcgroup/SwiftAppium.git
|
|
129
|
+
cd SwiftAppium
|
|
130
|
+
swift build
|
|
131
|
+
swift run swiftappium
|
|
132
|
+
```
|