51Testing软件测试论坛
标题:
插入检查点的问题
[打印本页]
作者:
chenbo81516
时间:
2008-4-15 10:22
标题:
插入检查点的问题
'Import SourceRef.xls
DataTable.ImportSheet "C:\Source\SourceRef.xls","DVD Ripper Series","Action1"
'''''''''''''''''''''''''''''''''''''''''''''Xilisoft DVD Ripper Series'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
SystemUtil.Run DataTable("SrcPath", dtLocalSheet), "", "C:\Source\DVD Ripper Series", "open"
Dialog("Installer Language").WinComboBox("Please select a language.").Select "English"
Dialog("Installer Language").WinButton("OK").Click
'Import SourceRef.xls
DataTable.ImportSheet "C:\Source\SourceRef.xls","DVD Ripper Series","Action1"
'''''''''''''''''''''''''''''''''''''''''''''Xilisoft DVD Ripper Series'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
SystemUtil.Run DataTable("SrcPath", dtLocalSheet), "", "C:\Source\DVD Ripper Series", "open"
Dialog("Installer Language").WinComboBox("Please select a language.").Select "English"
Dialog("Installer Language").WinButton("OK").Click
Dialog("DVD Ripper Series").Static("License Version").Check CheckPoint("Please review the license terms before installing Xilisoft DVD Ripper Platinum 5 0..34.0409")
Dialog("DVD Ripper Series").WinButton("I Agree").Click
Dialog("DVD Ripper Series").WinEdit("Edit").SetSelection 0,1
Dialog("DVD Ripper Series").WinEdit("Edit").Set DataTable("InsPath", dtLocalSheet)
Dialog("DVD Ripper Series").WinButton("Next >").Click
Dialog("DVD Ripper Series").WinButton("Install").Click
Dialog("DVD Ripper Series").WinCheckBox("Run DVD Ripper Series").Set "OFF"
Dialog("DVD Ripper Series").WinButton("Finish").Click
Check CheckPoint("Please review the license terms before installing Xilisoft DVD Ripper Platinum 5 0..34.0409")
Dialog("DVD Ripper Series").WinButton("I Agree").Click
Dialog("DVD Ripper Series").WinEdit("Edit").SetSelection 0,1
Dialog("DVD Ripper Series").WinEdit("Edit").Set DataTable("InsPath", dtLocalSheet)
Dialog("DVD Ripper Series").WinButton("Next >").Click
Dialog("DVD Ripper Series").WinButton("Install").Click
Dialog("DVD Ripper Series").WinCheckBox("Run DVD Ripper Series").Set "OFF"
Dialog("DVD Ripper Series").WinButton("Finish").Click
'Import SourceRef.xls
DataTable.ImportSheet "C:\Source\SourceRef.xls","DVD Ripper Series","Action1"
'''''''''''''''''''''''''''''''''''''''''''''Xilisoft DVD Ripper Series'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
SystemUtil.Run DataTable("SrcPath", dtLocalSheet), "", "C:\Source\DVD Ripper Series", "open"
Dialog("Installer Language").WinComboBox("Please select a language.").Select "English"
Dialog("Installer Language").WinButton("OK").Click
Dialog("DVD Ripper Series").Static("License Version").Check CheckPoint("Please review the license terms before installing Xilisoft DVD Ripper Platinum 5 0..34.0409")
Dialog("DVD Ripper Series").WinButton("I Agree").Click
Dialog("DVD Ripper Series").WinEdit("Edit").SetSelection 0,1
Dialog("DVD Ripper Series").WinEdit("Edit").Set DataTable("InsPath", dtLocalSheet)
Dialog("DVD Ripper Series").WinButton("Next >").Click
Dialog("DVD Ripper Series").WinButton("Install").Click
Dialog("DVD Ripper Series").WinCheckBox("Run DVD Ripper Series").Set "OFF"
Dialog("DVD Ripper Series").WinButton("Finish").Click
'Import SourceRef.xls
DataTable.ImportSheet "C:\Source\SourceRef.xls","DVD Ripper Series","Action1"
'''''''''''''''''''''''''''''''''''''''''''''Xilisoft DVD Ripper Series'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
SystemUtil.Run DataTable("SrcPath", dtLocalSheet), "", "C:\Source\DVD Ripper Series", "open"
Dialog("Installer Language").WinComboBox("Please select a language.").Select "English"
Dialog("Installer Language").WinButton("OK").Click
Dialog("DVD Ripper Series").Static("License Version").Check CheckPoint("Please review the license terms before installing Xilisoft DVD Ripper Platinum 5 0..34.0409")
Dialog("DVD Ripper Series").WinButton("I Agree").Click
Dialog("DVD Ripper Series").WinEdit("Edit").SetSelection 0,1
Dialog("DVD Ripper Series").WinEdit("Edit").Set DataTable("InsPath", dtLocalSheet)
Dialog("DVD Ripper Series").WinButton("Next >").Click
Dialog("DVD Ripper Series").WinButton("Install").Click
Dialog("DVD Ripper Series").WinCheckBox("Run DVD Ripper Series").Set "OFF"
Dialog("DVD Ripper Series").WinButton("Finish").Click
这个脚本是原先我的一位同事所编写的,
如果我想在Dialog("DVD Ripper Series").Static("License Version").后插入检查点,但是无法在Active Screen中选中置检查点的文字",license version" 这是如何处理的?
作者:
chenbo81516
时间:
2008-4-15 10:25
这个脚本得复了,我得新贴一下
'Import SourceRef.xls
DataTable.ImportSheet "C:\Source\SourceRef.xls","DVD Ripper Series","Action1"
'''''''''''''''''''''''''''''''''''''''''''''Xilisoft DVD Ripper Series'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
SystemUtil.Run DataTable("SrcPath", dtLocalSheet), "", "C:\Source\DVD Ripper Series", "open"
Dialog("Installer Language").WinComboBox("Please select a language.").Select "English"
Dialog("Installer Language").WinButton("OK").Click
Dialog("DVD Ripper Series").Static("License Version").Check CheckPoint("Please review the license terms before installing Xilisoft DVD Ripper Platinum 5 0..34.0409")
Dialog("DVD Ripper Series").WinButton("I Agree").Click
Dialog("DVD Ripper Series").WinEdit("Edit").SetSelection 0,1
Dialog("DVD Ripper Series").WinEdit("Edit").Set DataTable("InsPath", dtLocalSheet)
Dialog("DVD Ripper Series").WinButton("Next >").Click
Dialog("DVD Ripper Series").WinButton("Install").Click
Dialog("DVD Ripper Series").WinCheckBox("Run DVD Ripper Series").Set "OFF"
Dialog("DVD Ripper Series").WinButton("Finish").Click
这个脚本是原先我的一位同事所编写的,
如果我想在Dialog("DVD Ripper Series").Static("License Version").后插入检查点,但是无法在Active Screen中选中置检查点的文字",license version" 这是如何处理的?
作者:
jackymail
时间:
2008-4-15 10:31
不明白什么意思。
可以回放时在需要的地方插入断点,停下来再加入检查点。。
作者:
chenbo81516
时间:
2008-4-15 10:34
jackymail有msn吗,加我
jingling.xue@hotmail.com
我可以详细的给你描述一下
作者:
chenbo81516
时间:
2008-4-15 12:47
有人吗
作者:
dreamever
时间:
2008-4-15 13:19
两种解决方法:
1、如果那段脚本是录制生成的,只是现在找不到active screen的话,你可以启用update mode run模式,然后把脚本执行一下,这样QTP就能把active screen恢复,你也可以在上面设置检查点了;
2、如果那段脚本不是录制生成的,那么上面的方法没用,最好的办法就使用getroproperty方法获取界面对象的属性,然后使用if else语句判断是否一致,最后用reporter.ReportEvent方法来输出比较结果。这个结果会自动显示在QTP的测试报告中,具体的用法去查一下QTP对象模式的说明文档吧
作者:
chenbo81516
时间:
2008-4-15 16:23
update mode run模式启用不了呀,状态一直是disable
欢迎光临 51Testing软件测试论坛 (http://bbs.51testing.com/)
Powered by Discuz! X3.2