- 1、本文档共66页,可阅读全部内容。
- 2、有哪些信誉好的足球投注网站(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
软件测试相关度量
清 华 大 学 软 件 学 院 2004年5月11日 2,3,4 5 6 9b 10 12 14 T T F F 9a T F 7 T F At least 3 test cases needed (X = 20, Y = 10) 2,3,4,5,6,7,9a,9b,10,14 (X = 5, Y = 30) 2,3,4,5,9a,12,14 (X = 21, Y = 10) 2,3,4,5,6,7,5,6,7,5,9a,9b,12,14 All-Edges Coverage of P 2,3,4 5 6 9b 10 12 14 T T F F 9a T F 7 T F Infinitely many test cases needed (X = 5, Y = 10) (X = 15, Y = 10) (X = 25, Y = 10) … All-Paths Coverage of P All-Paths testing Generate test data to exercise all distinct paths in a program! a path that makes i iterations through a loop is distinct from a path that makes i+1 iterations through the loop, even if the same nodes are visited in both iterations. Thus, there are an infinite number of paths in the string processing program! All-Paths testing (cont.) 包含的不同执行路径数达520条,对每一条路径进行测试需要1毫秒,假定一年工作365 × 24小时,要想把所有路径测试完,需3170年 2,3,4 5 6 9b 10 12 14 T F 9a T F Y X X Y Y X X Y Y X X X T F 7 T F X X P’s Control and Data Flow Graph How many test cases are needed? 2,3,4 5 6 9b 10 12 14 T F 9a T F Y X X Y Y X X Y Y X X X T F 7 T F X X All-Uses Coverage of P all-statements all-edges boundary-interior loop testing min-max loop testing all-paths all-defs all-uses all-DU-paths all-p-uses all-c-uses C1 C2 subsumes Structural Subsumption Hierarchy all-branches Black Box Test Equivalence Class Boundary Analysis … Testing Levels Testing occurs throughout lifecycle Unit Integration System Acceptance Regression Overall Approach Unit testing (module) Integration testing System testing Acceptance testing White / Black box Black box Black box - requirements Black box - performance Section 2Estimating Number of Test Case Allocating Test Times Estimate No. of Test Cases Time (available time ? available staff)/ (average time to prepare a test case) How many test cases do we need? Cost (available budget) / (average preparation cost per test case) Select the minimum number of the two Example Development budget: $4 million,
文档评论(0)