多设备兼容性

适配系统

android 现在基本适配:6.0,7.0,8.0,9.0
ios 适配 iphone 和 ipad 基本不适配7.x 和 8.x 系统

兼容性带来的质量问题:

  • 平台特性
    • 安装不上
  • 功能可用性
    • crash
    • 业务流程中断
    • 尺寸错乱
    • 告警和报错
  • 用户体验与性能
    • 卡顿/响应慢
    • 游戏测试时花屏/黑屏/白屏
      (各品牌设备按理说应该是全部需要测试的,因为底层的ROM和芯片被改变)

兼容性测试技术

控制中心:负责分配任务,任务调度
中控机:比如ubantu连接n多台手机,使用硬件设备:USB Hub
通常是这种方式:控制中心连接pc机,每个PC机连接n台手机来控制
在这里插入图片描述
jenkins作为调度平台,调度pc机,使用monkey、maxim、appcrawler、appium来驱动

安装 STF

1 条件

  • Node.js 8.x required (some dependencies don’t support newer versions)
    必须使用node.js 8
  • ADB properly set up
  • RethinkDB >= 2.2
  • GraphicsMagick (for resizing screenshots)
  • ZeroMQ libraries installed
  • Protocol Buffers libraries installed
  • yasm installed (for compiling embedded libjpeg-turbo)
  • pkg-config so that Node.js can find the libraries
    MAC OS系统上,执行

brew install rethinkdb graphicsmagick zeromq protobuf yasm pkg-config
cnpm install -g stf //可以使用淘宝安装会快一些 也可执行 npm install -g stf

在这里插入图片描述
以上,环境安装全部完成!

开始操作

1 启动rethinkdb,想放置后台"&",想长期运行“nohub”

nohub rethinkdb &

想让别人也使用
stf local --public-ip <your_internal_network_ip_here>
本地ip:0.0.0.0

stf local --public-ip 0.0.0.0

这样就会开放一个7100的端口

  • 浏览器输入网址0.0.0.0:7100
    (也可以使用 stf local 来启动)

查看当前开发的端口
netstat -tlnp | grep 7100

stf-setting-key:获取token:11be67041bb4479f936858bef5de8bb2048f262f050542a08440232cbddbbdbc

远程调试手机:
首先对方主机要ssh打开分享
adb connect ip+端口号
其中 ip是
在这里插入图片描述
###shell 脚本解析
在这里插入图片描述
(因中间http编写重复,去掉后正确)

1 执行 curl -H “Authorization: Bearer YOUR-TOKEN-HERE” https://stf.example.org/api/v1/user
这个user的api使用如下:
在这里插入图片描述
借助使用jq分析,使用STF_TOKEN和STF_HOST可以得到用户的使用信息。

2 执行 curl -H “Authorization: Bearer YOUR-TOKEN-HERE” https://stf.example.org/api/v1/devices
可以得到设备信息

3 占用一个设备
发起POST请求
curl -X POST --header “Content-Type: application/json” --data ‘{“serial”:“EP7351U3WQ”}’ -H “Authorization: Bearer YOUR-TOKEN-HERE” https://stf.example.org/api/v1/user/devices
其中 serial是序列号
不用的话
释放这个设备
curl -X DELETE -H “Authorization: Bearer YOUR-TOKEN-HERE” https://stf.example.org/api/v1/user/devices/{serial}

4 最有用:Note that if you haven’t added your ADB key to STF yet, the device may be in unauthorized state after connecting to it for the first time. We recommend you make sure your ADB key has already been set up properly before you start using this API. You can add your ADB key from the settings page, or by connecting to a device you’re actively using in the UI and responding to the dialog that appears.

发起远程连接的请求
curl -X POST -H “Authorization: Bearer YOUR-TOKEN-HERE” https://stf.example.org/api/v1/user/devices/{serial}/remoteConnect
也要释放

在这里插入图片描述
emulator和localhost其实是一个设备,只是一个是模拟器一个是远程连接

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值