Appium for Windows environment setup

Source: Internet
Author: User

Service Environment: 1installationNodejs

Download nodejs installation package (http://nodejs.org/download/) installation

Test installation succeeded: Run cmd, enter node-v

2installationAndroidof theSKD

Install android SDK run dependency   SDK ' Android ' Span style= "font-family: the song Body;" > tools. And make sure you install level17 or more versions   api

Set Android_home System Variables for your Android SDK path, and put Tools and the Platform-tools two directories added to the system Path path.

Variable: android_home

Value: D:\ANDROID-SDK

Setting: Path

Value:%android_home%\platform-tools;%android_home%\tools;

3installationApache Ant

Installing Apache Ant(http://ant.apache.org/bindownload.cgi)

Unzip the folder and add the path to the environment variable.

Variable: ant_home

Value: D:\apache-ant-1.8.2

Setting: Path

Value:%ant_home%\bin

Test the ant Environment for installation success: run cmd, enter ant, if not specified build.xml It will output:

Buildfile:build.xml does not exist!

Build failed

4 Installing the JDK

installation Jdk

Download the Unzip folder and set the M2home and M2 environment variables to add the M2 environment variable to your system the PATH variable.  

Variable: java_home

Value: C:\Program Files (x86) \java\jdk1.7.0_01

Variable: classpath

Value:%java_home%\lib;

Setting: Path

Value:%java_home%\bin;%java_home%\jre\bin;

test Environment installed successfully: Run cmd , enter java-version If successful, the Java information appears:

5 InstallationApache Maven

Installing Maven(http://maven.apache.org/download.cgi)

Download the Unzip folder and set the M2home and M2 environment variables to add the M2 environment variable to your system the PATH variable.  

Variable: maven_home

Value: D:\apache-maven-3.1.1

Settings: Path:

Value:%maven_home%\bin

test Environment installed successfully: Run cmd , enter mvn-v if it succeeds, it appears maven Information:

6 InstallationAppium

Install appiumusing npm .

in the cmd Use the command NPM install-g appium under the appium(the whole process is slow, please wait patiently) after the installation succeeds, the cmd input Appium The following message appears to indicate that the installation was successful:

At this point, theappium installation process is complete.

Operating Environment 1 installationMavenPlugins

To modify the maven Repository storage location:

Find maven under the conf under the settings.xml config file, mine is in D:\apache-maven-3.2.5\conf\settings.xml

The MAVEN repository defaults to the local user's temporary folder under the . M2 folder under repository , mine is in C: \ Users\admcnm\.m2\repository Directory,

Now let's modify to assign it to our own path, I'm now going to assign the repository to the D:\Repositories\Maven directory, just open the local repository that was logged off.

Then write the corresponding path value in it:

OK, first to experience maven, knock in cmd and enter to execute:mvn help:system

That's when maven downloads a whole bunch of stuff from the remote repository, it's okay, let it download, and sooner or later it's going to be downloaded,

the next step is to Eclipse installed in maven Plugins,

There are two of the most common ways that Eclipse installs plug-ins:
1. One is the online installation, which seems to be the most used,that is: Help-and installNew software, and then enter the HTTP address for installation, But there is one obvious drawback: it's slow! (Can be solved by FQ)
2. one is off-line installation, the way to install the link, this way can be better, can be plugged in and unplugged at any time, very convenient.

Eclipse Maven3 Installation:

1. use the first way to install who will, just enter the http address:http://m2eclipse.sonatype.org/sites/m2e, put the option on the hook, and then wait for it to download the installation, Restart Eclipse when you're done .
2. Here I do not say the above the kind of online installation, for two reasons: first, after installation is not good management ; Second, the download is too slow ; The next thing I'm going to say is to use Link Way to install offline Maven3 plugins.

The official website does not provide maven plug-in Offline installation package, general, you search on the Internet, lucky words should be able to find. I've compiled maven 's offline packages for people who need them to download,

Click here to download the link directly:http://115.com/file/dpk80gj0#eclipse-maven3-plugin.7z

Link installs eclipse maven plugin offline

2. Unzip the eclipse-maven3-plugin.7z downloaded from the Web to eclipse\dropins

After Eclipse 3.6, there's no need to write Link . just put the plugin you downloaded and put it under the eclipse\dropins .

For example: My Maven plugin directory:
D:\eclipse\dropins\maven\

Restart later Eclipse

Check that the maven plugin for Eclipse is installed successfully:Window--Preferences

To configure maven:
1. Click the Add button to select the path value of your native maven installation

2. Click the Browse button to select your maven setting.xml profile and click OK, this completes the configuration of the eclipse maven Plugin

Eclipse will help you automatically download the maven plugin jar package and wait patiently

Run Tests

1. connect the phone or launch the android emulator.

2. start appium in cmd

3. open a different cmd terminal window. Switch to the instance code path

4. Run MVN test for project construction you can see the value output in the appium Terminal window and start running the script on the emulator or phone.

5. done.

Appium for Windows environment setup

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.