Skip to content
UI Automation Framework for Games and Apps
Branch: master
Clone or download
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github/ISSUE_TEMPLATE add issue template Sep 19, 2018
airtest closes #271, 去掉了swipe时的一次多余的坐标转换,让部分三星机型滑动操作恢复正常 Feb 21, 2019
docs add supported platforms overview Feb 13, 2019
playground fix script & log dir settings Feb 13, 2019
tests 新增一个在yosemite输入法中,输入EDITOR CODE的接口 Jan 16, 2019
.gitattributes add android/static into linguist-vendored Mar 26, 2018
.gitignore use public links in docs Jan 31, 2018
LICENSE opensource init version Jan 24, 2018 opensource init version Jan 24, 2018 update readme Feb 14, 2019
requirements.txt 更新contrib version版本(测试正常) Oct 12, 2018 use public links in docs Jan 31, 2018 level up to 1.0.26 Feb 13, 2019

Airtest · Build status

Cross-Platform UI Automation Framework for Games and Apps




  • Write Once, Run Anywhere: Airtest provides cross-platform APIs, including app installation, simulated input, assertion and so forth. Airtest uses image recognition technology to locate UI elements, so that you can automate games and apps without injecting any code.

  • Fully Scalable: Airtest cases can be easily run on large device farms, using commandline or python API. HTML reports with detailed info and screen recording allow you to quickly locate failure points. NetEase builds Airlab on top of Airtest Project.

  • AirtestIDE: AirtestIDE is an out of the box GUI tool that helps to create and run cases in a user-friendly way. AirtestIDE supports a complete automation workflow: create -> run -> report.

  • Poco: Poco adds the ability to directly access object(UI widget) hierarchy across the major platforms and game engines. it allows writing instructions in Python, to achieve more advanced automation.

Get started from airtest homepage and find support in google groups

Supported Platforms

Android Emulator iOS Windows Unity Cocos2dx Egret WeChat


Use pip to install Airtest python library.

pip install -U airtest

On MacOS/Linux platform, you need to grant adb execute permission.

# for mac
cd {your_python_path}/site-packages/airtest/core/android/static/adb/mac
# for linux
# cd {your_python_path}/site-packages/airtest/core/android/static/adb/linux
chmod +x adb

Download AirtestIDE from our homepage if you need to use the GUI tool.


You can find the complete Airtest documentation on readthedocs.


Airtest aims at providing platform independent API, so that you can write automated cases once and run it on multiple devices and platforms.

  1. Using connect_device API you can connect to any android/iOS device or windows application.
  2. Then perform simulated input to automate your game or app.
  3. DO NOT forget to make assertions of the expected result.
from airtest.core.api import *

# connect an android phone with adb
# or use connect_device api
# connect_device("Android:///")

swipe(Template("slide_start.png"), Template("slide_end.png"))

For more detailed info, please refer to Airtest Python API reference or take a look at API code

Running .air cases from CLI

Using AirtestIDE, you can easily create automated cases as .air directories. Airtest CLI provides the possibility to execute cases on different host machine and target device platforms without using AirtestIDE itself.

# run cases targeting on Android phone connected to your host machine via ADB
airtest run "path to your .air dir" --device Android:///

# run cases targeting on Windows application whose title matches Unity.*
airtest run "path to your .air dir" --device "Windows:///?title_re=Unity.*"

# generate HTML report after running cases
airtest report "path to your .air dir"

# or use as python module
python -m airtest run "path to your .air dir" --device Android:///

Try running provided example case: airtest/playground/test_blackjack.air and see Usage of CLI. Here is a multi-device runner sample.


Pull requests are very welcome. Help needed here


Thanks for all these great works that make this project better.

You can’t perform that action at this time.