首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 281 毫秒
1.
针对单一UML模型测试不充分的问题,结合UML2.0交互概览图的特点开展测试方法研究,提出一种测试线索自动生成的方法。首先,给出UML类图、顺序图、交互概览图(OID)的形式化定义;通过提取交互概览图的流程信息和对象交互信息分别构造节点控制流图(NCFG)和消息序列图(MSD);将从MSD提取的消息路径嵌入到NCFG中,构造可测试交互概览图模型;最后采用两两覆盖准则生成测试线索。实验验证了该方法自动生成的测试线索在保证测试充分性的前提下可避免组合爆炸。  相似文献   

2.
统一建模语言(UML)无法精确描述系统模型,只能从某一层面描述系统信息,从而导致基于UML模型的多态测试不完备。为此,提出一种带OCL约束的多态路径测试线索生成方法。通过在类图中加入OCL约束信息,考虑类图中多态性对测试的影响,结合UML类图、状态图及协作图,设计并构造OCL约束下包含多态和状态信息的消息间受限控制流图(MRCFG),应用唯一MRCFG路径覆盖准则生成测试线索。通过建立原型工具自动生成包含多态信息的测试线索,从而证明该方法提高了测试的自动化程度,并且生成的多态测试线索更完备。  相似文献   

3.
基于消息序列的形式化面向对象软件测试技术   总被引:1,自引:1,他引:1  
赖祥伟  张为群 《计算机科学》2002,29(10):153-155
本文分析了UML交互图和状态图中的消息提取机制,构造了使用形式化描述语言RAISE对UML图中提取的消息进行描述、规约和精华,最终生成测试用例的测试流程,提出了基于消息序列的面向对象软件自动测试方法,并且在此基础上提出了检测OO系统容错能力的测试用例构造方法。  相似文献   

4.
基于UML时序图的集成测试序列自动生成   总被引:5,自引:0,他引:5  
该文研究了基于UML时序图的集成测试序列自动生成方法。该方法分析了时序图的语义信息并添加语义约束规约生成可测试模型,从中提取相关信息生成有限状态机;然后使用Wp方法构造测试序列;最后使用中国邮递员算法对Wp方法进行改进生成最优测试序列。该方法生成的测试序列长度相对较短,并能充分满足测试用例覆盖需求。  相似文献   

5.
基于UML状态图的模型信息自动提取技术研究   总被引:1,自引:0,他引:1  
宋瑾钰  魏仰苏 《计算机工程与设计》2007,28(20):4860-4861,4864
UML是OMG用于软件系统的可视化、详述、构造和文档化的统一建模语言,状态图是UML模型的重要组成部分,用于描述系统的动态行为.在研究Rational Rose及其状态图文档的基础上,提出了通过UML状态图自动提取模型信息的两种方法-基于LALR(1)文法和基于Rose的扩展接口的提取方法,并对两种方法进行了比较分析.自动提取模型信息技术提高了协议测试序列的自动生成效率.  相似文献   

6.
UML协作图能够描述对象之间动态的交互关系及对象之间消息传递的过程,根据协作图中的消息流和控制流可以获取有用的场景模型并生成测试用例。本文在研究UML协作图和确定有穷自动机(DFA)之间对应关系的基础上,提出一种将UML协作图转换为DFA,再从DFA中提取测试场景生成测试用例的方法,并将该方法应用于实际项目的测试用例生成。最后,通过对结果进行数据对比和分析,说明该测试用例生成方法的有效性。  相似文献   

7.
根据类对象之间的消息通信产生的同步消息、消息传递以及消息等待的交互特征,设计了一种有向同步交互图(DSIG)模型,提出了类继承的同步交互路径(SIAPaths)测试用例生成方法,给出了自动生成同步交互路径的算法.同时,提出了同步交互序列测试充分性准则,并从基本交互路径序列和基本交互消息序列的测试覆盖率两方面阐述了测试的可行性.  相似文献   

8.
一种基于UML动态视图的测试场景生成方法   总被引:1,自引:0,他引:1  
赵欣  刘琳岚  罗海平  樊鑫 《计算机应用》2009,29(5):1385-1392
本文提出一种基于UML动态视图的测试场景生成方法。通过将状态图中对象的状态信息加入顺序图,构建一个基于UML动态视图的测试模型,将其转化为扩展的十字链表结构的有向图;针对测试模型中存在的普通、条件、循环消息类型提出相应的处理方法,采用深度优先算法遍历生成测试场景。在将复杂的UML图转化为测试模型的过程中,应用该方法可以提高所生成场景路径的完整性,同时降低生成场景的冗余度。  相似文献   

9.
提出了一种基于UML序列图的面向对象类簇级测试的方法.这种方法根据序列图进行分析提取类交互信息和用户的输入数据生成测试用例,并根据序列图对代码进行插桩,构造测试模块;最后测试驱动器执行测试模块得到测试结果. 该方法也支持UML2.0 中为序列图添加的新特征.  相似文献   

10.
一种基于UML的集成测试线索的生成方法   总被引:2,自引:0,他引:2  
本文在总结生成集成测试线索研究现状的基础上提出了一种有效解决组合爆炸并且生成测试线索少的集成测试线索生成方法,并根据此方法实现了一个集成测试线索生成工具.该方法根据被测系统集成测试线索具有层次的特点,首先利用例间顺序依赖关系活动图(UCSDAD)提取系统用例间的测试线索,然后通过描述用例交互信息的协作图得到系统中每个用例的测试线索,最后将得到的系统用例间测试线索中的用例替换为相应的用例测试线索,从而可以生成系统集成测试线索.  相似文献   

11.
UMLTGF:一个基于灰盒方法从UML活动图生成测试用例的工具   总被引:8,自引:0,他引:8  
UML已经成为建模语言的事实标准,如何从UML分析设计模型生成测试用例也为面向对象软件测试带来了新的挑战.为了从UML设计模型中的活动图直接生成测试用例,给出了UML活动图的形式化定义和灰盒测试方法.该方法首先分析UML活动图上的所有执行路径(每条路径称为一个测试场景),然后根据测试场景中的节点和转换所代表的活动及其输入/输出变量、相关约束条件等生成测试用例.并根据该方法实现了一个自动生成测试用例的工具UMLTGF,它可以从Rational Rose的规约文件中提取活动图信息并生成相应的测试用例.该工具能够提高软件测试的效率,降低测试成本.  相似文献   

12.
基于UML活动图的测试研究进展   总被引:2,自引:0,他引:2  
UML活动图不再是状态图的特例,它作为一种独立的模型广泛用于软件的行为建模.基于UML活动图的测试受到业界的普遍欢迎.然而从UML活动图自动生成完整的测试场景\用例成为一个难点.本文对基于UML活动图的测试进行了比较分析,总结了几种从UML活动图生成测试场景\用例的方法及其使用的算法,即反蚂蚁Agent方法、灰盒方法、自适应细菌Agent方法和系统的形式化方法.对这些方法进行了分析与比较,指出一些不足之处.最后对UML活动图测试的发展趋势做了一些展望.  相似文献   

13.
Unified Modeling Language (UML) activity diagrams are widely used to model concurrent interaction among multiple objects. In this paper, we propose a transformation‐based approach to generating scenario‐oriented test cases for applications modeled by UML activity diagrams. Using a set of transformation rules, the proposed approach first transforms a UML activity diagram specification into an intermediate representation, from which it then constructs test scenarios with respect to the given concurrency coverage criteria. The approach then finally derives a set of test cases for the constructed test scenarios. The approach resolves the difficulties associated with fork and join concurrency in the UML activity diagram and enables control over the number of the resulting test cases. We further implemented a tool to automate the proposed approach and studied its feasibility and effectiveness using a case study. Experimental results show that the approach can generate test cases on demand to satisfy a given concurrency coverage criterion and can detect up to 76.5% of seeded faults when a weak coverage criterion is used. With the approach, testers can not only schedule the software test process earlier, but can also better allocate the testing resources for testing concurrent applications. Copyright © 2015 John Wiley & Sons, Ltd.  相似文献   

14.
UML2.0 introduced interaction overview diagrams (IODs) as a way of specifying relationships between UML interactions. IODs are a variant of activity diagrams that show control flow between a set of interactions. The nodes in an IOD are either inline interactions or references to an interaction. A number of recent papers have defined a formal semantics for IODs. These are restricted, however, to interactions that can be specified using basic sequence diagrams. This excludes the many rich modeling constructs available in activity diagrams such as interruptible regions, activity groups, concurrent node executions, and flow final nodes. It is non-trivial to allow such constructs in IODs because their meaning has to be interpreted in the context of interaction sequences rather than activities. In this paper, we consider how some of these activity diagram constructs can be used practically in IODs. We motivate the integration of these constructs into IODs using a NASA air traffic control subsystem and define a formal semantics for these constructs that builds on an existing semantics definition for IODs.  相似文献   

15.
提出了一种新颖的基于UML图自动生成系统测试用例的方法.此方法适用于所有UML建模的系统.用创新性地结合图论知识,对用例图和序列图进行抽象,定义了相应的测试覆盖准则以生成测试用例.通过两级遍历,自动生成系统测试向最,并且达到所提的系统测试覆盖率的要求.能够覆盖所有用例、用例依赖性、以及交互中所有的消息序列.实现最大化的...  相似文献   

16.
UML顺序图的自动验证   总被引:1,自引:0,他引:1  
UML顺序图反映了系统中并发对象之间的消息交互及顺序,在软件建模中占有重要地位。该文对UML顺序图模型的自动验证方法进行了研究,在把UML顺序图转换为Promela语言后,使用模型检验器SPIN来验证系统设计模型是否满足某些关键性质需求。为了加强该方法的适用性,采用可扩展的标记语言XML文件格式定义顺序图模型的外部表示形式,该表示方法遵从OMG的XMI标准,从而使验证过程适用于不同的UML建模环境。  相似文献   

17.
UML-B is a development process framework for Event-B based on a “UML-like” graphical formal notation that provides support for object-oriented modelling concepts, in particular, for class and state machine diagrams. However, this methodology has a gap for mapping requirements to formal specifications. To overcome this issue, we present a proposal for extending UML-B to support a conceptual model to provide an easier starting point for the actual development process. More precisely, we propose two diagrams to facilitate the passing from requirements to the initial formal model: a first one to represent system behavior based on UML 2 interaction overview diagram (IOD) and a second one for system structure based on boundary-control-entity stereotyped class diagram (BCE). We show how to translate the former into an Event-B specification and explain how to link the latter to the original UML-B using a simple ATM example as proof of concept.  相似文献   

18.
Novel techniques and a toolset are presented for automatically testing the conformance of software implementations against partial behavioral models constituted by a set of parameterized UML sequence diagrams, describing both external interactions with users or client applications and internal interactions between objects in the system. Test code is automatically generated from the sequence diagrams and executed on the implementation under test, and test results and coverage information are presented back visually in the model. A runtime test library handles internal interaction checking, test stubs, and user interaction testing, taking advantage of aspect-oriented programming techniques. Incremental conformance checking is achieved by first translating sequence diagrams to Extended Petri Nets that combine the characteristics of Colored Petri Nets and Event-Driven Petri Nets.  相似文献   

19.
基于BISON的 UML语法分析器设计   总被引:1,自引:0,他引:1       下载免费PDF全文
目前基于UML类图和状态图做面向对象软件测试方面已有不少研究,因此研究如何实现一个UML语法分析器有其现实意义。利用BISON设计了一个UML语法分析器,通过对UML文档的词法语法分析,实现了从UML文档中自动提取用于软件测试的信息,提高了软件测试效率。在VC6.0环境下对该分析器仿真,实验结果表明,软件能正确提取测试需要的信息。  相似文献   

20.
测试用例的自动生成是软件测试研究的主要方向之一。针对现有的UML模型驱动测试方法在测试数据生成方面存在低效、无目的性、冗余等问题,提出了基于UML活动图模型驱动的划分测试用例自动生成方法。该方法将测试场景归为五种类型,并为每种类型规划了测试数据取值范围和选择方法。构建了基于该方法的原型工具软件,提供被测软件原模型和数据约束即可生成测试用例。实验结果表明,该方法能够在不降低测试覆盖率的情况下,能生成数量少、针对性强的测试用例集。  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号