当前位置:网站首页>App自动化测试开元平台Appium-runner
App自动化测试开元平台Appium-runner
2022-07-01 13:29:00 【qq_492448446】
Appium Runner 自动化测试工具封装
https://github.com/crazyFeng/appium-runner
只需要你会用excel,就能够实现自动化测试,提高工作效率
安装方式
pip仓库安装
pip install appiumrunner
源码安装
python setup.py install --user
检查是否安装成功,输入appiumrun
使用步骤
编写excel
编写 yaml 配置文件
运行自动化测试
检查测试报告
yaml文件的内容如下所示:
excel_file: D:\work\course\test\platform\app_framework\data\case.xls
username: "张三"
projectname: "读书屋项目"
title: "自动化测试报告"
appium_url: "http://192.168.1.179:4723/wd/hub"
appium_run_info:
deviceName: "emulator-5554"
platformName: "Android"
platformVersion: "5.1.1"
appPackage: "com.tencent.mobileqq"
appActivity: ".activity.SplashActivity"

excel文件分为两个sheet,一个为data,另一个为login,里面是操作的步骤
data数据:
| login | {'time':10,'username':'1111','password':'2222'} | {'time':10,'username':'22222','password':'2222'} |
| regist | {'time':10,'conf1':'1111','conf':'2222'} | {'time':10,'conf1':'1111','conf':'2222'} |
login 的数据:
| 操作id | 步骤描述 | 动作 | 定位方式 | 定位值 | 多元素下标 | 校验值来源 | 属性名 | 校验方式 | 数据项 |
| case_setp1 | 点击弹窗同意按钮 | click | find_element_by_id | com.android.packageinstaller:id/permission_allow_button | |||||
| case_setp2 | 点击弹窗同意按钮 | click | find_element_by_id | com.android.packageinstaller:id/permission_allow_button | |||||
| case_setp3 | 等待页面加载 | wait | time | ||||||
| case_setp4 | 点击弹窗同意按钮 | click | find_element_by_xpath | //android.widget.TextView[@content-desc="同意"] | |||||
| case_setp5 | 点击登录按钮 | click | find_element_by_id | com.tencent.mobileqq:id/btn_login | |||||
| case_setp6 | 点击用户名输入 | send_keys | find_element_by_xpath | //android.widget.EditText[@content-desc="请输入QQ号码或手机或邮箱"] | username | ||||
| case_setp7 | 点击密码输入 | send_keys | find_element_by_id | com.tencent.mobileqq:id/password | password | ||||
| case_setp8 | 登录成功 | click | find_element_by_id | com.tencent.mobileqq:id/login | |||||
| case_setp9 | 关闭应用 | end |
如何启动自动化:
找打config.yaml文件所在路径,然后执行 appiumrun --config=config.yaml
边栏推荐
- 啟動solr報錯The stack size specified is too small,Specify at least 328k
- 6. Wiper part
- SAP 智能机器人流程自动化(iRPA)解决方案分享
- Spark source code reading outline
- String input function
- 内容审计技术
- 1.8 new features list
- 陈宇(Aqua)-安全->云安全->多云安全
- 04 redis source code data structure dictionary
- Shangtang technology crash: a script written at the time of IPO
猜你喜欢

【机器学习】VAE变分自编码器学习笔记

Explain IO multiplexing, select, poll, epoll in detail

Etcd 概要 机制 和使用场景

啟動solr報錯The stack size specified is too small,Specify at least 328k

Interpretation of R & D effectiveness measurement framework

开源者的自我修养|为 ShardingSphere 贡献了千万行代码的程序员,后来当了 CEO

Fiori 应用通过 Adaptation Project 的增强方式分享
Reasons for MySQL reporting 1040too many connections and Solutions

一款Flutter版的记事本

学会使用LiveData和ViewModel,我相信会让你在写业务时变得轻松
随机推荐
10. Page layout, guess you like it
陈宇(Aqua)-安全->云安全->多云安全
ArrayList capacity expansion mechanism and thread safety
Summary of 20 practical typescript single line codes
一文读懂TDengine的窗口查询功能
Several models of IO blocking, non blocking, IO multiplexing, signal driven and asynchronous IO
Research Report on China's software outsourcing industry investment strategy and the 14th five year plan Ⓡ 2022 ~ 2028
Chen Yu (Aqua) - Safety - & gt; Cloud Security - & gt; Multicloud security
What is the future development direction of people with ordinary education, appearance and family background? The career planning after 00 has been made clear
04 redis source code data structure dictionary
Jenkins+webhooks- multi branch parametric construction-
Interpretation of R & D effectiveness measurement framework
网络中的listen
Analysis report on production and marketing demand and investment forecast of global and Chinese diamond powder industry Ⓤ 2022 ~ 2027
Machine learning summary (I): linear regression, ridge regression, Lasso regression
Shangtang technology crash: a script written at the time of IPO
Applet - multiple text line breaks in view
Camp division of common PLC programming software
Analysis report on the development trend and prospect scale of silicon intermediary industry in the world and China Ⓩ 2022 ~ 2027
Applet - applet chart Library (F2 chart Library)