官术网_书友最值得收藏!

  • Appium Essentials
  • Manoj Hans
  • 209字
  • 2021-07-23 19:27:10

Conventions

In this book, you will find a number of styles of text that distinguish between different kinds of information. Here are some examples of these styles, and an explanation of their meaning.

Code words in text are shown as follows: "After installation, run the command appium-doctor to ensure that we are ready with Appium."

A block of code is set as follows:

@BeforeClass
public void setUp() throws MalformedURLException{
  //Set up desired capabilities
  DesiredCapabilities caps = new DesiredCapabilities();
  File app=new File("path of the apk");
  caps.setCapability(MobileCapabilityType.APP,app);
  caps.setCapability(MobileCapabilityType.PLATFORM_VERSION, "4.4");
  caps.setCapability(MobileCapabilityType.PLATFORM_NAME, "Android");
  caps.setCapability(MobileCapabilityType.DEVICE_NAME, "Android emulator");
  caps.setCapability("avd","Name of the AVD to launch");
  caps.setCapability(MobileCapabilityType.APP_PACKAGE, "package name of your app (you can get it from apk info app)");
  caps.setCapability(MobileCapabilityType.APP_ACTIVITY, "Launch activity of your app (you can get it from apk info app)");
  caps.setCapability(MobileCapabilityType.BROWSER_NAME, "Browser");
  // In case of web-apps
  driver = new AndroidDriver (new URL("http://127.0.0.1:4723/wd/hub"), caps);
  driver.manage().timeouts().implicitlyWait(30,TimeUnit.SECONDS);
}

Any command-line input or output is written as follows:

android create avd –n <name of the AVD> -t <targetID>

New terms and important words are shown in bold. Words that you see on the screen, in menus or dialog boxes for example, appear in the text like this: "Click on Advanced system settings."

Note

Warnings or important notes appear in a box like this.

Tip

Tips and tricks appear like this.

主站蜘蛛池模板: 陆丰市| 卓尼县| 崇信县| 厦门市| 鹰潭市| 胶州市| 景洪市| 亚东县| 天全县| 平山县| 八宿县| 丹江口市| 泰安市| 静乐县| 华阴市| 苍梧县| 郸城县| 新郑市| 观塘区| 南充市| 深圳市| 浦江县| 石景山区| 忻州市| 望城县| 东辽县| 门源| 茌平县| 龙井市| 盐源县| 平凉市| 壶关县| 广昌县| 紫云| 五大连池市| 天水市| 茂名市| 北海市| 石狮市| 江北区| 楚雄市|