CN201383144Y - Testing device - Google Patents
Testing device Download PDFInfo
- Publication number
- CN201383144Y CN201383144Y CN200920106465U CN200920106465U CN201383144Y CN 201383144 Y CN201383144 Y CN 201383144Y CN 200920106465 U CN200920106465 U CN 200920106465U CN 200920106465 U CN200920106465 U CN 200920106465U CN 201383144 Y CN201383144 Y CN 201383144Y
- Authority
- CN
- China
- Prior art keywords
- function
- test case
- path
- module
- logic analyzer
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Landscapes
- Debugging And Monitoring (AREA)
Abstract
The utility model relates to a testing device, which comprises a function logic analyzer, a test case input module, a test case and function path mapper, a function preprocessing module, a test case optimizer, an optimal path graphic representation module and an optimal file graphic representation module, wherein the test case input module is connected with the function logic analyzer, the test case and function path mapper is connected with the test case input module, the function preprocessing module is connected with the function logic analyzer, the test case optimizer is connected with the test case input module, and the optimal path graphic representation module and the optimal file graphic representation module are connected with the test case optimizer. The testing device can find out all paths by analyzing nodes and find out all the paths passing through variation points ( at function level) by analyzing variation, thereby assisting procedure testers to program test cases and can also assist programmers to analyze range of influence brought by procedure variation.
Description
Technical field
The utility model relates to a kind of proving installation, especially a kind of proving installation of testing for software modification.
Background technology
After regression test is meant that certain part of software has taken place to change or some mistake is corrected, the test of carrying out for the part that guarantees to change or be modified does not introduce new mistake.A kind of regression tested method is all to resurvey, but time cost and financial cost are very high, especially can't use in big-and-middle-sized software engineering project, generally adopt selectivity regression test method (Regression TestSelection, RTS).One of selectivity regression tested target is after modification of program, thereby only to revising and affected part is tested again. reach and test identical test covering fully.
White-box testing also claims structured testing or logical drive test, it is the construction test procedure according to program inside, whether come the testing product internal actions normally to carry out according to the regulation of design specification book by test, whether every path in the check program can both correctly work by pre-provisioning request.Tested object is regarded a box of opening as, the tester is according to program internal logic structure relevant information, and design or selection test case are tested all logical paths of program, by state at the difference scrutiny program, determine actual state whether with the state consistency of expection.
Program plug-in mounting (Program Ins trumentation) is by insert operation (being called " probe ") in tested program, so that obtain the control stream and the traffic flow information of program, thus the method for realization test purpose.
The device that program flow diagram (flow chart) generates automatically is more, as algoview, autoflowchart or the like, these instruments all are based on statement level, and the figure of drafting is bigger, the overall static path quantity that provides is bordering on astronomical figure, for big-and-middle-sized software project test and inapplicable.
The function calling relationship figure that said apparatus generates can only provide test and call fun, does not consider branch statement.The given overall static path of such function calling relationship figure can not reflect the programmed control flow process truly, more can not do the code revision impact analysis.
Algoview is a simple program flow diagram, and the logic call relation between its statement level only is confined in the function, for the not expression of logical relation of the overall situation of whole project.Simultaneously, this granularity of logic call relation of statement level is too thin, can have influence on the efficient of whole analysis.
This class device does not provide the logical relation between function.Such function calling relationship figure is nonsensical for change impact analysis.Simultaneously, they do not provide the global logic of whole project to call the pass yet.
The utility model content
The purpose of this utility model is the defective at prior art, and a kind of proving installation is provided, to realize analysis and to draw out towards the global path figure of function level, change impact analysis.
For achieving the above object, the utility model provides a kind of proving installation, comprising:
The function logic analyzer;
The test case load module is connected with described function logic analyzer;
Test case and function path mapper; Be connected with described test case load module.
Also comprise: the function pretreatment module is connected with described function logic analyzer.Also comprise: function graphics path representation module is connected with described function logic analyzer; Function text on path representation module is connected with described function logic analyzer.Also comprise: the test path graphical representation module is connected with function path mapper with described test case; Test path text representation module is connected with function path mapper with described test case.Also comprise: the test case optimizer is connected with described test case load module.Also comprise: optimize the graphics path representation module, be connected with described test case optimizer; Optimize the graphic file representation module, be connected with described test case optimizer.
Therefore, the method decorateeed by analysis of the utility model proving installation is found out all paths; Find out all paths by variation point (the function level) by analyzing change, the helper tester writes test case, also can change the coverage of bringing by helper person's routine analyzer.
Description of drawings
Fig. 1 is the structural representation of the utility model proving installation;
One of function calling relationship synoptic diagram when Fig. 2 moves for the utility model proving installation;
Two of function calling relationship synoptic diagram when Fig. 3 moves for the utility model proving installation.
Embodiment
Below by drawings and Examples, the technical solution of the utility model is described in further detail.
Proving installation of the present utility model is by the plug-in mounting to source code, analyze the static father code, generation is towards the local static map of a plurality of functions of function level node, and a plurality of subfunctions are together in series by principal function, realizes the global path figure of whole engineering project.
As shown in Figure 1, the structural representation for the utility model proving installation comprises:
Function logic analyzer 1; Test case load module 2, and function logic analyzer 1 is connected; Test case and function path mapper 3; Be connected with test case load module 2.
Also comprise: function pretreatment module 4, and function logic analyzer 1 is connected; Function graphics path representation module 11, and function logic analyzer 1 is connected; Function text on path representation module 12, and function logic analyzer 1 is connected.Test path graphical representation module 31 is connected with function path mapper 3 with test case; Test path text representation module 32 is connected with function path mapper 3 with test case.Test case optimizer 5 is connected with test case load module 2.Optimize graphics path representation module 51, be connected with test case optimizer 5; Optimize body of an instrument representation module 52, be connected with test case optimizer 5.
The function of each module is as follows:
Function logic analyzer 1 is used for carrying out the analysis of similar compiler according to pretreated function source code;
Function graphics path representation module 11 generates graphic file after being used for 1 analysis of function logic analyzer, carries out forms and shows;
Function text on path representation module 12 is used for showing by the text forms after function logic analyzer 1 is analyzed;
Test case load module 2 is used for software test and needs the input test use-case, test case is collected input;
Test case and function path mapper 3 are used for by the analysis of test case to input, and the test case of reality should be generated the pattern that the function path after the analysis of and function logic analyzer is complementary
Test path graphical representation module 31 generates graphic file after being used for test case and 3 analyses of function path mapper, carries out forms and shows;
Test path text representation module 32 is used for test case and mapper 3 analysis backs in function path show by the text forms;
Function pretreatment module 4 is used to import source code, and carries out pre-service, and setting is decorateeed;
Optimization graphics path representation module 51 generates graphic file after being used for 5 analyses of test case optimizer, carries out forms and shows;
Optimizing body of an instrument representation module 52 is used for showing by the text forms after test case optimizer 5 is analyzed.
Function pretreatment module 4 is carried out pre-service with the source code of the tested software of importing, send into then in the function logic analyzer 1 source code is analyzed, the logic branch of routine analyzer, final to first result set, all possible operating path of this tested software that this first result set the inside comprises;
Above-mentioned first result set is handled, finally formed two kinds of forms of expression, graphic form and textual form, the graphic file of 11 pairs of generations of function graphics path representation module, carry out forms and show, the text of 12 pairs of generations of function text on path representation module carries out forms and shows.
Simultaneously, above-mentioned first result set is poured test case load module 2 into, and test case and function path mapper 3 shine upon the test case of input to first result set then, obtain second result set of a test case; Result set 2 is handled, finally formed two kinds of forms of expression, graphic form and textual form; The graphic file of 31 pairs of generations of test path graphical representation module carries out forms and shows, the text of 32 pairs of generations of test path text representation module carries out forms and shows.
5 pairs second result sets of test case optimizer are optimized, it is the simplest to get its optimum by certain rule, obtain the 3rd result set, the 3rd result set is handled, finally formed two kinds of forms of expression, graphic form and textual form, optimize the graphic file of 51 pairs of generations of graphics path representation module, carry out forms and show, optimize the text of 52 pairs of generations of file representation of file module, carry out forms and show.
As shown in Figure 2, one of function calling relationship synoptic diagram when moving for the utility model proving installation by analysis project version 1, obtains the function calling relationship figure of Item version 1, each function is represented a node among the figure, and directly the logic call relation is represented with arrow.
Lead-in item version 2 again, by with the comparison of Item version 1, obtain the function calling relationship change figure of project, as shown in Figure 3, two of function calling relationship synoptic diagram when moving for the utility model proving installation, the look node that heavy line connects among the figure promptly has the function (in the function definition body code variations being arranged) of change.The limit of heavy line then is all possible paths through this node.
For example:
Main () { f4 (); // call int a=0 in proper order; If (a>1) // condition is selected f1 (); Else f2 (); |
By analyzing, all paths of this project are:
main->f4->f1->f3;
main->f4->f2->f3;
If carry out the comparison of two Item versions, find in the function f 2 variation to have taken place, then node f2 becomes thick line, and thinks that main->f4->f2->f3 is the alternative routing by variation point f2, and the limit of main->f4->f2->f3 correspondence is also become heavy line.
The method that the utility model proving installation is decorateeed by analysis is found out all paths; Find out all paths by variation point (the function level) by analyzing change, the helper tester writes test case, the coverage of also can the change of helper person's routine analyzer bringing etc.
It should be noted last that, above embodiment is only unrestricted in order to the explanation the technical solution of the utility model, although the utility model is had been described in detail with reference to preferred embodiment, those of ordinary skill in the art is to be understood that, can make amendment or be equal to replacement the technical solution of the utility model, and not break away from the spirit and scope of technical solutions of the utility model.
Claims (6)
1, a kind of proving installation is characterized in that comprising:
The function logic analyzer;
The test case load module is connected with described function logic analyzer;
Test case and function path mapper; Be connected with described test case load module.
2, proving installation according to claim 1 is characterized in that also comprising: the function pretreatment module is connected with described function logic analyzer.
3, proving installation according to claim 1 is characterized in that also comprising:
Function graphics path representation module is connected with described function logic analyzer;
Function text on path representation module is connected with described function logic analyzer.
4, proving installation according to claim 1 is characterized in that also comprising:
The test path graphical representation module is connected with function path mapper with described test case;
Test path text representation module is connected with function path mapper with described test case.
5, proving installation according to claim 1 is characterized in that also comprising: the test case optimizer is connected with described test case load module.
6, proving installation according to claim 5 is characterized in that also comprising:
Optimize the graphics path representation module, be connected with described test case optimizer;
Optimize the graphic file representation module, be connected with described test case optimizer.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200920106465U CN201383144Y (en) | 2009-03-25 | 2009-03-25 | Testing device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200920106465U CN201383144Y (en) | 2009-03-25 | 2009-03-25 | Testing device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN201383144Y true CN201383144Y (en) | 2010-01-13 |
Family
ID=41526615
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN200920106465U Expired - Fee Related CN201383144Y (en) | 2009-03-25 | 2009-03-25 | Testing device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN201383144Y (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104281518A (en) * | 2013-07-02 | 2015-01-14 | 腾讯科技(深圳)有限公司 | Terminal application test method, device, system and platform and mobile terminal |
CN105760288A (en) * | 2014-12-15 | 2016-07-13 | 阿里巴巴集团控股有限公司 | Method and device testing rewritten application program |
CN106776348A (en) * | 2017-02-06 | 2017-05-31 | 腾讯科技(深圳)有限公司 | Testing case management and device |
-
2009
- 2009-03-25 CN CN200920106465U patent/CN201383144Y/en not_active Expired - Fee Related
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104281518A (en) * | 2013-07-02 | 2015-01-14 | 腾讯科技(深圳)有限公司 | Terminal application test method, device, system and platform and mobile terminal |
CN105760288A (en) * | 2014-12-15 | 2016-07-13 | 阿里巴巴集团控股有限公司 | Method and device testing rewritten application program |
CN105760288B (en) * | 2014-12-15 | 2019-02-01 | 阿里巴巴集团控股有限公司 | Test the method and device of revised application program |
CN106776348A (en) * | 2017-02-06 | 2017-05-31 | 腾讯科技(深圳)有限公司 | Testing case management and device |
CN106776348B (en) * | 2017-02-06 | 2022-09-09 | 腾讯科技(深圳)有限公司 | Test case management method and device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN100487667C (en) | System and method for automatically testing software unit | |
CN101739339B (en) | Program dynamic dependency relation-based software fault positioning method | |
CN110750459B (en) | Automatic test case generation and test process management method based on white box analysis | |
CN102073587A (en) | Static detection method for inaccessible route in program | |
CN101286132A (en) | Test method and system based on software defect mode | |
CN102662644A (en) | Method for generating test case by using flow chart | |
US20070061641A1 (en) | Apparatus and method for generating test driver | |
CN105426309A (en) | Test case automatic generation method and apparatus | |
CN103218297A (en) | Screening method and device of test data | |
CN104915293A (en) | Software testing method and system | |
CN103294596A (en) | Early warning method for contract-type software fault based on program invariants | |
CN201383144Y (en) | Testing device | |
CN112131116A (en) | Automatic regression testing method for embedded software | |
CN105808438A (en) | Test case reuse method based on function call path | |
US6430705B1 (en) | Method for utilizing virtual hardware descriptions to allow for multi-processor debugging in environments using varying processor revision levels | |
CN104102581A (en) | Method and device for implementing unit testing | |
Ferrari et al. | Characterising faults in aspect-oriented programs: Towards filling the gap between theory and practice | |
Yoshida et al. | On refactoring support based on code clone dependency relation | |
CN102087629A (en) | Agent embedded software-based invariant test method and tool | |
Liuying et al. | Test selection from UML statecharts | |
Krinke | Mining control flow graphs for crosscutting concerns | |
Leuschel et al. | Automated property verification for large scale B models | |
Al-Ashwal et al. | A CASE tool for JAVA programs logical errors detection: Static and dynamic testing | |
Saadatmand | Towards automating integration testing of. NET applications using Roslyn | |
Zoubi et al. | Study the impact of improving source code on software metrics |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
C17 | Cessation of patent right | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20100113 Termination date: 20130325 |