Desired Capabilities are keys and values encoded in a JSON object, sent by Appium clients to the server when a new automation sessionis requested.

They tell the Appium drivers all kinds of important things abouthow you want your test to work.

Each Appium client builds capabilities in a wayspecific to the client's language, but at the end of the day, they are sent over to Appium as JSON objects.

There are many, many Capabilities that Appium supports.Capabilities also differ by driver, though there are a standard set that mostdrivers pay attention to.

What follows are a series of tables outlining thevarious Desired Capabilities available in general and for specific drivers.

===========================================================

General Capabilities

These Capabilities span multiple drivers.

automationName

Which  automation engine to use

Appium  (default) or Selendroid or UiAutomator2 or Espresso for Android or XCUITest  for iOS or YouiEngine for application built with You.i Engine

platformName

Which mobile OS  platform to use

iOS, Android,  or FirefoxOS

platformVersion

Mobile OS version

e.g., 7.1, 4.4

deviceName

The kind of  mobile device or emulator to use

iPhone  Simulator, iPad Simulator, iPhone Retina 4-inch, Android Emulator, Galaxy S4,  etc.... On iOS, this should be one of the valid devices returned by  instruments with instruments -s devices. On Android this capability is  currently ignored, though it remains required.

app

The absolute  local path or remote http URL  to a .ipa file (IOS), .app folder (IOS Simulator), .apk file (Android) or  .apks file (Android App Bundle), or a .zip file containing one of these (for  .app, the .app folder must be the root of the zip file). Appium will attempt  to install this app binary on the appropriate device first. Note that this  capability is not required for Android if you specify appPackage and  appActivity capabilities (see below). Incompatible with browserName. See here  about .apks file.

/abs/path/to/my.apk  or http://myapp.com/app.ipa

browserName

Name of mobile  web browser to automate. Should be an empty string if automating an app  instead.

'Safari' for  iOS and 'Chrome', 'Chromium', or 'Browser' for Android

newCommandTimeout

How long (in  seconds) Appium will wait for a new command from the client before assuming  the client quit and ending the session

e.g. 60

language

Language to set  for iOS and Android. It is only available for simulator on iOS

e.g. fr

locale

Locale to set  for iOS and Android. It is only available for simulator on iOS. fr_CA format  for iOS. CA format (country name abbreviation) for Android

e.g. fr_CA, CA

udid

Unique device  identifier of the connected physical device

e.g. 1ae203187fc012g

orientation

(Sim/Emu-only)  start in a certain orientation

LANDSCAPE or  PORTRAIT

autoWebview

Move directly  into Webview context. Default false

true, false

noReset

Don't reset app  state before this session. See here  for more details

true, false

fullReset

Perform a  complete reset. See here  for more details

true, false

eventTimings

Enable or  disable the reporting of the timings for various Appium-internal events  (e.g., the start and end of each command, etc.). Defaults to false. To  enable, use true. The timings are then reported as events property on  response to querying the current session. See the event  timing docs for the the structure of this response.

e.g., true

enablePerformanceLogging

(Web and  webview only) Enable Chromedriver's (on Android) or Safari's (on iOS)  performance logging (default false)

true, false

printPageSourceOnFindFailure

When a find  operation fails, print the current page source. Defaults to false.

e.g., true

Appium Desired Capabilities-General Capabilities的更多相关文章

  1. Appium Desired Capabilities

    Appium Desired Capabilities Desired Capabilities 是由 keys 和 values 组成的 JSON 对象. 举个简单例子: { "platf ...

  2. Appium Desired Capabilities-iOS Only

    Appium Desired Capabilities-iOS Only These Capabilities are available only on the XCUITest Driver an ...

  3. Appium Desired Capabilities信息配置

    编写APPium脚本,必须要配置Desired Capabilities信息 Desired Capabilities 在启动 session 的时候是必须提供的. Desired Capabilit ...

  4. Appium自动化(4) - Appium Desired Capabilities 参数详解

    如果你还想从头学起Appium,可以看看这个系列的文章哦! https://www.cnblogs.com/poloyy/category/1693896.html Desired Capabilit ...

  5. Appium Desired Capabilities-Android Only

    Android Only These Capabilities are available only on Android-baseddrivers (like UiAutomator2for exa ...

  6. appium Capabilities的各个标签

    今天详解一下Capabilities的各个标签,以后如果用得着可以随时翻阅. General Capabilities 标签 概述 值 automationName 使用引擎 默认为Appium,其中 ...

  7. 五 Android Capabilities讲解

    1.Capabilities介绍 可以看下之前代码里面设置的capabilities DesiredCapabilities capabilities = new DesiredCapabilitie ...

  8. Capabilities & ChromeOptions

    https://sites.google.com/a/chromium.org/chromedriver/capabilities http://stackoverflow.com/questions ...

  9. 四 Android Capabilities讲解

    本文转自:http://www.cnblogs.com/sundalian/p/5629429.html Android Capabilities讲解   1.Capabilities介绍 可以看下之 ...

随机推荐

  1. 经典卷积神经网络——AlexNet

    一.网络结构 AlexNet由5层卷积层和3层全连接层组成. 论文中是把网络放在两个GPU上进行,为了方便我们仅考虑一个GPU的情况. 上图中的输入是224×224224×224,不过经过计算(224 ...

  2. Charles系列一:Charles功能介绍、下载安装和界面简介

    一:Charles主要功能介绍 Charles是一个HTTP代理/HTTP监视器/反向代理,使开发和测试人员能够查看机器和Internet之间所有的HTTP和SSL/HTTPS流量,这包括请求,响应. ...

  3. 第3课.进化后的const

    1.c语言中 const修饰的变量是只读的,本质上还是变量 const修饰的局部变量在栈上分配空间(因为在栈上分配空间,所以我们可以通过改变这个空间的值.间接去改变这个变量.) const修饰的全局变 ...

  4. vue用echarts 画3d地球 且画线

    页面效果如下: 项目结构如下: 引入的包 "dependencies": { "core-js": "^3.3.2", "regi ...

  5. Mybatis插件之Mybatis-Plus的CRUD方法

    使用Mybatis-plus进行基本的CRUD(增查改删)操作. 实体类(User)代码: import com.baomidou.mybatisplus.annotation.IdType; imp ...

  6. poj2486 Apple Tree (树形dp+分组背包)

    题目链接:https://vjudge.net/problem/POJ-2486 题意:一棵点权树,起点在1,求最多经过m条边的最大点权和. 思路: 树形dp经典题.用3维状态,dp[u][j][0/ ...

  7. mybatis+mysql insert添加数据后返回数据主键id

    1.根据useGeneratedKeys获取返回值,部分数据库不支持 修改mybatis xml <insert id="insertUser" useGeneratedKe ...

  8. 【AI】【人工智能】【计算机】人工智能工程技术人员等职业信息公示

    人社厅发[2019]48号 各省.自治区.直辖市及新疆生产建设兵团人力资源社会保障厅(局).市场监管局.统计局,国务院各部门.各直属机构.各中央企业.有关社会组织人事劳动保障工作机构,中央军委政治工作 ...

  9. IDEA插件之JProfiler

    1.是什么?来用干嘛的? 一个商业授权的Java剖析工具. 用来剖析程序内存.CPU使用情况,找到性能瓶颈,快速定位问题所在. 2.IDEA安装JProfiler插件 (1)File -> Se ...

  10. c# bitmap的拷贝及一个图像工具类

    using (Bitmap bmp = new Bitmap(scanImgPath)) { Bitmap bitmap = new Bitmap(bmp.Width, bmp.Height, Pix ...