基于WDA实现ios的ui自动化/monkey

环境部署

1.carthage

brew直接能装,不需要用git的源码编

brew install carthage

2.facebook的wda

git上下载源码:https://github.com/facebook/WebDriverAgent

运行初始化脚本:sh /Script/bootstrap.sh

3.wda的python库

pip直接装

pip install facebook-wda

UI通信

1.启动UI web driver

xcodebuild -project WebDriverAgent.xcodeproj -scheme WebDriverAgentRunner -destination 'platform=iOS Simulator,name=iPhone 6' test

2.python脚本与web driver通信

#coding:utf-8

import wda

c = wda.Client(‘http://localhost:8100’)

print c.status()

c.home()

你可能感兴趣的:(基于WDA实现ios的ui自动化/monkey)