Appium 1.6.5安装

Download and Install Appium 1.6.5 (updated)

September 6,2017 by anish 6 Comments

If you have been working on Appium orhave been actively following Appium updates, then you might be aware that anewer version of Appium was released in October 2016 (Appium v 1.6.0). Thislatest release was an important milestone because it added support for new iOSand Android frameworks and it also introduced support for Windows desktopapplications and You.i TV. In this article, we will provide detailed step bystep guide for Appium installation using which you will be able to download andinstall Appium’s latest version (version 1.6.5 in this case).

The latest version of Appium is Appium1.6.5 (which was released on 26th May 2017). However, you can use this articlefor both Appium 1.6.4 and Appium 1.6.3. The steps would remain the same (thecontent in the screenshots might be bit different based on what version you areusing)

Are you looking for complete Appiumsetup from scratch? Use our step by stepAppium Tutorial to setup all the tools, inspectelements on your mobile app and write your first test script.

Update [01 June, 2017]: Appium 1.6.5 isnow available in GUI form as well. Check out our Appium Desktop app article for details

Before we begin, please note that thisarticle doesn’t cover the entire Appium setup from scratch, using which you canstart automation of your test scripts (the entire setup is covered in our Appium tutorial series, as mentioned in the yellowbox above). This article just covers the download and setup of Appium1.6.3/Appium 1.6.4/Appium 1.6.5 on a Windows machine.

Why download or upgrade to Appium 1.6?

If you are new to Appium and downloadingit for the first time, or if you are already working on some previous versionsof Appium, then you would be wondering why you should switch to the latestversion of Appium rather than sticking with older versions some of which comewith GUIs as well. Well, the most important reason to use the latestversion of Appium is that it supports newer versions of iOS and Android.Appium1.6.5 fixes multiple issues with the previous versions of Appium & supportsiOS 10.3 and Android 7.1 (Nougat). So if your device or emulator uses any ofthese latest versions, then you have to switch to Appium 1.6’s latest version.Other than this, the newer version of Appium provides –

·        XCUITest support for iOS 9.3 and iOS 10

·        UI Automator 2 support for Android

·        support for Windows desktop applications and You.i TV

·        … and many other improvements and bug fixes

Different ways in which you can downloadand setup Appium

A very important thing to keep in mindabout Appium versions is that they come in 2 different flavors – some Appiumversions are GUI based and some are non-GUI based (ie operated from commandprompt). If youhave worked with Appium 1.6.3 or the versions before that, then you would haveobserved that all the Appium versions were not GUI based. Only few Appiumserver versions were GUI based, and to work with the rest of them, you wouldhave had to use command prompt or Node js.

Fortunately, this is not the case anymore. Starting from Appium 1.6.4 beta, all the Appium versions have had a GUIversion well.

Installing Appium 1.6.5/1.6.4 or anyNon-GUI version of Appium

Installation of non-GUI version ofAppium is a 2 step process. The first step is to install Node.JS. The secondstep is to use Node.JS to install Appium.

Let’s have a look at each of these stepsin detail.

Step 1 – Download and Install Node.JS

Follow the steps given below to downloadand install Node.JS. If you have already installed Node.JS, then you can skipthis and move to the next section.

1. Open Node.JS website using this link– https://nodejs.org/

2. Click on the LTS version’s link todownload the latest version.

Note: The screenshots are shown for thelatest version (v6.11.0, as on 28 June 2017). Even if you want to download someother version, please go ahead and do it. The steps given below would remainthe same, even though the screenshot content might change a bit.

3. Click on Save File tosave the msi file on your machine

4. Open the msi file to start theinstallation process

5. Click on Next button, accept the LicenseAgreement, select default values in all the screens to install Node.JS.

6. The installation would proceed as shownbelow. Once its complete, click on Finish button

7. To verify that the installation wassuccessful, open Start menu. You will see a folder for Node.js. Expand thefolder and check that it shows Node.js and Node.js command prompt among otherthings. This shows that your installation is successful

This completes the process of downloadand installation of Node.js. Let’s now check the steps on how to installAppium.

Step 2 – Install Appium using Node.js

Unlike Node.js, we don’t have todownload Appium first to install it. We will just run the command in Node.js,and it will automatically download and install Appium. Let’s see how this isdone –

1. Go to Start menu > My Programs >Node.js folder and open Node.js command prompt.

2. Once you have opened the command prompt,you have to just provide the command to install Appium. There are 2 differentvariations in which you can provide this command –

·        Variation 1 : Install the latest version of Appium– With thisapproach, Node.js will always install the latest version. The command that youcan use for this is –npm install -g appium

·        Variation 2 : Install a specific Appium version – Here, you can install any version ofAppium. To do this you will have to provide the version number of Appiumtogether with the command we mentioned above. Suppose, you want to installversion 1.6.0, then the command that you will use is – npm install -gappium@1.6.0

Since we will be installing the latestversion of Appium, we will use variation 1

3. In Node.js command prompt, type thiscommand – npm install -g appium and hit Enter

4. Once you hit Enter, you will see thatNode will start installing Appium (you might have to wait a few seconds to seethe actual installation happening). Some screenshots of the installation stepsare given below –

NPM adding few dependencies for Appium…

5. Once the installation is complete, youwill see that command prompt screen as shown in the below screenshot

6. As a last step, to check that Appium(and that too it’s latest version) has been installed, run this command : appium-v

In the above image, you can see thatrunning Appium -v command shows the version number as 1.6.5.This confirms that the latest version of Appium has been successfully installedon your machine.

Starting Appium server from CommandPrompt

Since you have downloaded a non-GUIversion of Appium, the only way you can start the server is through commandprompt. You can either use the default windows command prompt or the Node.jscommand prompt, which we used in the previous section to install Appium.

Once you open command prompt, you cansimply run command – Appium, which will start the Appium server asshown in the below image. Please note that this command starts Appium on thedefault address and port which is 0.0.0.0:4723

If you want to run Appium on a specificserver and port of your choice, then you can provide it with the command like this– appium -a 127.0.0.1 -p 4723. This command starts appium server onaddress 127.0.0.1

Stopping the Appium server

Stopping of the Appium server is a twostep process as mentioned below –

1. In the command prompt window, press thekeys Ctrl and C. This will show the Terminatebatch job(Y/N) message as shown below

2. Press ‘Y’ and then hit enter. This wouldstop the Appium server


This completes the article on downloading and installing non GUI version ofAppium 1.6.x. Let us know if you found this article helpful and the steps easyto understand. Your feedback would help us improve our content and make it moreuseful for all our readers.

Related: If you use the non-GUI version ofAppium, then you would also be interested in learning how you can start andstop Appium server from Java. Have a look at this article for complete details– Start and StopAppium server from Java

From: http://www.automationtestinghub.com/download-and-install-appium-1-6/

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
Appium是一个开源的自动化测试框架,主要用于移动应用的测试,支持iOS和Android平台。以下是Appium的基本安装步骤: 1. **安装Node.js**: Appium需要Node.js环境,首先确保你已经安装了最新版本的Node.js。你可以访问https://nodejs.org/ 下载并安装。 2. **选择平台版本**: 根据你的目标设备(iOS或Android),确定相应的Appium版本。Appium有两个主要分支:Appium Desktop(适用于Mac和Windows)和Appium Server(适用于服务器环境)。 - 对于Mac或Windows用户,推荐使用Appium Desktop,它包含了自动化测试工具和模拟器/真实设备连接功能。 - 对于服务器环境,你需要单独安装Appium Server,并且可能需要安装对应的SDK(Xcode或Android SDK)。 3. **安装Appium Desktop (仅限Mac/Windows)**: 访问Appium官网的Download页面(https://appium.io/downloads/),下载对应平台的Appium Desktop安装包,然后按照向导进行安装。 4. **安装Appium Server (服务器环境)**: 在命令行中运行 `npm install -g appium` 来全局安装Appium。如果你需要安装特定版本,可以指定版本号如 `npm install -g appium@1.19.0`。 5. **启动Appium Server**: 在安装完成后,运行 `appium` 命令启动服务器。首次启动时,可能需要配置一些参数,比如选择合适的设备或模拟器。 6. **验证安装**: 可以通过Appium的HTTP API进行测试,打开浏览器访问 `http://localhost:4723/wd/hub`,如果一切正常,应该能看到Appium的欢迎信息。 相关问题: 1. Appium支持哪些操作系统? 2. Appium Server的启动命令是什么? 3. 如何通过Appium测试我的移动应用?
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值