【Android自动化】自动输入安装密码,并检测App是否安装成功

七叔叫你在appium搭建app自动化测试环境 前言 我们在appium做app自动化测试,环境搭建是比较麻烦的。也是很多初学者在学习app自动化之时,花很多时间都难跨越的坎。今天七叔就来讲讲appium如何搭建APP自动化测试环境。喜欢七叔的可以给小编点点关注哟。 没有成功的环境,就没有办法继续后续的使用。 在app自动化测试当中,我们主要是通用电脑端的python代码,能够驱使手机端的app去进行操作。比如打开一个app,输入用户名和密码,进入登陆操作。 由于电脑端和手机端是两个独立的设备。要实现数据通信,就需要将二者连一起。因此对于 阅读详情

准备工作

  1. pip install --pre uiautomator2 (安装u2的库)
  2. pip install -U weditor (桌面可生成一个可执行的py)
  3. 根据网上的资料去了解u2的使用方法

安装App主文件(install_app.py)

import subprocess
import uiautomator2 as u2
import time
import argparse
from threading import Thread
import pymysql.cursors
import pymysql
import sys


def get_serial_and_apk():
    """
    获取设备名和包名
    """
    parser = argparse.ArgumentParser()
    parser.add_argument('--serial', type=str)  # 从jenkins获取需要安装的App的手机的uid
    parser.add_argument('--upload_filename', type=str)  # 获取需要安装的Apk的包名
    parser.add_argument('--replace_install', type=int)  # 这边是根据公司需要使用原有Apk构建,还是重新覆盖安装新的包
    args = parser.parse_args()
    serial = args.serial
    upload_file = args.upload_filename
    replace_install = args.replace_install
    print(replace_install)
    apk_path = "/Users/data/upload_apk/" + upload_file  # 安装包的路径,linux为例
    print(apk_path)
    return serial, apk_path, replace_install, upload_file  # 输出设备号,apk的安装路径,是否覆盖安装,包名


def select_install_pwd():
    """
        运行sql语句,主要是去数据库根据uid去查当前设备的安装密码
        :param
        sql_words: sql语句
        :return: 查询数据对应的字典列表
    """
    connect = pymysql.Connect(
        host="192.168.1.1",
        port=3306,
        user="root",
        passwd="123456",
        db="auto_build",
        charset="utf8"
    )
    # 获取游标
    cursor = connect.cursor(cursor=pymysql.cursors.DictCursor)
    try:
        sql = f"""SELECT install_passwd FROM device_info WHERE id =\'{serial}\'"""
        cursor.execute(sql)
        results = cursor.fetchall()
        for row in results:
            print(row['install_passwd'])
            return row['install_passwd']
    except Exception as e:
        print(e)
        connect.rollback()
    cursor.close()
    connect.close()
    return None


def time_out(start_time, time_out=120.0):
	"""
	定义一个超时的时间2min
	"""
    end_time = time.time()
    difference = round((end_time - start_time), 2)
    if difference - time_out > 0:
        print(f"设定的时间{time_out}到了退出")
        return False
    else:
        return True


def listen_alert(driver):
    """
    监听弹框
    """
    time.sleep(1)
    if driver(textContains='请输入').exists():
        pwd = select_install_pwd()
        driver(textContains='请输入').set_text(pwd)
        print("准备点击确定")
        time.sleep(2)
        if driver(text='确定').exists:
            driver(text='确定').click()
            print("已点击确定")
    if driver(text="继续安装").exists():
        driver(text="继续安装").click()
        print("点击继续安装")
    if driver(text='无视风险安装').exists():
        driver(text='无视风险安装').click()
    if driver(text='安装').exists():
        driver(text='安装').click()


def cmd(cmd, remove_shell=False):
	"""
	adb命令头部封装
	"""
    head = adb_head
    if remove_shell:
        head = adb_head.replace('shell', '')
    print(head + ' ' + cmd)
    import os
    r = os.popen(head + ' ' + cmd)
    print(r.read())
    return r.read()


def create_dir_if_not_exists(remote_path):
	"""
	判断下手机设备中是否有我们上传的一个路径
	为什么需要上传到手机,而不是直接adb install 安装呢,主要是需要获取安装成功的Success的提示,以手机内部安装更为合适
	"""
    r = cmd('ls ' + remote_path)
    if 'No such file or directory ' in r:
        cmd(' mkdirs ' + remote_path)


def push_file(file_path, remote_path):
	"""
	推Apk到手机中存储
	"""
    # create_dir_if_not_exists(remote_path)
    cmd(' push ' + file_path + ' ' + remote_path, remove_shell=True)
    print(' push ' + file_path + ' ' + remote_path)


def install(apk_path, apk_name):
    """
    安装apk
    """
    push_file(apk_path, '/data/local/tmp')  # 上传apk到手机中
    remote_path = '/data/local/tmp/' + apk_name  # 手机中的安装包的路径
    cmd = adb_head + ' pm install  -r ' + remote_path  # 强制安装
    # cmd = "adb -s %s install %s" % (serial, apk_path)
    process = subprocess.Popen(cmd, shell=True,
                               stdout=subprocess.PIPE,
                               stderr=subprocess.PIPE)
    process.wait(120)
    for line in process.stdout:
        line_str = line.decode("utf-8")
        print(line_str)
        if 'Success' in str(line_str):
            print("安装包已成功安装".center(70, "-"))
            return True
        else:
            if 'Failure' in str(line_str):
            	print(line_str)
                print("请检查当前安装的apk版本是否过低".center(50, "*"))
                print("注意此时apk安装失败,断开测试连接,请检查完毕后重新构建".center(50, "*"))
                sys.exit(1)
            return False


if __name__ == '__main__':
    serial, apk_path, replace_install, upload_file = get_serial_and_apk()
    adb_head = 'adb -s ' + serial + ' shell '
    if replace_install == 3:
        p1 = Thread(target=install, args=(apk_path, upload_file))
        p1.start()
        try:
            driver = u2.connect_usb(serial)
        except RuntimeError as e:
            print("检测到是否是设备断开连接!!!".center(70, "*"))
            sys.exit(1)
        while p1.is_alive():
            listen_alert(driver)
        p1.join()
        print("Ending".center(70, "-"))
        try:
            driver.service("uiautomator").stop()
        except Exception as e:
            print("未能停止uiautomator2的程序")
            print(e)
    else:
        print("使用原有的apk进行构建...")

app安卓逆向之smali代码log注入与原代码修改 文章目录1.背景分析2.概述3.开始3.1smali代码基础知识普及3.2apktool的基本使用3.3构建个人Log类并且反编译成Smali文件注入到某电商App中3.4重编译修改后的App项目,安装到模拟器中运行并使用注入的代码打印日志总结 1.背景分析 在安卓逆向的过程中常常会面临三个场景 想要了解某个方法是否有被调用 经过常规的代码分析后,想要知道App某些方法内部某些变量的值 App在Jave层的一些安全检测代码在我们的研究阶段需要屏蔽及修改 以上第一、第二个场景使用Xposed、 阅读详情

相关推荐

Android10.0 PMS安装第三方app时添加密码锁限制安装

在10.0的系统rom定制化开发中,在进行一些产品定制的时候,有需求要求限制第三方app的安装,需要添加 一个密码锁,在安装app的时候,会弹窗密码锁,输入正确的密码后,就可以继续安装app的功能 接下来就来实现这个功能

安卓兼职framework和app工程师的博客 1153

Android 10 安装Apk加限制(需要密码)

需求:安装APK时需要输入密码,例如12345,才能安装成功,否则安装失败。

qq_61516234的博客 3139

【实战指南】EC-Engineer中ESI配置与PDO Mapping全流程解析

本文详细解析了EC-Engineer中ESI配置与PDO Mapping的全流程操作,包括环境准备、ESI文件导入技巧、在线配置细节及故障处理。特别强调了WinPcap驱动的兼容性问题和PDO Mapping的最佳实践,帮助工程师高效完成EtherCAT总线配置,适用于工业自动化领域的伺服控制与运动协同场景。

weixin_28730927的博客 403

android弹窗验证密码,Android 应用安装添加密码输入弹窗

基于RK Android6.0-MID代码packages/apps/PackageInstaller/src/com/android/packageinstaller/PackageInstallerActivity.java为防止之后遗忘,记录一下安装apk时会弹出输入弹窗,输入内容正确,才可以点击安装按钮,输入错误安装应用弹窗消失先引用需要用到的类import android.widget....

weixin_39861823的博客 1602

RagFlow实战:如何用DeepDoc引擎高效处理扫描PDF文档(附完整代码解析)

本文详细解析了如何利用RagFlow的DeepDoc引擎高效处理扫描PDF文档。通过实战演示从环境搭建、PDF预处理、文本检测与识别,到布局分析与表格结构提取的完整流程,并提供了完整的代码实现。该方案超越了传统OCR,能输出保留原始版面信息的结构化数据,为构建高质量知识库提供了强大支持。

weixin_29245767的博客 302

kafka的安装与简单使用

auto.create.topics.enable=false #自动创建topic参数,建议此值设置为false,严格控制topic管理,防止生产者错写topic。num.partitions=5 # 默认partition数量为1,如果topic在创建时没有指定partition数量,默认使用此值,建议改为5。log.dirs=/export/server/kafka_2.13-3.2.0/logs #需要自己创建logs目录。可,本人依次递增1,2,3。#配置kafka环境变量。

v15220的博客 1130

android安装apk必须输入密码,jarsigner重新签名apk无法安装的解决方法

jarsigner -digestalg SHA1 -sigalg MD5withRSA -keystore debug.keystore -storepass android woxiangkan_debug.apk androiddebugkey在签名时,要加上2个参数:-digestalg SHA1 -sigalg MD5withRSA造成无法签名错误的原因,初步估计是JDK版本的问题。JD...

weixin_39755890的博客 1792

python画弗里德曼(Friedman) 检验和秩和检验(Nemenyi)检验图

python画弗里德曼(Friedman) 检验和秩和检验(Nemenyi)检验图 画好后效果图 实现代码如下 import matplotlib.pyplot as plt #算法平均排名 _alg_=[1.405,2.643,2.786,2.167] y=[1,2,3,4]#alg1,alg2,alg3,alg4 通过Nemenyi测试计算得到的临界值CD CD=1.024 h_CD=CD/2 plt.figure(figsize=(10,6)) plt.scatter(_alg_,y,s=10

大模型天花板 4473

android 实现密码输入弹窗

前言部分 最近有点忙好久没写啥东西了,正好项目中用到了一个输入密码的弹窗,顺便单独记录下,防止以后需要用. 内容部分 内容比较简单: 主要分为几个步骤,如下: 实现dialog的部分内容. 这里注意一下就是dialog的显示问题,比如,你需要设置一个主题,否则dialog显示的可能会有缝隙;还有就是你需要设置dialog的布局属性来保证dialog不是一个变形的弹窗. 代码如下: va...

鲨鱼不会飞的博客 3236

STM32F103内部晶振配置实战:从代码修改到频率验证(附工程模板)

本文详细介绍了STM32F103内部晶振(HSI)的配置实战,从代码修改到频率验证的全流程,并附赠可直接使用的工程模板。通过对比HSI与外部晶振的优缺点,帮助开发者在成本敏感和空间受限的应用中实现稳定时钟配置,同时提供频率校准和常见问题排查方法。

weixin_29171087的博客 324

PDBfixer:蛋白质结构修复工具

本文介绍蛋白质数据银行(PDB)文件常见问题及修复工具PDBFixer的使用方法。PDB文件常存在缺失原子、残基等问题,PDBFixer可通过GUI、命令行或Python API实现自动化修复。文章详细说明安装方法、命令行参数、Python脚本修复流程及非标准残基替换表,并与Modeller、ColabFold和Rosetta Remodel等其他修复工具进行对比分析,提供了各工具的特点、适用场景和典型计算时间比较,帮助用户根据具体需求选择合适的修复工具。

Protein Designer的博客 613

用Ranorex进行安卓IOS自动化测试

Ranorex是一个可以媲美QTP的自动化测试软件,比QTP更强的是,还可以测试IOS、安卓的手机APP。下面演示一下如何添加手机设备来测试(IOS安卓真机和安卓模拟器都可以)。

博客 2582

SAP 系统里生成 PDF 的几条主干路径:从 Spool 转换到 Adobe 原生渲染,再到 BTP 云服务

本文系统梳理了SAP生态中PDF生成的多种技术方案,包括Spool转换、OTF转换、Smart Forms/Adobe Forms原生生成以及云端服务等不同路径。文章通过实际案例和代码示例,详细分析了各方案的适用场景、技术要点和工程实践建议,特别强调了多语言支持、字体处理、性能优化等关键因素。针对不同业务需求,提供了从简单导出到复杂交互式PDF的完整解决方案框架,为SAP环境下的PDF处理提供了实用指南。

2007 年 ~ 2025 年,深耕 SAP 技术 18 年 302

第一:APP自动化工具-AirtestIDE-安装部署

【代码】第一:APP自动化工具-AirtestIDE-安装部署。

欢迎来到本博客! 3854

zemax 如何编译用户自定义DLL(含VS下载教程)

zemax 如何编译用户自定义DLL(含VS下载教程)

weixin_72050316的博客 498

华为的C语言编程规范.pdf

华为技术有限公司内部技术规范。本规范制定了编写C语言程序的基本原则、规则和建议。从代码的清晰、简洁、可测试、安全、程序效率、可移植各个方面对C语言编程作出了具体指导。

安卓自动化工具(附自动刷抖音脚本实例)

目前做Android自动化模拟用户操作的工具不多,还有一些工具是基于一些脚本框架封装的只能执行一些特定操作的应用。基于目前这类教程网上资源稀缺的现状下,我给大家推荐两款好用的工具,方便大家做相关方向的项目时可以参考。下面给大家介绍的两款好用的安卓自动化工具,也是本人常用的,感觉不错的两款:ADB和Autojs。 下面内容我将分别向大家介绍这两款工具的情况,然后列出一些常用命令,最后我会分别用两种工具做一个自动刷抖音的工具(每10秒滑动一次)。 一、ADB ADB全称为Android Debug Bridge

m0_45903982的博客 1万+

visio安装包

Microsoft Office Visio 是一款专业的制图软件。利用经过更新的形状、协作工具和数据链接图表,创建专业级图表以简化复杂的信息。

一款很“炸”的安卓UI自动化工具

介绍:4399AT是一款基于APPIUM框架改造和集于算法遍历,图像识别技术的自动化测试工具 工具:适用于Android App UI自动化 电脑系统:win10 64位 工具好处:解决不同手机安装提示和APP操作提示框,兼容不容手机控件,adb不稳定,PO模式等问题,具体可关注微信公众号“测试一般不一般”进行相关资料查看。 以下是关于该工具的使用说明,详情API可查看api文档   ...

9311

SAP B1中文培訓教材_SDK

公司内部培训资料,对开发工具 ,DIAPI, UIAPI,Add-ON有详细解说

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

【Android自动化】AccessibilityService实战-微信僵尸好友检测

上节我们学习了AccessibilityService无障碍的基础知识,并写了一个简单的微信自动登录的小案例。相信大家都意犹未尽,所以本节安排一波实战 —— 微信僵尸好友检测。啥是 僵尸好友?[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-dhtijtjk-1670470679465)(https://upload-images.jianshu.io/upload_images/27208505-edd7ca2cd0e6b404.png?imageMogr2/auto-orie

datian1234的博客 5358

Python appium搭建app自动化测试环境

appium做app自动化测试,环境搭建是比较麻烦的。也是很多初学者在学习app自动化之时,花很多时间都难跨越的坎。但没有成功的环境,就没有办法继续后续的使用。在app自动化测试当中,我们主要是通用电脑端的python代码,能够驱使手机端的app去进行操作。比如打开一个app,输入用户名和密码,进入登陆操作。由于电脑端和手机端是两个独立的设备。要实现数据通信,就需要将二者连一起。因此对于真机用户,需要用USB线连接手机和电脑,并且在开发者选项当中,开启USB调试模式。

MXB_1220的博客 894

python appium搭建app自动化测试环境

appium做app自动化测试,环境搭建是比较麻烦的。也是很多初学者在学习app自动化之时,花很多时间都难跨越的坎。 但没有成功的环境,就没有办法继续后续的使用。 在app自动化测试当中,我们主要是通用电脑端的python代码,能够驱使手机端的app去进行操作。比如打开一个app,输入用户名和密码,进入登陆操作。 由于电脑端和手机端是两个独立的设备。要实现数据通信,就需要将二者连一起。...

weixin_30624825的博客 827

android:ksweb、busybox、虚拟机、Termux(高级终端)

手机已经 root安装 tsu,这是一个 su 的 Termux 版本,是一个真正的 root 权限,用来在 Termux上替代su,操作不慎可能对手机有安全风险,因为官方封装了,所以安装也很简单:安装 tsu:pkg install tsu -y切换到 root:tsu退出 root:exittsu切换 root 用户时会弹出 root 授权提示,给予其 root 权限即可。在管理员身份下输入 exit 可回到普通用户身份。

freeking101的博客 10万+

APP自动化测试-安卓性能测试Monkey

#Monkey介绍 ##什么是Monkey Monkey是一个Android自动化测试工具,主要用于Android的压力测试,测试app是否会Crash,通过Monkey程序模拟用户触摸屏幕、按键等操作来对设备上的程序进行压力测试,检测程序多久的时间会发生异常,Monkey测试是一种为了测试软件的稳定性,健壮性快速有效的方法。 #安装Monkey测试环境 *安装JDK,配置环境变量(https://www.oracle.com/technetwork/j...

Roda的博客 5945

Keepass2Android密码管理器:安卓平台开源密码管理完整指南

在当今数字时代,保护您的在线账户安全至关重要。**Keepass2Android密码管理器**是一款功能强大的开源Android应用,让您能够安全存储和管理所有密码。这款兼容KeePass桌面版的移动应用,通过主密码和双重验证保护您的敏感信息,支持跨设备同步,是个人和企业用户的理想选择。 ## 🎯 项目亮点:为什么选择Keepass2Android? **Keepass2Android**作

gitblog_00533的博客 1140

android手机自动化测试,Android手机自动化测试实例详解

2014-9-24本人从参加工作以来,一直在做自动化测试方面的工作。最初接触的是Web自动化,后来又做接口自动化测试。由于最近几年手机应用越来越广泛,手机应用的自动化测试也发展的很快,所以我就利用工作之余去学习手机自动化测试。手机自动化框架也比较多,针对ios,android两个不同的平台,最后我挑选了appium,它是利用webdriver来进行驱动测试的,这个框架我比较熟悉,而且它支持两个平台...

weixin_39977488的博客 617

Android 14抓包自动化:ADB脚本一键配置HTTPS代理与证书

HTTPS抓包是移动端开发、测试与安全分析中的基础技术,其核心原理是通过中间人代理解密加密流量。在Android系统不断升级的背景下,尤其是Android 14对证书管理和网络权限的严格限制,传统手动配置流程变得异常繁琐且难以在自动化流程中复用。ADB(Android Debug Bridge)作为官方调试接口,提供了自动化执行Shell命令、推送文件与修改系统设置的强大能力,是实现跨版本、批量设备环境配置的关键技术。通过编写集成化的ADB脚本,可以自动完成CA证书安装、全局代理设置及应对系统限制等操作,将

weixin_34195364的博客 337

ETL实战指南:从数据抽取、清洗到加载的完整流程与最佳实践

在数据驱动业务的时代,数据集成与数据仓库建设已成为企业数字化转型的基础。无论是构建BI报表、数据中台,还是支撑数据分析,都离不开一套可靠的数据处理流程。ETL作为数据工程的核心方法论,涵盖抽取、转换与加载三个关键环节,旨在将分散、异构、脏乱的原始数据加工为统一、可信、可直接用于分析的数据资产。其技术价值不仅在于解决数据同步问题,更在于通过清洗规范化、口径统一和幂等设计,保障数据质量与一致性。在实际应用中,ETL广泛用于离线批量同步、实时数据捕获及数据湖分析等场景,帮助团队构建稳定高效的数据管道。本文结合工程

weixin_34049948的博客 558
上一篇: 【附源码】pytest多并发实践
下一篇: 【性能测试基础】性能专有名词解析及性能瓶颈分析技巧
晴时初遇雨
博客等级 码龄7年 1253粉丝 72原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

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

抵扣说明:

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

余额充值