谁说QTP不能多线程 - 当Python遇上QTP

Python并发编程与正则表达式实战指南 并发编程是提升Python程序性能的核心技术,通过多线程、多进程和协程三种模式应对不同场景需求。多线程适合I/O密集型任务,多进程突破GIL限制实现真正并行,协程则在高并发网络服务中表现优异。正则表达式作为文本处理的利器,通过模式匹配实现高效数据提取与清洗,预编译和原子分组等技巧可显著提升性能。这些技术在爬虫开发、日志分析、Web服务等场景有广泛应用,掌握它们能帮助开发者构建高性能的Python应用。 阅读详情

谁说QTP不能多线程 - 当Python遇上QTP

作者:Wally Yu (微博:http://weibo.com/quicktest)

经常有人问我一个问题:QTP可以同时做多个项目的自动化吗?我每次都回答说“不行,QTP不支持多线程,VBS本身就不是一门多线程的语言!”

最近在反思...QTP真的不能多线程吗?

好吧...如果一定要QTP可以多线程,咋办?我硬是想出了两个办法:

1. 需要在Windows可以多个QTP进程 - 可以吗?不行!有木有办法?没办法...

2. 需要QTP弃用VBS作为其脚本语言,改用多线程语言作为脚本语言(如Java、Python...) - 可以吗?不行!有木有办法?没办法...

且慢,假设QTP采用支持多线程的脚本语言,如何实现多线程?对,可以这样实现:

Function testScenario_1()

...

End Function


Function testScrnario_2()

...

End Function

...


Threading (testScenario_1).start()

Threading (testScenario_1).start()

...

如上结构可以实现QTP的多线程测试,这样岂不是大大提高了QTP的执行效率了么

可是回到现实中来,QTP的脚本语言是VBS,如何才能实现以上的愿望呢?呵呵,何不用AOM + DP!!!

(注:AOM

2020 Python 软件测试接口测试面试题分享!内附答案! 干货 阅读详情

相关推荐

PyCharm运行与调试配置全解析:从概念到实战,提升Python开发效率

在Python开发中,集成开发环境(IDE)的配置是提升开发效率的关键环节。PyCharm作为一款功能强大的IDE,其核心价值在于通过深度集成的运行配置(Run Configuration)和调试配置(Debug Configuration)系统,将代码编写、依赖管理、运行测试和问题排查等工作流无缝串联。运行配置定义了程序的执行环境,包括解释器、工作目录和参数等,而调试配置在此基础上增加了断点、单步执行和变量查看等调试功能,相当于为程序装上了“X光机”。理解这些配置的原理,能帮助开发者快速搭建高效、可靠的开

weixin_34197488的博客 463

qtp测试软件的使用方法及实例

此文档中包括了六个用qtp测试工具的测试实验,步骤详细,便于对自动化软件qtp的学习使用

微信数据库读取解密脚本 聊天记录查看工具,支持所有微信版本,后期将支持企业微信[Windows]

(1)获取微信昵称、微信账号、微信手机号、微信邮箱、微信KEY的基址偏移(2)获取微信的微信昵称、微信账号、微信手机号、微信邮箱、微信KEY、微信原始ID(wxid_******)(3)获取微信文件夹路径(4)支持查看聊天记录查看(5)根据key解密微信数据库(6)提供数据库部分字段说明(7)支持微信多开场景,获取多用户信息等(8)微信需要登录状态才能获取数据库密钥(9)支持导出聊天记录为html,备份微信聊天记录,方便查看(10)合并多个数据库,方便查看。

weixin_43101935的博客 1万+

基于ESP32-S3与PCM5102的HiFi网络收音机复刻指南:从硬件设计到软件配置

本文提供了一份详细的基于ESP32-S3与PCM5102的HiFi网络收音机复刻指南。内容涵盖从核心硬件选型(如ESP32-S3主控与PCM5102 DAC芯片)、四路独立LDO供电设计,到软件环境配置、固件烧录及常见问题调试的全过程,旨在帮助创客打造一台支持网络电台、本地播放与蓝牙连接的高保真音频播放器。

weixin_30632267的博客 185

FPGA新手避坑指南:手把手教你搞定RTL8211千兆网PHY的时序配置(附Verilog代码)

本文详细解析了FPGA与RTL8211千兆网PHY芯片的时序配置问题,重点介绍了TXDLY/RXDLY引脚设置、FPGA发送端和接收端的Verilog实现,以及调试与验证的完整流程。通过硬件电路设计和代码示例,帮助开发者解决网络连接不稳定、丢包等常见问题,提升千兆网通信的稳定性。

weixin_28732953的博客 539

【超详细】安装了anaconda后,Ubuntu18+COLMAP配置疯狂踩坑踩至魔怔的记录

本博客收集了博主在Ubuntu18系统中编译COLMAP所遇到的困难,提供了解决方法,也收集了目前网上大多数的坑,除此之外,也为Ubuntu18系统下COLMAP的安装提供了一种新的路径。

Stay_Foo_lish的博客 3509

2026年摩尔线程数字IC面试试卷带答案

本文摘要: 该试卷为数字IC设计笔试,满分120分,时长90分钟,包含单选题、波形分析题、多选题和代码设计题。重点考察时序约束(如set_false_path)、建立/保持时间、逻辑化简、复位机制、AXI协议、半导体工艺、状态机、GPU架构等核心知识点。多选题涉及异步FIFO设计、Verilog综合、亚稳态处理、C++关键字和低功耗技术。代码题要求实现单比特信号去毛刺电路,需稳定4个时钟周期才输出。试题解析详细,标注了企业面试高频考点,如摩尔线程自研的MUSA架构和花港GPU架构特点。整体内容专业性强,覆盖

Open 98

第七天 Labview进阶(7.4 NI Vision简单使用)

NIVision机器视觉软件使用指南 摘要:NIVision是National Instruments推出的高效机器视觉软件,具有硬件无缝集成、图形化编程和工业级部署等优势。本文介绍了NIVision的安装步骤(需Vision Acquisition和Vision Development模块)及三个典型应用案例:1)实物检测通过IMAQCreate等模块实现物体识别与坐标定位;2)OCR检测利用IMAQOCR系列模块完成字符识别;3)几何模板匹配使用IMAQLearnGeometricPattern等模块实

weixin_38637405的博客 771

WorkBuddy CAD 审图救命课:约束、单位、尺寸链一次查清,打样前拦住返工

最危险的 CAD 文件不是打不开,而是看起来完整却混用了毫米与英寸、草图欠约束、关键尺寸没有来源。审图任务必须先列规则,再输出问题位置。 本课不会用“AI 一键完成”制造错觉,而是把 WorkBuddy、FreeCAD 0.21.2、OpenCascade 7.7 与人工审阅组成一条可复现链路。你会从“一份模拟 STEP 文件、参数表、装配基准与审图标准”出发,得到“单位报告、约束清单、尺寸链风险表与人工复核标记”,并学会用真实命令、错误信号和停止条件判断成果能不能进入下一阶段。

yueyeguzhuo的专栏 264

Outlook Express 6 (OE6) for Win7/Win8/Win10

英文版 Outlook Express6.0, 兼容Win7/Win10/WinXP,解压就可用。

win10 跳过U8环境检测的IE WebControls.rar

win10 安装u8的时候 提示IE WebControls 不通过,这个工具可以欺骗u8的检查。 跳过U8环境检测的IE WebControls。提示导入失败后,重新检测通过。

深度学习工具包 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")

SAP B1中文培訓教材_SDK

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

上一篇: 《QTP项目应用与进阶》发布啦 - 自动化测试从业人员的必备宝典!!!
下一篇: QTP测试框架之_报表
Wally_Yu
博客等级 码龄19年 71粉丝 28原创
评论 2
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

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

抵扣说明:

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

余额充值