- 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."
推薦閱讀
- C++面向?qū)ο蟪绦蛟O計(第三版)
- 軟件項目估算
- Microsoft Application Virtualization Cookbook
- Arduino by Example
- Effective C#:改善C#代碼的50個有效方法(原書第3版)
- 數(shù)據(jù)結(jié)構(gòu)(Python語言描述)(第2版)
- Responsive Web Design by Example
- Angular開發(fā)入門與實戰(zhàn)
- PLC應用技術(三菱FX2N系列)
- C++反匯編與逆向分析技術揭秘(第2版)
- ExtJS Web應用程序開發(fā)指南第2版
- 汽車人機交互界面整合設計
- 貫通Tomcat開發(fā)
- Java 9:Building Robust Modular Applications
- 小學生C++趣味編程從入門到精通