红旗Linuxx、QTP、Jenkins

QTP的Description对象
QTP是建立在对象识别基础上的自动化测试工具
通常QTP是通过对象库来识别不同的对象,而描述性编程是QTP另外一种能够识别对象的途径,它不依赖于对象库,通过增加一些对象的描述来识别对象。
当需要操作一个对象时有三种方式:
1、使用对象库经记录的控件名;初级描述性编程(直接描述)
Browser("title:=Google").Page("title:=Google").Link("text:=Google").click
注意:如果需要两个以上特性来描述一个对象,需要使用逗号(,)对描述性语言进行分割
使用:=来连接属性和属性值,并且:=两边不能有空格
使用SPY查看对象的属性名和属性值(Tools -----& Object Spy)
使用"With"关键字简化代码:With.......End
2、使用描述性编程;高级描述性编程
测试对象的属性描述都包装在Description对象中
QTP中的Description对象详解
QTP/UFT中定位对象的最常见方法
QTP运行对象属性和对象库属性的区别和用法
QTP----如何批量添加对象到对象库
qtp&问题汇总(不断更新)&…
QTP虚拟对象
QTP中的测试对象和运行时对象
QTP之——Failed to run script. Description: 没有注册类别
qtp 怎样添加界面中没有被操作录制的对象到对象库
QTP对象的方法(一)
没有更多推荐了,软件测试技术积累、分享、交流......
[转]QTP的录制回放过程
网上转载的,个人觉得通过这篇文章,对于QTP脚本录制和回放有个更深入的了解。
原文地址:
QTP录制过程
1.确定用于描述当前操作对象的测试对象类,并创建测试对象
2.读取当前操作对象属性的当前值,并存储一组属性和属性值到测试对象中
3.为测试对象创建独特的有别于其他对象的名称,通常使用一个突出属性的值
4.记录在对象上执行的操作
录制过程中可能出现的问题:
1.无法识别对象
解决方案:如果是没有相应程序的插件,而导致的对象不能识别,请填加相应的插件.如果是少量的几个控件不能识别的话,可以用合适类型的虚拟对象来代替.当然还有两个万能的办法,就是更改录制模式使用LOW-LEVEL
Recording 和 Analog Recording来录制.
2.无法生成脚本,但对象可以识别
解决方案:把对象手工添加到对象库中去,然后手工来生成需要的脚本
QTP回放过程
1.根据对象的名称到对象存储库中查找相应的对象
2.读取对象的描述,既对象的属性和属性值
3.基于对象的描述,QTP在应用程序中查找相应的对象
4.执行相关的操作
回放过程中可能出现的问题:
1.找不到测试对象
解决方案:把该对象填加到对象库中去
2.测试对象与运行时对象不匹配
解决方案:如果是因为脚本的上下文依赖而导致的对象不能识别,请加相应的延时.如果是由于对象属性发生了变化而导致的对象不能识别,请修改相应的属性.
3.无法执行脚本操作
解决方案:请检查脚本程序
QTP-录制与回放
没有更多推荐了,Jekins+QTP配置方法_百度文库
您的浏览器Javascript被禁用,需开启后体验完整功能,
享专业文档下载特权
&赠共享文档下载特权
&100W篇文档免费专享
&每天抽奖多种福利
两大类热门资源免费畅读
续费一年阅读会员,立省24元!
Jekins+QTP配置方法
&&自动测试相关文档
阅读已结束,下载本文需要
定制HR最喜欢的简历
下载文档到电脑,同时保存到云知识,更方便管理
加入VIP
还剩2页未读,
定制HR最喜欢的简历
你可能喜欢Postman-CI集成Jenkins - One|Piece - 博客园
官方说明:Postman's command-line companion lets you do amazing things! With Newman, you can integrate Postman collections with your build system. Or you can run automated tests for your API through a cron job.
概述:集成Postman的API测试命令行执行工具
基于Node.js,可安装在Linux/Windows/Mac
安装命令:
npm install -g newman
验证安装是否成功
出现版本号,则安装成功
运行方式,执行Postman导出的Collection文件
newman -c *.json.postman_collection
Newman命令行操作
执行指定的Collection文件
newman -c *.json.postman_collection
执行指点定的Collection文件及Environment文件
newman -c *.json.postman_collection -e *.postman_environment
执行保存到服务器上的Collection
newman -u https://www.getpostman.com/collections/cb208e7ee5
循环执行Collection文件5次
newman -u https://www.getpostman.com/collections/cb208e7ee5 -n 5
详细的newman命令用法
Usage: newman [options]
-h, --help
output usage information
-V, --version
output the version number
-c, --collection [file]
Specify a Postman collection as a JSON [file]
-u, --url [url]
Specify a Postman collection as a [url]
-f, --folder [folder-name]
Run a single folder from a collection. To be used with -c or -u
-e, --environment [file]
Specify a Postman environment as a JSON [file]
-E, --exportEnvironment [file]
Specify an output file to dump the Postman environment before exiting [file]
-d, --data [file]
Specify a data file to use either json or csv
-g, --global [file]
Specify a Postman globals file [file]
-G, --exportGlobals [file]
Specify an output file to dump Globals before exiting [file]
-y, --delay [number]
Specify a delay (in ms) between requests
-r, --requestTimeout [number]
Specify a request timeout (in ms) for requests
-R, --avoidRedirects
Prevents Newman from automatically following redirects
-s, --stopOnError
Stops the runner with code=1 when a test case fails
-j, --noSummary
Doesn't show the summary for each iteration
-n, --number [number]
Define the number of iterations to run
-C, --noColor
Disable colored output
-k, --insecure
Disable strict ssl
-N, --encoding [encoding-type]
Specify an encoding for the response. Supported values are ascii,utf8,utf16le,ucs2,base64,binary,hex
-x, --exitCode
Continue running tests even after a failure, but exit with code=1. Incompatible with --stopOnError
-o, --outputFile [file]
Path to file where output should be written [file]
-O, --outputFileVerbose [file]
Path to file where full request and responses should be logged [file]
-t, --testReportFile [file]
Path to file where results should be written as JUnit XML [file]
-i, --import [file]
Import a Postman backup file, and save collections, environments, and globals [file] (Incompatible with any option except pretty)
-p, --pretty
Enable pretty-print while saving imported collections, environments, and globals
-H, --html [file]
Export a HTML report to a specified file [file]
-W, --whiteScreen
Black text for white screen
-L, --recurseLimit [limit]
Do not run recursive resolution more than [limit] times. Default = 10. Using 0 will prevent any varialbe resolution
Newman is a command-line collection runner for Postman. You must specify a collection file or a collection URL to run newman
A collection file or URL is mandatory
newman -c POSTMAN_COLLECTION
newman -u POSTMAN_COLLECTION -e POSTMAN_ENVIRONMENT
newman -c POSTMAN_COLLECTION -f SAMPLE_FOLDER
For more documentation, issues and examples head over to https://github.com/postmanlabs/newman
Jenkins集成
既然Newman支持命令行运行,那么集成Jenkins就很简单。在Jenkins的Job中添加command line,内容如下:
newman -c *.json.postman_collection --exitCode 1
随笔 - 142
Trackbacks - 0在远程linux系统中安装tomcat
在远程linux系统中安装tomcat
假如jenkins编译的maven项目所打的war包在这个目录下:
现在我们想将这个war包,利用jenkins上传到远程的tomcat中,怎么弄呢?步骤如下:
(1) 下载好对应版本的tomcat
1)tomcat官网中下载tomcat。我远程的机器为linux系统,因此下载的是linux版本,我下载的版本是7.0.88, apache-tomcat-7.0.88.tar.gz。
(2) 将apache-tomcat-7.0.88.tar.gz上传到linux系统中,并启动
1) 将压缩包上传到linux系统中,解压。 tar -zxvf
apache-tomcat-7.0.88.tar.gz
对解压后的文件夹文件赋予权限。chmod 777
apache-tomcat-7.0.88 *
2) 运行tomcat需要安装jdk。
下载linux版本的jdk,我下载的版本是jdk-8u171-linux-x64.tar.gz,按照步骤1)进行上传并解压。
接下来就是需要配置环境。利用命令
vi ~/.bash_profile进行配置。
随后就是利用命令 source ~/.bash_profile保存环境变量。输入命令java -version查看jdk是否安装成功。如果出现如下界面,则表明安装成功。
3) 启动tomcat
进入tomcat的bin目录下启动startup.sh。这时候tomcat就已经启动了,我们可以在本地机器中输入远程地址来查看tomcat是否启动。由于我的tomcat配置的端口号是8090,因此输入就可以看到tomcat已经启动。
远程操作Linux下安装Tomcat服务器并安装部署Java Web程序
没有更多推荐了,
(window.slotbydup=window.slotbydup || []).push({
id: "5865577",
container: s,
size: "300,250",
display: "inlay-fix"

我要回帖

更多关于 linux常用命令 的文章

 

随机推荐