Viewing the log is an important part of the code that we can debug directly when we test it on the editor, but the program runs automatically when it is continuously integrated, and if a bug occurs, the code location can only be located by logging. Appium logs are mainly divided into three parts.
1. The preparation phase includes the Appium launch and the pre-launch of the app.
2. The control stage includes the execution of the test cases such as app launch and element manipulation.
3. Close the stage, close the Appium, clear the session and other finishing tasks
First, the preparatory stage
These lines of log indicate that the Appium started successfully and that the log output level is Debug.
These lines are to collect our key-value pairs, test the language and version of the code used, get the APK information, our example does not have an apk, so can not get to, will be running on the device to get app information.
These lines indicate that our code is connected to the Appium server. Use the JDK version, ADB location, apk info.
This section of the log shows the process of appium finding a phone.
This paragraph is to start the log monitoring, and then the mobile phone operation, such as querying the phone version, delete the previous automated legacy information, the need to upload the program to the mobile phone, install the required setting and unlock programs.
Second, the control phase
Starting with this paragraph is the process of starting the app, shutting down all uiautomator processes first, and then running Appiumbootstrap.
Locate the element and click on the My button.
Click on the element.
Third, closing phase
This paragraph is to turn off mobile app and log monitoring.
This paragraph is to close Uiautomator, clean up data and session.
Appium-appium Log Analysis