Software testing method based on combination of control flow graph traversal and slice forward traversal

A software testing method and control flow graph technology, applied in the direction of software testing/debugging, etc., can solve problems such as failure to use, unsafe, adverse effects of slicing technology security, etc., and achieve the effect of improving accuracy

Active Publication Date: 2010-12-15
哈尔滨哈船导航技术有限公司
View PDF2 Cites 17 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0026] 1) Only select and execute the test cases that are newly added, modified or deleted variable definitions use pairs, so the data flow selective regression testing technology typically ignores the test cases that are not modified and traversed;
[0027] 2) The data flow testing technology chooses to traverse the newly added, modified or deleted definition using the right test case, the data flow technology may ignore some test cases, the test case reaches a modified variable definition, but does not reach The use of this variable, these test cases are modified traversal, but non-modified exposed
[0028] 3) Data flow techniques may ignore test cases where modifications reveal, for example, when code deletions do not involve variable definition usage
[0031] 1) When the program P contains a modified assertion statement, the dynamic slicing technology may ignore some test cases exposed by the modification, so this technology is not safe; when the code modification does not change the control flow graph of the program P or add new Variable definitions for other slicing techniques are safe
[0032] 2) Adding an assertion statement or an assignment statement in the program P will have an adverse effect on the security of the slicing technique, for example, adding a new assignment statement s in P, because the slice obtained by the program slicing technique is only included before the program is modified Statements appearing in program P, any test case slice will not contain statement s
But when the program P' contains structural changes, the technique may select test cases for non-modification traversal

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Software testing method based on combination of control flow graph traversal and slice forward traversal
  • Software testing method based on combination of control flow graph traversal and slice forward traversal
  • Software testing method based on combination of control flow graph traversal and slice forward traversal

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0058] The present invention is described in more detail below in conjunction with accompanying drawing example:

[0059] combine figure 2 , mainly includes the following steps:

[0060] Step 1: Create the original program and the modified program control flow graphs G and G′ respectively, and establish the correspondence between each test case and the execution path for each test case in the test case set T before the regression test.

[0061] Step 2: Traverse G and G′ synchronous depth-first search, and compare the statement nodes that can be reached by each traversal. For the node that changes the variable definition, skip to step 3; for the lexical inconsistency between nodes N and N' during the comparison process, select all test cases in T that can reach the node.

[0062] Step 3: First, explain the variables and process quantities used in the forward traversal algorithm ForwardWalk (Pairs):

[0063] Algorithm ForwardWalk(Pairs)

[0064] Enter Pairs: (s i , v i ) ...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention provides a software testing method based on the combination of control flow graph traversal and slice forward traversal. The method improves the traversal strategy of the selective regression testing method based on control flow graph traversal, changes the definitions of variables in codes and introduces the slice forward traversal algorithm; and in the method, all the definition-use pairs vdefine-vuse which are affected directly or indirectly is identified, only the test case of the variable definition-use pairs are selected to traverse, thus avoiding the consumption of test time and effect caused by selecting all the test cases through one node. As the improvement of strategy and the introduction of algorithm only aim at the modification of variable definition and the deletion of code is not considered, the method disclosed by the invention can not influence the safety and increase the selection accuracy of test cases in a certain scope.

Description

technical field [0001] The invention relates to a software testing method. In particular, the invention relates to a selective regression testing method based on the combination of control flow graph traversal and slice forward traversal algorithms in the technical field of regression testing. Background technique [0002] Software testing is accompanied by the production of software. In the early software development process, the meaning of testing was relatively narrow, and testing was equated with "debugging". It was not until 1957 that software testing began to be distinguished from debugging as an activity of finding software defects. At present, the research hotspots of software testing at home and abroad are: software testing process model, unit testing adequacy standard, regression testing, embedded software testing, object-oriented software testing, software quality and complexity measurement, automated test data generation, etc. Among them, regression testing is ...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F11/36
Inventor 李刚高昕睿高峰刘厂张振兴沈志峰
Owner 哈尔滨哈船导航技术有限公司
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products