当前位置: 首页 > news >正文

appium默认60秒关闭应用的问题

问题:appium默认启动一个应用的session过期时间是60秒到时间会自动停了刚启动的应用,工作台打印:info: [debug] We shut down because no new commands came in的日志

   

分析:--command-timeout  60 The default command timeout for the server to use for all sessions (in seconds and should be less than 2147483). Will still be overridden by newCommandTimeout cap

意思是默认60秒过期,超过60秒就会自动

解决办法:

从appium工作台最前面找到,启动命令:

> Launching Appium server with command: C:\Program Files (x86)\Appium\node.exe lib\server\main.js --address 127.0.0.1 --port 4723 --avd Nexus7 --platform-name Android --platform-version 19 --automation-name Appium --device-name "Android Emulator" --log-no-color

在cmd命令行,对应目录加时间参数即可:--command-timeout 600

在目录:C:\Program Files (x86)\Appium>

执行

node.exe node_modules\appium\lib\server\main.js --

address 127.0.0.1 --port 4723 --avd Android4.4.2 --device-ready-timeout 70 --pla

tform-name Android --platform-version 19 --automation-name Appium --avd Nexus7 -

-device-name "Android Emulator" --log-no-color --command-timeout 600

启动日志中就能看到:

info: [debug] Non-default server args: {"address":"127.0.0.1","logNoColors":true

,"avd":"Nexus7","androidDeviceReadyTimeout":"70","deviceName":"Android Emulator"

,"platformName":"Android","platformVersion":"19","automationName":"Appium","defa

ultCommandTimeout":600}

时间变成600秒了

【整整200集】超超超详细的Python接口自动化测试进阶教程合集,真实模拟企业项目实战

http://www.lryc.cn/news/127709.html

相关文章:

  • Docker 容器内无法使用vim命令 解决方法
  • Django的简介安装与配置及两大设计模式
  • Mybatis分页插件——PageHelper
  • k8s认证详解 k8s证书详解 2023推荐
  • php初解
  • 【C语言】回调函数,qsort排序函数的使用和自己实现,超详解
  • PHP手术麻醉系统源码,自动生成麻醉和护理医疗文书
  • 内网穿透实战应用——【通过cpolar分享本地电脑上有趣的照片:发布piwigo网页】
  • iPhone删除的照片能恢复吗?不小心误删了照片怎么找回?
  • LeetCode--HOT100题(32)
  • SAP MM学习笔记24-以评估收货(评价)和非评估收货(非评价)
  • Hadoop的DataNode无法启动的解决方案
  • re中的match和search有什么区别?
  • 《内网穿透》无需公网IP,公网SSH远程访问家中的树莓派
  • .net连接mysql,提示找不到请求的 .Net Framework Data Provider。可能没有安装
  • 销售自动化管理软件是什么,销售自动化管理软件有什么优势
  • MySQL 函数
  • 爬虫逆向实战(六)--猿人学第四题
  • 【大数据Hive】hive 事务表使用详解
  • 网络层协议
  • JWT(JSON Web Token )令牌
  • leetcode 力扣刷题 滑动窗口 部分题解(记录)
  • Intellij IDEA SBT依赖分析插件
  • MySQL中事务特性以及隔离机制
  • Docker知识(详细笔记)
  • 【C#】获取已安装的NETFramework版本集合
  • 对字符串中所有单词进行倒排-C语言/Java
  • Kubernetes入门 四、Pod核心
  • 【JAVA】数组练习
  • 每日一题——不同路径的数目(一)