autodesk inventor api自动化测试的设计与实现

上传人:w****i 文档编号:111726522 上传时间:2019-11-03 格式:PDF 页数:63 大小:531.23KB
返回 下载 相关 举报
autodesk inventor api自动化测试的设计与实现_第1页
第1页 / 共63页
autodesk inventor api自动化测试的设计与实现_第2页
第2页 / 共63页
autodesk inventor api自动化测试的设计与实现_第3页
第3页 / 共63页
autodesk inventor api自动化测试的设计与实现_第4页
第4页 / 共63页
autodesk inventor api自动化测试的设计与实现_第5页
第5页 / 共63页
点击查看更多>>
资源描述

《autodesk inventor api自动化测试的设计与实现》由会员分享,可在线阅读,更多相关《autodesk inventor api自动化测试的设计与实现(63页珍藏版)》请在金锄头文库上搜索。

1、上海交通大学 硕士学位论文 Autodesk Inventor API自动化测试的设计与实现 姓名:余良飞 申请学位级别:硕士 专业:软件工程 指导教师:赵建军;李玉刚 20100101 Autodesk Inventor API 自动化测试的设计与实现 I Autodesk Inventor API 自动化测试的设计与实现自动化测试的设计与实现 摘 要 软件测试是软件生命周期的一个重要阶段。软件测试技术,特别是软件测试自动化 技术是当前国际软件界最有争议、亟待发展的技术。目前,国内外许多研究机构和公司 都进行了大量的软件测试的研究和应用的工作。录制/回放和数据驱动是目前比较流行 的两种自动化

2、测试框架类型。前者通过自动化工具自动录制用户操作,生成线性脚本。 测试人员通过回放这些脚本来进行回归测试。这种方法的缺点是脚本可重复利用率低, 维护成本非常高。后者数据驱动测试框架,通过分离测试数据与测试脚本,运行时将测 试数据关联至测试脚本,实现多个测试用例共享一段测试脚本,脚本利用率和可维护性 都得到了极大地提高。 本文结合数据驱动的测试理论, 开发了一套 API(Application Programming Interface, 应用程序接口)自动化测试系统,针对 Inventor API 进行测试,从而提供高质量的 API 给用户进行 Inventor 二次开发。 本文分析了数据驱动

3、的自动化测试系统的特征,并研究了 API 测试的过程,最终设 计了基于数据驱动的 API 自动化测试系统,采用 VBScript 作为测试脚本,以 XML 格式 存储数据文件。该系统包括测试输入输出系统、测试用例管理系统和测试执行控制系统 三个子系统。论文通过结构图、流程图、类图等形式详细论述了这三个子系统的设计、 功能与工作流程。其中测试输入输出系统是实现数据驱动测试的关键模块,测试脚本通 过该系统提供的接口获取测试用例文件中的数据, 同时测试脚本也通过该模块实现测试 结果的输出。而测试用例管理系统则提供了功能强大的可视化界面,帮助测试人员根据 不同的测试用例设计方法生成测试用例文件。测试执

4、行控制系统负责测试环境的初始 化、执行测试以及生成测试报告等工作。 本文的最后给出了运用所开发的系统对一个实际的 API 进行测试的例子, 展示了测 Autodesk Inventor API 自动化测试的设计与实现 II 试输入输出系统、 测试用例管理系统和测试执行控制系统如何相互配合完成对测试全过 程的支持,以达到提高测试效率和测试质量的目的。 通过实践可以看出,利用本系统开发测试脚本,测试脚本开发人员利用简单易用的 VBScript 即可编写出高质量的测试脚本。测试用例也可以非常灵活、方便地通过测试用 例管理工具生成。由于脚本与数据分离,测试脚本的维护以及测试用例的扩展都非常方 便,测试

5、人员扩展测试用例后甚至都不需要修改测试脚本,这也是本文设计的测试系统 的显著特点。 关键词 Inventor,API,自动化测试,数据驱动测试 Autodesk Inventor API 自动化测试的设计与实现 III THE DESIGN AND IMPLEMENT OF AUTODESK INVENTOR API AUTOMATION TEST ABSTRACT Software testing is an important stage in the software lifecycle. Software testing technology, and especially the s

6、oftware automation testing technology is the most hot technology in the world wide software area and eager for developing. A lot of institutes and companies around the world have been working on the research of the software test technology. Record/replay and data-driven are two popular automation te

7、st modes. The record/replay mode can generating liner scripts by record the users operations. Then the tester can start the regression test by replay these scripts. The shortcoming of linear script is that it is not easy to reuse the script, and the cost to maintain the script is high. While in the

8、data-driven test mode, the test script and test data are saved separately. The test data will be merged into the test script when it is running. So several test data files can share one same test script. In this way, the script can be easily reused and maintained. This thesis designed an API automat

9、ion testing system with the theory of data-driven testing framework. The system is designed for Inventor API testing and it aims to provide API with high quality to the Inventor add-in developers. This thesis analyzed the character of data-driven automation testing and the API testing process. And i

10、t designed a data-driven automation testing system. VBScript is used as testing script and XML is the standard format of the data files in this system. The system includes Testing Input Output sub-system, Test Case Manager sub-system and Test Executing sub-system. The thesis explained the design, fu

11、nctions and workflow of these three sub-systems by structure charts, flow charts and class charts. The Testing Input Output sub-system is the key component to realize the data-driven testing. It provides the interface for test script to retrieve the data from the test cases files, and output the tes

12、t result to the external files. The Test Case Manager sub-system provides a powerful UI for testers to develop and manage the test cases. The Test Executing sub-system is mainly working on the initial of test environment, executing the script and generating test reports. The thesis introduced an exa

13、mple on applying the testing framework to the Inventor API test in the last chapter. The example shows the cooperation of Test Input Output sub-system, Autodesk Inventor API 自动化测试的设计与实现 IV Test Case Manager sub-system and Test Executing sub-system in the testing process and how they improve the test

14、 efficiency and test quality. From the practice of the system we can found that the test script developer can write out high quality test script with the simple VBScript with our test system. And the test case can also be generated with the Test Case Manager without too much effort. Since the test s

15、cript and test data are separately saved, the testers can easily maintain the script and expand the test cases. And the testers even dont need to modify the test script after expanding the test cases, thats also the most outstanding feature of this testing system. Keywords Inventor, API, automation

16、testing, data-driven testing Autodesk Inventor API 自动化测试的设计与实现 上海交通大学上海交通大学 学位论文原创性声明学位论文原创性声明 本人郑重声明:所呈交的学位论文,是本人在导师的指导下,独立 进行研究工作所取得的成果。除文中已经注明引用的内容外,本论文不 包含任何其他个人或集体已经发表或撰写过的作品成果。对本文的研究 做出重要贡献的个人和集体,均已在文中以明确方式标明。本人完全意 识到本声明的法律结果由本人承担。 学位论文作者签名: 日期: 年 月 日 Autodesk Inventor API 自动化测试的设计与实现 上海交通大学上海交通大学 学位论文版权使用授权书学位论文版权使用授权书 本学位论文作者完全了解学校有关保留、使用学位论文的规定,同 意学校保留并向国家有关部门或机构送交论文的复印件和电子版,允许 论文被查阅和借阅。本人授权上海交通大学可以将本学位论文的全部或 部分内容编入有关数据库进行检索,可以采用影印、缩印或扫描等复制 手段保存和汇编本学位论文。 保密保密,在 年解密后适用本授权书。 本学位

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 学术论文 > 其它学术论文

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号