1、文件:/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-android-driver/lib/driver.js,注释以下几句代码

await this.adb.uninstallApk(this.opts.appPackage);

  await helpers.installApkRemotely(this.adb, this.opts);

  await helpers.resetApp(this.adb, this.opts.app, this.opts.appPackage, this.opts.fastReset);
  await this.checkPackagePresent();
 
2、文件:/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-android-driver/build/lib/driver.js,注释以下几句代码:
    return _regeneratorRuntime.awrap(_androidHelpers2['default'].resetApp(this.adb, this.opts.app, this.opts.appPackage, this.opts.fastReset));
    return _regeneratorRuntime.awrap(this.adb.uninstallApk(this.opts.app));
    return _regeneratorRuntime.awrap(_androidHelpers2['default'].installApkRemotely(this.adb, this.opts));
    return _regeneratorRuntime.awrap(this.checkPackagePresent());
 
3、文件:/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-android-driver/lib/android-helpers.js 注释以下几句代码
    await adb.install(unicodeIMEPath, false);

  await helpers.pushSettingsApp(adb);
  await helpers.pushUnlock(adb);
 
4、文件/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-android-driver/build/lib/android-helpers.js  替换以下几句代码
    return _regeneratorRuntime.awrap(helpers.initUnicodeKeyboard(adb))  替换为return context$1$0.abrupt('return', defaultIME);
    return _regeneratorRuntime.awrap(helpers.pushSettingsApp(adb));  替换为return context$1$0.abrupt('return', defaultIME);
    return _regeneratorRuntime.awrap(helpers.pushUnlock(adb));  替换为return context$1$0.abrupt('return', defaultIME);
 
 
 
 
 

Appium禁止appium setting和unlock在设备上重复安装的更多相关文章

  1. 如何禁止 Mac OS X 在外接设备上生成 .DS_Store 文件?以及如何批量删除 .DS_Store 文件?

    如何禁止 Mac OS X 在外接设备上生成 .DS_Store 文件?以及如何批量删除 .DS_Store 文件?原文链接:http://www.java2class.net/bbs/viewthr ...

  2. 【Abode Air程序开发】在设备上进行安装

    在设备上进行安装 在 Google Android 设备上安装应用程序 在 Apple iOS 设备上安装应用程序 在 Google Android 设备上安装应用程序 在项目的开发.测试和部署阶段, ...

  3. 不通过App Store,在iOS设备上直接安装应用程序(转)

    今天在iOS设备上安装天翼云存储app,在safari上直接打开http://cloud.189.cn/wap/index.jsp,点击“点击免费安装”,如下图: 神奇的事情发生了,设备上直接下载ap ...

  4. 不通过AppStore,在iOS设备上直接安装应用程序的原理

    本文转载至  http://mobile.51cto.com/hot-439095.htm 通过itms-services协议,可以通过safari浏览器直接在iOS设备上安装应用程序.利用这种方式, ...

  5. Android 在同一台设备上安装多个同一项目的apk

    如果设备上已经安装了一个apk,再次安装这个apk就会提示覆盖前面的应用 解决办法: 方法一:手动改包名 不好改,改了几次都不成功(可能是代码在svn管理的原因,改完后文件夹里的代码就没了),确实不实 ...

  6. appium--解决每次安装appium setting和Unlock

    前戏 每次启动appium进行自动化的时候,都会提示我们需要安装appium setting和Unlock,而且还都要手动确认 那这两个文件是做什么的呢? Appium settings:用于设置网络 ...

  7. Appium(客户端版)解决每次运行Android,都安装Appium Setting和Unlock的方法

    遇到的问题:使用的Appium界面的server进行启动,每次启动时都会安装Appium Setting和Unlock文件. 通过log可以看到安装路径如下:   Appium Setting安装包路 ...

  8. Appium——解决每次启动时都安装setting和unlock app方法

    找到appium安装目录 C:\Program Files (x86)\Appium\node_modules\appium\lib\devices\android 修改代码,注释掉弹出setting ...

  9. 【Appium】每次启动是提示安装setting和unlock app的解决办法

    进入appium安装目录,C:\Program Files (x86)\Appium\node_modules\appium\lib\devices\android,编辑android.js文件,注释 ...

随机推荐

  1. BestCoder Round #92 1002 Count the Sheep —— 枚举+技巧

    题目链接:http://bestcoder.hdu.edu.cn/contests/contest_showproblem.php?cid=748&pid=1002 题解: 做题的时候只是想到 ...

  2. 网页兼容性测试(工具使用IETESTER、Firefox、360安全浏览器)

    网页兼容性测试主要是针对不同的浏览器进行的测试.由于用户浏览器的不同,往往都会使我们的网页发生页面样式错乱,图片无法显示等问题.对于前端开发工程师来说,确保代码在各种主流浏览器的各个版本中都能正常显示 ...

  3. css父元素背景覆盖其子元素背景

    <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title> ...

  4. AtrousConvolution和dilated convolution

    唉,真烦哪些炒概念的,把整个世界都给弄乱了. 这里说一下dilated convolution和atrous convolution. 这两种是一样的,至少keras源码中是一样的.在keras中调用 ...

  5. python中format()方法格式化字符串

    format()是python2.6新增的一个格式化字符串的方法,功能非常强大,有可能在未来完全替代%格式化方法,相比 % ,format()的优点有: 1 .格式化时不用关心数据类型的问题,form ...

  6. CentOS6.3安装 Oracle 11g R2

    1.设置系统1.1.包需求 11g很人性化了,增加了检查的机制,还有就是不象10g那样在64位下要安装很多的32位包,只需要安装一个gcc-32bit-4.3就OK了.下列表必须要安装:binutil ...

  7. ubuntu下的google拼音输入法(终结版)

    声明:此文章是从我的51cto博客上搬至于此. Ubuntu下SCIM应该是最好的中文输入法了,它与搜狗差不多,下面介绍它的安装方法: 1)终端输入: sudo apt-get remove scim ...

  8. bootstrap table 根据单元格中的数据改变单元格的样式

    在bootstrap-table.js里面列属性 formatter就是用来格式化单元格的,其默认值是undefined 类型是function,function(value,  row, index ...

  9. python与c#的交互模块pythonnet

    今天总结一下python与c#的交互模块pythonnet,其实微软也是有相应的解释器的,就是Ironpython,可是毕竟Ironpython还有很多东西没有从python那边继承过来,所以有时候用 ...

  10. docker 学习(四) springboot + docker

    下面演示: 在Windows上新建一个简单的Springboot工程,生成docker iamge,然后在本地的docker上运行: (1):登录到 https://start.spring.io/, ...