⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 winrunner.txt

📁 测试软件Winrunner的函数集大全包括了所有Winrunner的常用函数
💻 TXT
📖 第 1 页 / 共 3 页
字号:

250、web_cursor_to_link ( link, x, y );移动鼠标指针到某个链接

251、web_cursor_to_obj ( object, x, y );移动鼠标指针到某个对象

252、web_event ( object, event_name [, x , y ] );在指定对象运行一个事件

253、web_file_browse ( object );点击浏览按钮

254、web_file_set ( object, value );在文件类型的对象设置文本值

255、web_find_text ( frame, text_to_find, result_array [, text_before, text_after, index, show ] );返回帧内文本位置

256、web_frame_get_text ( frame, out_text [, text_before, text_after, index ] );返回帧内文本的内容

257、web_frame_get_text_count ( frame, regex_text_to_find, count );返回帧内标准表达式的事件个数

258、web_frame_text_exists ( frame, text_to_find [, text_before, text_after ] );检查帧内指定的文本字符串是否存在

259、web_get_run_event_mode ( out_mode );返回当前的运行模式

260、web_get_timeout ( out_timeout );返回winrunner响应web的最大等待时间

261、web_image_click ( image, x, y );点击一个图片链接或图片

262、web_label_click ( label );点击指定的标签

263、web_link_click ( link );点击朝文本链接

264、web_link_valid ( name, valid );检查url链接是否有效

265、web_obj_get_child_item ( object, table_row, table_column, object_type, index, out_object );返回对象的子对象的物理描述

266、web_obj_get_child_item_count ( object, table_row, table_column, object_type, object_count );返回对象的子对象的个数

267、web_obj_get_info ( object, property_name, property_value );返回对象属性的值

268、web_obj_get_text ( object, table_row, table_column, out_text [, text_before, text_after, index] );返回对象的文本字符串

269、web_obj_get_text_count ( object, table_row, table_column, regex_text_to_find, count ); 返回对象内标准表达式的事件个数

270、web_obj_text_exists ( object, table_row, table_column, text_to_find [, text_before, text_after] );在对象里如果该文本存在,返回该文本

271、web_refresh ( frame );winrunner重新连接指定的帧

272、web_restore_event_default ( );重新设置全部事件为默认值

273、web_set_event ( class, event_name, event_type, event_status );设置事件状态

274、web_set_run_event_mode ( mode );设置事件运行模式

275、web_set_timeout ( timeout );设置winrunner响应web的最大时间

276、web_set_tooltip_color ( fg_color, bg_color );设置webtest工具条的颜色

277、web_sync ( timeout );等待帧的导航完成

278、web_tbl_get_cell_data ( table, row, column, starting_pos, out_text, out_actual_text_length );返回web表内指定单元的内容,开始于指定的字符

279、web_url_valid ( URL, valid );检查url是否有效

280、tbl_get_cell_data ( table, row, column, out_text );返回table里指定单元的内容(加载webtest)

281、tbl_get_cols_count ( table, out_cols_count );返回表的列数(加载webtest)

282、tbl_get_column_name ( table, col_index, out_col_name );返回表里指定列的标题的名称(加载webtest)

283、tbl_get_rows_count ( table, out_rows_count );返回表的行数(加载webtest)

284、web_password_encrypt ( password );将web页面的密码加密

285、set_window ( window [,time] );激活窗口并确定等待时间

286、win_activate ( window );激活窗口

287、win_check_bitmap ( window, bitmap, time [, x, y, width, height ] );比较窗口的位图

288、win_check_gui ( window, checklist, expected_results_file, time );比较窗口的gui数据

289、win_check_info ( window, property, property_value [, timeout ] );检查被请求的窗口属性

290、win_click_help ( window );在窗口点击帮助按钮

291、win_click_on_text (window, string [ ,search_area  [ , string_def  [ , mouse_button ] ] ] );在窗口搜索文本

292、win_close ( window );关闭窗口

293、win_drag (source_window, x, y [, mouse_button ] );从源窗口拖动对象

294、win_drop ( target_window, x, y  );拖动对象到目标窗口

295、win_exists ( window [, time ] );检查窗口是否显示在屏幕上

296、win_find_text ( window, string, result_array [, search_area [, string_def ] ] );返回窗口里字符串的位置

297、win_get_desc ( window, obligatory, optional, selector, out_desc );返回窗口的物理描述

298、win_get_info ( window, property, out_value );返回窗口属性的值

299、win_get_text ( window, out_text [, x1, y1, x2, y2] );从窗口指定区域读取文本

300、win_highlight ( window [, flashes ] );高亮显示窗口

301、win_max ( window );最大化窗口到全屏

302、最小化窗口为一个图标

303、win_mouse_click ( window, x, y [, mouse_button  [, modifier] ] );在窗口点击鼠标

304、win_mouse_dbl_click ( window, x, y [, mouse_button  [, modifier ] ] );在窗口双击鼠标

305、win_mouse_drag ( window, start_x, start_y, end_x, end_y [, mouse_button ] );在窗口做鼠标拖动操作

306、win_mouse_move ( window, x, y );移动鼠标焦点到指定的位置

307、win_move ( window, x, y );移动窗口到一个绝对位置

308、win_move_locator_text ( window, string [ ,search_area  [ ,string_def ] ] );移动鼠标焦点到窗口的某个字符串

309、win_open ( window );打开应用程序窗口

310、win_resize ( window, width, height );调整窗口大小

311、win_restore ( window );恢复窗口从前的大小

312、win_type ( window, keyboard_input );用键盘输入窗口

313、win_wait_bitmap ( window, bitmap, time [, x, y, width, height] );等待窗口位图

314、win_wait_info ( window, property, value, time );等待窗口属性值

315、atan2 ( y, x );返回y/x(正切)的弧度

316、cos ( x );返回余弦值

317、exp ( x );返回e的指数值

318、int ( x );返回实数的整数部分

319、log ( x );返回自然对数

320、sin ( x );返回正弦值

321、sqrt ( x );返回平方根值

322、delete array [ subscript ];删除数组里某个元素

323、split ( string, array [ , field_separators ] );将输入分成区域保存在数组里

324、call test_name ( [ parameter1, parameter2, ... parametern ] );调用其他测试脚本

325、call_chain_get_attr ( property, level, out_value );返回调用链里测试或函数的信息

326、call_chain_get_depth ( );返回调用链选项的个数

327、call_close test_name ( [ parameter1, parameter2, ... parametern ] );调用测试脚本,完成时关闭测试

328、call_ex ( Astra_test_path );从winrunner里调用Astra QuickTest测试

329、return [ expression ];返回测试或函数的结果表达式

330、texit ( [ expression ] );停止执行当前的测试

331、treturn [ ( expression ) ];停止调用测试返回控制调用测试

332、load ( module_name [,1/0 [,1/0 ] ] );载入一个编译过的模块

333、reload ( module_name [,1|0 [,1|0] ]);删除编译过的模块并重新载入内存

334、unload ( [ module | test [ , function_name ] ] );从内存里删除编译模块

335、define_object_exception (recovery_scenario_name, function, window, object, property  [ , value ] );对一个gui对象异常事件定义简单的观察场景

336、define_popup_exception (recovery_scenario_name, function, window );对pop-up事件定义异常

337、define_tsl_exception (recovery_scenario_name, return_code [, TSL_function ] );定义tsl事件异常事件

338、exception_off ( recovery_scenario_name );解除指定的观察场景

339、exception_off_all ( );解除所有的观察场景

340、exception_on (recovery_scenario_name );激活指定的观察场景

341、file_close ( file_name );关闭用file-open打开的文件

342、file_compare ( file1, file2 [ , save_file ] );比较两个文件的内容

343、file_getline ( file_name, out_line );读取文件下一行,并将其分配给一个变量

344、file_open ( file_name, mode );打开或创建指定的文件

345、file_printf ( file_name, format, exp1 [ , exp2,... exp30 ] );按格式打印文件

346、pause ( [ expression ] );暂停测试执行并输出提示信息

347、report_msg ( message );往测试报告里写信息

348、sprintf ( format, exp1, exp2,...expn );返回固定格式字符串到一个变量

349、str_map_logical_to_visual ( logical_string, visual_string );把逻辑字符串转换成形象字符串

350、eval ( statement1 [; statement2;.... statementn;] );评估并执行附属的tsl语句

351、get_unique_filename ( folder_path , file_prefix  , file_extension  , out_filename  , with_underscore );基于指定的前缀,创建唯一的文件名

352、nargs ( );返回参数通过的个数

353、tl_step ( step_name, status, description );把测试脚本分成几块,并在当前测试结果里插入状态信息

354、invoke_application ( file, command_option, working_dir, show );调用windows应用程序

355、dos_system ( expression );执行dos命令

356、ascii ( string );返回字符串第一个字符的asc码

357、compare_text ( str1, str2 [, chars1, chars2 ] );比较两个字符串

358、index ( string1, string2 );显示两个字符串位置

359、length ( string );计算字符串里字符的个数

360、match ( string, regular_expression );寻找字符串里正规表达式的事件

361、substr ( string, position [, length ] );从字符串里提取子字符串

362、tolower ( string );转换全部大写字母到小写字母

363、toupper ( string ); 转换全部小写字母到大写字母

364、end_transaction ( transaction [ , status ] );标记一个性能分析的结束

365、get_time ( );返回当前系统时间

366、start_transaction ( transaction_name ); 标记一个性能分析的开始

367、time_str ( [ expression ] );将返回的整数时间转换成字符串

368、wait ( seconds [, milliseconds] );测试暂停


invoke_application(file,command_option,working_dir,show); 


file:应用程序的文件名,绝对路径; 


command_option:应用程序的参数; 


working_dir:应用程序工作路径; 


show:程序运行时的显示模式;



数据库检查点:标准检查点和运行时检查点 


标准检查点检查行数、列数、内容是否一致;包括defaultcheck仅检查数据库内容是否一致;custom check 可随意组合上面三种方式检查 


运行时检查点检查程序界面上某些控件显示的内容是否在数据库中匹配记录,三种方式:匹配一条、匹配多条、没有匹配记录
 
 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -