zoukankan      html  css  js  c++  java
  • Settings

    Settings

    Settings are a new concept introduced by appium. They are currently not a part of the Mobile JSON Wire Protocol, or the Webdriver spec.

    Settings are a way to specify the behavior of the appium server.//Settings是appium创造的一个新概念,不是Mobile JSON Wire 协议或者Webdriver的一部分。

    Settings are: - Mutable, they can be changed during a session - Only relevant during the session they are applied. They are reset for each new session. - Control the way the appium server behaves during test automation. They do not apply to controlling the app or device under test.//建立一个session后,Settings是按照需要可以改变的。Settings只影响appium server的行为,不影响被测试的app和设备。

    An example of a setting would be ignoreUnimportantViews for Android. Android can be set to ignore elements in the View Hierarchy which it deems irrelevant. Setting this can cause tests to run faster. A user who wants to access the ignored elements however, would want to disable ignoreUnimportantViews, and reenable it afterwards.

    Another example of a use-case for settings would be telling appium to ignore elements which are not visible.

    Settings are implemented via the following API endpoints://通过下面的api实现。

    POST /session/:sessionId/appium/settings

    Expects a JSON hash of settings, where keys correspond to setting names, and values to the value of the setting. { settings: { ignoreUnimportantViews : true } }

    GET /session/:sessionId/appium/settings

    Returns a JSON hash of all the currently specified settings. { ignoreUnimportantViews : true }

     

    Supported Settings

    “ignoreUnimportantViews” - Boolean which sets whether Android devices should use setCompressedLayoutHeirarchy() which ignores all views which are marked IMPORTANT_FOR_ACCESSIBILITY_NO or IMPORTANT_FOR_ACCESSIBILITY_AUTO (and have been deemed not important by the system), in an attempt to make things less confusing or faster.

    Android UiAutomator Configurator

    sets UiAutomator Configurator timeouts and delays in Android devices. only works in Android API 18 and above.

    “actionAcknowledgmentTimeout” - Int which is the same as setActionAcknowledgmentTimeout. If a negative value is given, it would set to default(3 * 1000 milliseconds)

    “keyInjectionDelay” - Int which is the same as setKeyInjectionDelay. If a negative value is given, it would set to default(0 milliseconds)

    “scrollAcknowledgmentTimeout” - Int which is the same as setScrollAcknowledgmentTimeout. If a negative value is given, it would set to default(200 milliseconds)

    “waitForIdleTimeout” - Int which is the same as setWaitForIdleTimeout. If a negative value is given, it would set to default(10 * 1000 milliseconds)

    “waitForSelectorTimeout” - Int which is the same as setWaitForSelectorTimeout. If a negative value is given, it would set to default(10 * 1000 milliseconds)

  • 相关阅读:
    关于打开MTK_SDCARD_SWAP 宏后MTK目前升级方案和 关于打开MTK_SHARED_SDCARD宏后MTK目前升级方案
    报表填报时,如何实现多个单元格绑定一个字段?
    双4G LTE
    报表移动端如何进行移动设备绑定与撤销
    各种卡的一些信息积累
    广佛肇城轨年内通车 佛山西站预计2017年中通车
    Web报表页面如何传递中文参数
    根据条件控制参数控件是否显示(可用)
    如何对报表的参数控件赋值
    Jquery前端分页插件pagination同步加载和异步加载
  • 原文地址:https://www.cnblogs.com/superbaby11/p/6073592.html
Copyright © 2011-2022 走看看