当前位置:网站首页>App移动端测试【4】apk的操纵
App移动端测试【4】apk的操纵
2022-07-03 15:30:00 【Leo_Eagle】
apk的安装与卸载
1. 安装apk
1.1 默认安装
C:\Users\Leo>adb connect 127.0.0.1:62001
already connected to 127.0.0.1:62001
C:\Users\Leo>adb install G:\weixin703android1400.apk
Performing Push Install
[ 34%] /data/local/tmp/weixin703android1400.apk
1.2 覆盖安装
C:\Users\Leo>adb install -r G:\weixin703android1400.apk
1.3 指定设备安装(覆盖)
C:\Users\Leo>adb –s 127.0.0.1:62001 install -r G:\weixin703android1400.apk
2. 卸载apk
注意:卸载apk需要进入到shell里面(adb shell)
2.1 首先进入到/data/app/下。
C:\Users\Leo>adb shell
[email protected]:/ # cd /data/app/
2.2 执行删除命令(退出shell模式,在cmd下通过adb uninstall删除apk)
adb uninstall
C:\Users\Leo>adb shell
[email protected]:/ # cd /data/app/
[email protected]:/data/app # ls
com.tencent.mm-2
com.tencent.mobileqq-1
[email protected]:/data/app # adb uninstall com.tencent.mm
/system/bin/sh: adb: not found
C:\Users\Leo>adb uninstall com.tencent.mm
格式:
adb uninstall com.tencent.mm
adb uninstall | -k com.tencent.mm 说明:-k卸载软件但是配置及缓存文件保存。
注意:
在/data/app/目录下查询的包末尾都带数字,但是adb uninstall *** 的时候末尾的『-1或-n』等要抹掉。
如adb uninstall com.tencent.mm
com.tencent.mm-2
com.tencent.mobileqq-1
3. 查看设备上面的安装应用
C:\Users\Leo>adb -s 127.0.0.1:62001 shell
[email protected]:/ # pm list package
或
C:\Users\Leo>adb shell pm list package
测试精讲视频
如果你觉的文章读的不过瘾,可以查看详细的视频教程。
学习路线如下




边栏推荐
- Unity功能——Unity离线文档下载及使用
- Visual upper system design and development (Halcon WinForm) -3 Image control
- 视觉上位系统设计开发(halcon-winform)-2.全局变量设计
- Vs2017 is driven by IP debugging (dual machine debugging)
- QT use qzxing to generate QR code
- Second kill system 3 - list of items and item details
- Detailed comments on MapReduce instance code on the official website
- [cloud native training camp] module 7 kubernetes control plane component: scheduler and controller
- XWiki Installation Tips
- Use of Tex editor
猜你喜欢

Halcon and WinForm study section 2

视觉上位系统设计开发(halcon-winform)-1.流程节点设计

Unity function - unity offline document download and use

求字符串函数和长度不受限制的字符串函数的详解

Summary of JVM knowledge points

【云原生训练营】模块七 Kubernetes 控制平面组件:调度器与控制器

视觉上位系统设计开发(halcon-winform)-4.通信管理

How are integer and floating-point types stored in memory

qt使用QZxing生成二维码

找映射关系
随机推荐
Concurrency-02-visibility, atomicity, orderliness, volatile, CAS, atomic class, unsafe
Using multipleoutputs to output multiple files in MapReduce
Popular understanding of gradient descent
Tensorflow realizes verification code recognition (I)
Chapter 04_ Logical architecture
详解指针进阶1
XWiki Installation Tips
视觉上位系统设计开发(halcon-winform)-6.节点与宫格
socket.io搭建分布式Web推送服务器
Apache ant extension tutorial
Stress test WebService with JMeter
Introduction, use and principle of synchronized
Get the executable path through the process PID (queryfullprocessimagename)
通过进程PID获取可执行文件路径(QueryFullProcessImageName)
Digital image processing -- popular understanding of corrosion and expansion
视觉上位系统设计开发(halcon-winform)
The difference between RAR and zip files
如何使用 @NotNull等注解校验 并全局异常处理
Introduction series of software reverse cracking (1) - common configurations and function windows of xdbg32/64
PyTorch crop images differentiablly