基于uml的测试技术的研究

上传人:E**** 文档编号:117930865 上传时间:2019-12-11 格式:PDF 页数:63 大小:1.90MB
返回 下载 相关 举报
基于uml的测试技术的研究_第1页
第1页 / 共63页
基于uml的测试技术的研究_第2页
第2页 / 共63页
基于uml的测试技术的研究_第3页
第3页 / 共63页
基于uml的测试技术的研究_第4页
第4页 / 共63页
基于uml的测试技术的研究_第5页
第5页 / 共63页
点击查看更多>>
资源描述

《基于uml的测试技术的研究》由会员分享,可在线阅读,更多相关《基于uml的测试技术的研究(63页珍藏版)》请在金锄头文库上搜索。

1、 摘 要 -I- 摘摘 要要 随着信息技术的发展,软件规模不断扩大,如何保证和提高软件质量成为软 件工程最为关心的问题之一。软件测试作为保证软件质量的关键技术之一,能够 有效地发现软件中的故障。但是,随着软件开发方法和软件工程的发展,特别是 面向对象技术的广泛应用, 面向对象技术自身的各种特性给软件测试带来了新的 挑战。传统的软件测试方法和技术是基于结构化思想的,较少考虑面向对象技术 的特性,很多情况下它们不能适应面向对象软件的测试。为了对面向对象软件进 行有效的测试,就迫切需要研究面向对象软件的测试方法与技术。 统一建模语言(Unified Modeling Language,UML)是一种

2、描述能力强大并且 涵义直观的标准建模语言。统一建模语言是一种图形化的建模语言,用于明确规 定和构建软件系统开发过程中形成的产品, 它提供多种图元从不同的角度和应用 层次刻画系统特性以及复杂的运行环境。使用统一建模语言 UML 建立的模型图 能够很好的描述面向对象软件各个方面的特性,从而为测试工作提供了不少方 便,而传统的软件测试技术无法有效的对其进行测试。因此,基于被测试软件系 统的 UML模型图的测试及其自动化方法和技术的研究也就成为当前测试领域研 究的热点之一。本文对基于 UML 模型图的测试用例生成方法进行了相应的研究 和探讨。 测试充分性准则是整个软件测试的核心,它直接决定了测试用例的

3、生成,而 测试用例生成是软件测试的关键。本文研究分析了基于 UML 状态图的面向对象 类级测试用例生成技术,所做的研究工作有:将 UML 状态图转换成相应的有限 状态机,根据有限状态机的规格说明信息,按照不同的测试充分性标准,分别提 出算法 1,通过遍历相应的测试树,生成满足状态覆盖标准的测试用例集,和算 法 2,生成满足迁移覆盖标准的测试用例集,并结合一个具体的状态图实例说明 了该方法的使用过程。论文最后还通过一个基于 UML 的研究生管理系统的框架 设计,对 UML 的其他模型图进行相应的测试策略分析。与传统的软件测试方法 相比较,基于 UML 模型图的软件测试具有比较明显的优势,体现在:

4、1、通用 性,测试完全基于 UML 的模型图,减少了模型建立过程;2、形式化,UML 有 基于 UML 的测试技术的研究 -II- 严格的定义,便于实现测试信息的提取和自动化;3、可重用性,实现测试分析 和设计阶段制品的重用。 关键词:关键词:UML;UML 状态图;软件测试;测试用例 Abstract -III- Abstract With the development of information and technology, the scale of software is becoming wider and wider, and in software engineering o

5、ne of the most concerned problem is how to guaranteeing and improving the quality of software. As one of the key techniques of guaranteeing software quality, software testing can effectively detect the faults in the system. As the software developing method and the software engineering process is de

6、veloping rapidly, especially the Object-Oriented techniques are applied extensively, the features of Object-Oriented techniques bring new challenge to software test, and most traditional test methods for structure software are not fit to test Object-Oriented software, there is a need to study Object

7、-Oriented software test method. Unified Modeling Language (UML) is a modeling language with powerful ability and intuitionistic meaning. UML is a graphic language for specifying, visualizing, and constructing the products of software systems. It provides various diagrams to depict system characteris

8、tics and complex environment from different viewpoints and different application layers. UML supports various works during each period of software developing process, it is able to give a good description of software using UML, and this could also give convenience to software test. The traditional t

9、echnology of software test can not test this problem in effect. So the method to test software based on UML is a hot issue in software test researching field. This paper discusses an approach to generating test cases from UML diagrams. The core of sofeware testing is test adequacy criteria.The gener

10、ating test cases are directly determined test adequacy criteria. Test cases generation is a key technique of software testing. This paper researchs and analyses how to obtain test cases from UML state chart for Object-Oriented software at class level. The UML state chart is converted into the corres

11、ponding extend finite state machine. According to the specification information of EFSM, test case set of class is generated based on 基于 UML 的测试技术的研究 -IV- different coverage criteria. The algorithm 1 of test case generation which meet to the state standard coverage metric through test tree are resea

12、rched. The algorithm 2 of test case generation which meet to the migration standard coverage metric. A case of UML state chart study is gived to demonstrate the application of the method. This paper using an example that framework design for postgraduate management system based on UML explains softw

13、are testing by UMLs diagrams.Compare to the traditional software testing methods, the software testing based on UML diagrams has more obvious advantages, reflect in:1.general, the generating test cases are fully based on UML diagrams,the model building process is reduced; 2.formal, the realization o

14、f tests and automated extraction is more facilitate because of strict definition of UML;3.reusability,the realization of reusing the products of the test analysis and design phase. Keywords:UML;UML statechart;sofeware testing;test case 目 录 -V - 目目 录录 摘 要 . I Abstract . III 目 录 V 第一章 引 言 - 1 - 1.1 课题

15、研究的背景和意义 - 1 - 1.2 UML 的发展历程和研究现状 . - 2 - 1.3 本文的主要工作及组织结构 - 3 - 1.3.1 本文的主要工作 - 3 - 1.3.2 本文的组织结构 - 3 - 第二章 软件测试概论 - 4 - 2.1 软件测试 - 4 - 2.2 测试用例 - 7 - 2.3 面向对象软件测试 - 8 - 2.4 软件测试模型 . - 9 - 2.5 基于模型的软件测试 - 11 - 2.6 本章小结 - 11 - 第三章 UML 概述 . - 13 - 3.1 UML 简介 . - 13 - 3.2 UML 的发展 . - 14 - 3.3 UML 建模语言

16、 . - 15 - 3.4 UML 建模语言的主要特点 . - 19 - 3.5 UML 的视角模型 . - 19 - 3.6 UML 逆向工程 . - 20 - 3.7 基于 UML 的软件测试方法 - 21 - 3.8 本章小结 - 23 - 第四章 基于 UML 状态图的测试用例生成 . - 24 - 4.1 UML 状态图 . - 24 - 4.2 扩展的有限状态机 - 25 - 4.3 覆盖标准 - 28 - 4.4 测试用例生成 - 29 - 4.4.1 满足状态覆盖标准的测试用例生成 - 29 - 4.4.2 满足迁移覆盖标准的测试用例生成 - 32 - 4.4.3 与传统的软件测试方法的比较 - 35 - 4.5 本章小结 - 36 - 第五章 基于 UML 的研究生管理系统框架设计及相应测试策略分析 . - 37 - 5.1 建模工具 - 37 - 5.2 系统需求 - 37 - 5.3 系统框架设计及相应测试策略分析 - 39 - 5.3.1 需求建模 - 39 - 5. 3. 2 静态结构模型 - 41 - 基于 UML 的测试技

展开阅读全文
相关资源
正为您匹配相似的精品文档
相关搜索

最新文档


当前位置:首页 > 办公文档 > 其它办公文档

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