What is automated testing? Automated testing refers to the automation of software testing, which is to run a system or application under a predetermined condition, evaluate the results of the operation, and pre-conditions should include both normal and abnormal conditions. Automated testing is the process of translating a man-driven test behavior into a machine execution.
The automated testing tools that were originally used in Android development are not monkey. The reasons for using Monkey are as follows:
Monkey is Andriod's own tool.
The use of monkey is relatively simple (less command line)
The tool for stress testing monkey is more useful
Of course, Monkey also has a lot of shortcomings:
The events sent by the monkey are random (ps it is like a monkey on the keyboard disorderly dot)
Therefore, monkey is also only suitable for use as a stress test, in the development process, the timely discovery of some of the problems in the project, such as ANR, so as to improve our development efficiency.
Recently, I was learning monkey, in the internet also collected a lot of information, but found that really useful and systematic tutorial really not many, so I will collect their own information to add their own understanding, write here, to facilitate more people's study. Environment Configuration
Each software use up, can not escape the link, the first to put your software environment configuration, but, we have said, Monkey is the Andriod SDK comes with the tool, what does that mean? That is, as long as your SDK configuration is not a problem, Your monkey tool is basically no problem, whether you are using Eclipse or Andriod studio which does not affect your use, is it more exciting?
First we need to check whether the configuration is successful, if the configuration is successful, the following interface will appear, also if the configuration is a problem, then you need to check the path of your SDK and the path of the JDK is correct. (The use of PS Eclipse and Andriod Studio is the same)
1. Download the SDK for Windows decompression: android-sdk-windows to D: Packing directory
2. Set environment variables for tools under SDK
Right-click Computer-Properties-Advanced system settings-environment variables-" br> Click Path, add "D:\android-sdk-windows\platform-tools" to the variable value, separated from the previous variable value with ";".
3. Download the installation JDK, click Install after the download is complete, and install it by default
4. Platforms exists no need to read (if the SDK cannot download platforms automatically, manually download Android SDK 2.1, will android-2.1_ R01-windows.zip file is extracted and placed to android-sdk-windows\platforms)