用户名: 密码: 验证码:
嵌入式软件单元无关性自动测试研究与实现
详细信息    本馆镜像全文|  推荐本文 |  |   获取CNKI官网全文
摘要
软件测试是保证和提高软件可靠性的重要手段,软件单元测试能最早发现程序错误。但在单元测试中己通过功能测试的子模块(子程序)并不一定是完全正确的。子模块还可能存在一些不易被发现的潜在缺陷,这些缺陷不影响本模块的功能正确性但因资源使用不当而影响其它模块的功能,从而导致系统出错,甚至崩溃。为此本文提出了软件模块无关性的概念,即一个子模块的运行不能影响其它模块及整个系统。软件模块无关性概念包括以下七方面:程序空间无关性、数据空间无关性、堆栈空间无关性、I/O空间无关性、寄存器无关性、中断无关性、重复调用无关性。
     现有的嵌入式软件单元测试工具主要是进行功能性的测试,还没有程序模块无关性测试的功能。针对这种情况,本文对软件模块级无关性自动测试的原理和实现方法进行了探索性的研究,目的是实现模块级功能自动测试和七个方面的无关性自动测试,找到针对不同CPU结构的通用测试方法。目前的测试工具与开发工具是分离的两套系统,这不利于尽早发现程序的缺陷,所以我们的最终目标是将该测试工具集成到开发工具中。
     本文初步实现了基于SPCE061A的软件模块级无关性自动测试工具IndependencyTest,其功能包括五个方面的无关性测试:数据空间无关性测试、堆栈空间无关性测试、I/O空间无关性测试、寄存器无关性测试、中断无关性测试。每项无关性测试功能的实现分为四个步骤:被测模块信息的提取、测试方法和测试数据自动构造、测试用例生成及测试结果的输出。对IndependencyTest工具进行的测试结果表明IndependencyTest工具能测试出汇编语言程序在无关性方面的潜在编程缺陷。
Software testing is an important means to ensure and improve the software reliability, software unit testing can be the first to detect errors. The sub-module or subprogram which has passed through function test is not always correct. There may be some potential flaws in the sub-module which are difficult to detect. These flaws do not affect the functional correctness of the module, but impact functions of other modules because of improper use of resources, causing system faults or even collapse. This thesis proposes the concept of software unit independency, that a sub-module can't affect the operation of other modules and the entire system. The concept of software module independency includes seven aspects: code space independency, data space independency, stack space independency, I/O independency, registers independency, interruptions independency test, and duplicated calling independency.
     The current embedded software unit test tools mainly include function test, but there is not independency test. According to this situation, the thesis has done some explorative research on the principle and realization method of automated software unit independency test. The research objective is to realize the seven aspects of automated independency test and find out the universal testing method of various types of CPU. The current testing tools and development tools are separated each other, which is not avail to detect potential flaws early. So the final goal is to integrate the test tool into development tools.
     The thesis primarily realizes the automated unit independency test which based SPCE061A. It includes as following five aspects: data space independency test, stack space independency test, I/O independency test, registers independency test, interruptions independency test. Each function module of independency test includes four steps: the extraction of information, test methods and test data automatically construction, test case generation and the output of the test results. The test results showed that IndependencyTest tool can find out the potential programming flaws of assembly language program.
引文
[1]James E.Strothman.The Ancient History OF system/360[EB/01].http://www.americanheritage.com/articles/magazine/it/1990/3/1990_3_34.shtml.
    [2]Nancy G.Leveson,Clark S.Turner.An Investingation of Therac-25 Accidents[J].IEEE Computer,1993,Vol.26:18-41.
    [3]Martin Schumacher.Year 2000,Y2K,millennium bug[J].IEEE Power Engineering Society Summer Meeting,1999,Vol.2:971-975.
    [4]何云.软件测试与可靠性评估方法研究[EB/01].http://se.csai.cn/testtech/No060.htm.
    [5][Z]http://cordis.europa.eu/esprit/src/intro.htm.
    [6]Hurst,R.S.SPMMS-Information Structures in Software Management[J].Software Engineering Journal,1986,Vol.1:50-57.
    [7]黄锡滋编著.软件可靠性、安全性与质量保证[M].北京:电子工业出版社,2002.
    [8]姚一平,才全.软件可靠性预计与评估方法探讨[J].航空精密制造技术,1993(03):24-27.
    [9]刘纯生,文传源.软件可靠性方法概述[J].北京航空航天大学学报,1987(03):65-76.
    [10]蔡开元著.软件可靠性工程基础[M].北京:清华大学出版社,1995.
    [11]重大研究计划“可信软件基础研究”2007年度项目指南[Z].http://www.nsfc.gov.cn/nsfc/fj/20070919_fj01.doc.
    [12]Edward Kit著,李新华,陈丽容,马立群等译.软件测试过程改进[M].北京:机械工业出版社,2003.
    [13]IEEE Computer Society Software Engineering Standards Subcommittee.IEEE std 1061-1992,IEEE Standard for a Software Quality Metrics Methodology[S].1992.
    [14]屠强.基于CMM的软件过程评估的研究与实现[D].南京航空航天大学,2007.
    [15]I.Rozman,R.Vajde Horvat,J.Gyorkos.United view on ISO 9001 model and SEI CMM[J].Engineering Management Conference,1994.
    [16]IEEE Computer Society Software Engineering Technical Committee.IEEE std 829-1983,IEEE Standard for Software Test Documentation[S].1983.
    [17]Glenford J.Myers.The Art of Software Testing[M].New York:Wiley,c1979.
    [18]John Watkins著,贺红卫,杨芳等译.使用软件测试过程[M].北京:机械工业出版社,2004.
    [19]Elfriede Dustin,Jeff Rashka,John Paul著,Automated Software Testing[M].北京:电子工业出版社,2003.
    [20]孙惠杰,杨晓红.软件测试的自动化[J].哈尔滨师范大学自然科学学报,2003,(05):47-49.
    [21]Daniel J.Mosley,Bruce A.Posey著,邓波,黄丽娟,曹青春等译.软件测试自动化[M].北京:机械工业出版社,2003.
    [22]林科学.软件测试/调试技术应用研究[D].南京气象学院,2004.
    [23][Z]http://www.rational.com/.
    [24][Z]http://www.hp.com/.
    [25][Z]http://www.numega.com/products/vc/vc.html.
    [26][Z]http://www.parasoft.com/insure/home.html.
    [27][Z]http://www.obsoft.com/.
    [28][Z]http://www.segue.com/.
    [39][Z]http://www.soft.com/products/index.html.
    [30][Z]http://ant.apache.org/.
    [31][Z]http://www.diasparsoftware.com/articles/JUnit/jUnitStarterGuide.html.
    [32][Z]http://www.componentsource.com/products/jprobe-suite/index.html.
    [33][Z]http://sourceforge.net/projects/httpunit/.
    [34]刘利枚.基于51系列的嵌入式软件测试系统研究与实现[D].电子科技大学,2005.
    [35]杜晓东.面向嵌入式系统的测试工具的研究[D].电子科技大学,2003.
    [36]深圳华唐科技公司.CodeTEST嵌入式软件在线测试与分析工具在嵌入式系统开发中的应用[J].今日电子,2001,(09):37-38.
    [37]测试工具CodeTest[Z].http://www.gd-emb.com/testing/test_service_07_3.php.
    [38][Z]http://www.telelogic.com/products/logiscope/index.cfm.
    [39]Wind River.Wind River Platform for Consumer Devices,Linux Edition[EB/01].http://www.windriver.com/products/product-notes/Platform-for-Consumer-Devices-le-Not e.pdf.
    [40][Z]http://www.embed.com.cn/testtool/test.asp?testname=ATTOL+Testware.
    [41][Z]http://www.embed.com.cn/testtool/test.asp?testname=VectorCASY.
    [42][Z]http://www.autosoft-jitong.com.cn/products/nmedbox.asp?id=3.
    [43][Z]http://www.visionmc.com/cpin.htm.
    [44][Z]http://company.mcuol.com/coretek/ProductDetail_171.htm.
    [45]Kanglin Li,Mengqi Wu著,曹文静,谈利群等译.高效软件测试自动化[M].北京:电子工业出版社,2004
    [46]罗亚非等编著.凌阳16位单片机应用基础[M].北京:北京航空航天大学出版社,2005.
    [47]官章全,唐晓卫编著.Visual C++6.0编程实例详解[M].北京:电子工业出版社,1999.

© 2004-2018 中国地质图书馆版权所有 京ICP备05064691号 京公网安备11010802017129号

地址:北京市海淀区学院路29号 邮编:100083

电话:办公室:(+86 10)66554848;文献借阅、咨询服务、科技查新:66554700