CN104794057A - Automatic testing method and device for crossed event - Google Patents

Automatic testing method and device for crossed event Download PDF

Info

Publication number
CN104794057A
CN104794057A CN201510213286.6A CN201510213286A CN104794057A CN 104794057 A CN104794057 A CN 104794057A CN 201510213286 A CN201510213286 A CN 201510213286A CN 104794057 A CN104794057 A CN 104794057A
Authority
CN
China
Prior art keywords
event
automatic test
test cases
tested
item
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.)
Granted
Application number
CN201510213286.6A
Other languages
Chinese (zh)
Other versions
CN104794057B (en
Inventor
刘晓华
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Raisecom Technology Co Ltd
Original Assignee
Raisecom Technology Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Raisecom Technology Co Ltd filed Critical Raisecom Technology Co Ltd
Priority to CN201510213286.6A priority Critical patent/CN104794057B/en
Publication of CN104794057A publication Critical patent/CN104794057A/en
Application granted granted Critical
Publication of CN104794057B publication Critical patent/CN104794057B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

The invention discloses an automatic testing method and device for a crossed event and device. The method comprises the steps that a normal event crossing relationship bank and an abnormal-operation event bank are confirmed; according to the normal event crossing relationship bank and the abnormal-operation event bank, an example set for an automatic test is generated; items to be which need to be tested for a test project are acquired, the example set for the automatic test is looked up according to combination relations of the items to be tested, and examples for the automatic test, matched with every item to be tested, are acquired; according to the examples for the automatic test matched with every item to be tested, the examples for the automatic test correspond to the items to be tested are confirmed, and the examples for the automatic test correspond to the items to be tested are executed to achieve testing on the test project. Through the automatic testing method for the crossed event, batch automatic test on the crossed event can be achieved.

Description

A kind of crossing event automated testing method and device
Technical field
The present invention relates to technical field of measurement and test, espespecially a kind of crossing event automated testing method and device.
Background technology
Along with network integration trend is day by day obvious, the function that telecommunication apparatus is supported is more and more, performance is more and more stronger, the test only carrying out individual module is nowhere near, the demand that module is intersected is increasing, this adds extensive work amount to tester, it is also proposed higher requirement to the skill level of modules simultaneously.
Module crossing event is tested, and comprises the cross-beta between each main points of inside modules and between module and module, also can comprise and be realized by the method for combination, such as: boundary value and equivalence class combination are all that a kind of method of combined test realizes.The test of module crossing event makes again events conflict test, and refers to that a function is just in operational process, the test that another one event or operation is simultaneously disturbed this process, and the collision event judging to perform interference can not cause application software abnormal.
Module cross-beta is many when individual module relative maturity, adopts manual testing, due to the restriction of the project cycle and human resources etc., has introducing automatic test.Mostly traditional automatic test, be the superposition for the few individual feature module of relative variability or individual feature module, forms robotization use-case, is then developed to script, for automatic test after script commissioning according to use-case.But script logic is relatively simple in existing automatic test, be used for regression test, and test period is long, be not suitable for the test carrying out batch.
Summary of the invention
In order to solve the problems of the technologies described above, the invention provides a kind of crossing event automated testing method and device, the batch-automated test of crossing event can be realized.
In order to reach the object of the invention, in first aspect, the invention provides a kind of crossing event automated testing method, described method comprises:
Determine normal event cross reference storehouse and abnormal operation event base, described normal event cross reference storehouse is used for store interleaving module in time, space and mutual relationship functionally, the abnormal operation event that described abnormal operation event base normally runs for storing the described Cross module of impact;
According to described normal event cross reference storehouse and described abnormal operation event base, generate automatic test cases collection;
Obtain the item to be tested that test event needs test, search described automatic test cases collection according to the syntagmatic of described item to be tested, obtain the automatic test cases mated with each described item to be tested;
According to the automatic test cases mated with each described item to be tested, determine the automatic test cases corresponding with described test event, perform the automatic test cases corresponding with described test event to realize testing described test event.
Alternatively, described normal event cross reference storehouse comprises essential option event and option event, and described abnormal operation event base comprises essential option event and option event;
Described according to described normal event cross reference storehouse and described abnormal operation event base, generate automatic test cases collection, specifically comprise:
The essential option event that the essential option event comprised according to described normal event cross reference storehouse and described abnormal operation event base comprise, generates the automatic test cases of specifying crossing event;
The option event that the option event comprised according to described normal event cross reference storehouse and described abnormal operation event base comprise, adopts topological sorting algorithm, generates the automatic test cases of random crossing event;
The automatic test cases of described appointment crossing event and the automatic test cases of described random crossing event form described automatic test cases collection.
Alternatively, described acquisition test event needs the item to be tested of test, searches described automatic test cases collection according to the syntagmatic of described item to be tested, obtains the automatic test cases mated with each described item to be tested, specifically comprises:
Set up test event, described test event comprises at least one Cross module;
Determine that described test event needs the item to be tested of test;
Judge that the syntagmatic of described item to be tested belongs to and specify crossing event relation or random crossing event relation;
If the syntagmatic of described item to be tested belongs to described appointment crossing event relation, then search the automatic test cases collection of described appointment crossing event, obtain the automatic test cases of the described appointment crossing event mated with each described item to be tested;
If the syntagmatic of described item to be tested belongs to described random crossing event relation, then search the automatic test cases collection of described random crossing event, if found, then obtain the automatic test cases of the described random crossing event mated with each described item to be tested, if do not found, then generate the automatic test cases mated with each described item to be tested.
Alternatively, the automatic test cases that described basis is mated with each described item to be tested, determine the automatic test cases corresponding with described test event, specifically comprise:
If there is shut sequence between the automatic test cases that multiple and described item to be tested mates, then according to described shut sequence, determine the automatic test cases corresponding with described test event;
If there is not shut sequence between the automatic test cases that multiple and described item to be tested mates, then the weighted value of the automatic test cases that multiple and described item to be tested mates is arranged, put in order according to described, determine the automatic test cases corresponding with described test event.
Alternatively, the described execution automatic test cases corresponding with described test event, with after realizing testing described test event, also comprises:
Generate test report according to test result, and described test report is analyzed;
According to the analysis of described test report being upgraded to described normal event cross reference storehouse and described abnormal operation event base.
In second aspect, the invention provides a kind of crossing event automatization test system, comprising:
Overall control module, normal event cross reference storehouse, abnormal operation event base and automatic test cases collection;
Described overall control module comprises: normal event cross reference generation module, abnormal operation event generation module, automatic test cases combination producing module and testing execution module;
Described normal event cross reference generation module, for determining described normal event cross reference storehouse, described normal event cross reference storehouse, for store interleaving module in time, space and mutual relationship functionally;
Described abnormal operation event generation module, for determining described abnormal operation event base, the abnormal operation event that described abnormal operation event base normally runs for storing the described Cross module of impact;
Described automatic test cases combination producing module, for generating described automatic test cases collection according to described normal event cross reference storehouse and abnormal operation event base, described automatic test cases collection is for storing automatic test cases;
Described testing execution module, needing the item to be tested of test, searching described automatic test cases collection according to the syntagmatic of described item to be tested for obtaining test event, obtain the automatic test cases mated with each described item to be tested; According to the automatic test cases mated with each described item to be tested, determine the automatic test cases corresponding with described test event, perform the automatic test cases corresponding with described test event to realize testing described test event.Alternatively, described normal event cross reference storehouse comprises essential option event and option event, and described abnormal operation event base comprises essential option event and option event;
Described automatic test cases combination producing module, for generating described automatic test cases collection according to described normal event cross reference storehouse and abnormal operation event base, is specially:
The essential option event that the essential option event comprised according to described normal event cross reference storehouse and described abnormal operation event base comprise, generates the automatic test cases of specifying crossing event;
The option event that the option event comprised according to described normal event cross reference storehouse and described abnormal operation event base comprise, adopts topological sorting algorithm, generates the automatic test cases of random crossing event;
The automatic test cases of described appointment crossing event and the automatic test cases of described random crossing event form described automatic test cases collection.
Alternatively, described testing execution module needs the item to be tested of test for obtaining test event, search described automatic test cases collection according to the syntagmatic of described item to be tested, obtain the automatic test cases mated with each described item to be tested, be specially:
Set up test event, described test event comprises at least one Cross module;
Determine that described test event needs the item to be tested of test;
Judge that the syntagmatic of described item to be tested belongs to and specify crossing event relation or random crossing event relation;
If the syntagmatic of described item to be tested belongs to described appointment crossing event relation, then search the automatic test cases collection of described appointment crossing event, obtain the automatic test cases of the described appointment crossing event mated with each described item to be tested;
If the syntagmatic of described item to be tested belongs to described random crossing event relation, then search the automatic test cases collection of described random crossing event, if found, then obtain the automatic test cases of the described random crossing event mated with each described item to be tested, if do not found, then generate the automatic test cases mated with each described item to be tested.
Alternatively, described testing execution module is used for, according to the automatic test cases mated with each described item to be tested, determining the automatic test cases corresponding with described test event, being specially:
If there is shut sequence between the automatic test cases that multiple and described item to be tested mates, then according to described shut sequence, determine the automatic test cases corresponding with described test event;
If there is not shut sequence between the automatic test cases that multiple and described item to be tested mates, then the weighted value of the automatic test cases that multiple and described item to be tested mates is arranged, put in order according to described, determine the automatic test cases corresponding with described test event.
Alternatively, described system also comprises: the report of test result module, test result and analysis module and knowledge base improve module;
Described test result module, for store test results;
Described test result report and analysis module, for generating test report according to described test result, and analyze described test report;
Described knowledge base improves module, upgrades described normal event cross reference storehouse and described abnormal operation event base for basis to the analysis of described test report;
Described test result module and described knowledge base improve module in described overall control module.
Alternatively, described system also comprises: human-computer interaction module, for receiving subscriber control information, and sends described subscriber control information to described overall control module; Wherein, described subscriber control information comprises operative configuration and operational order.
Alternatively, described system also comprises: crossing event driver module, and described crossing event driver module comprises for driving the abstract driving of normal event cross reference of described normal event cross reference generation module, for driving the abstract driving of abnormal operation event of described abnormal operation event generation module and for driving the automatic test cases combination producing module drive of described automatic test cases combination producing module;
Described system also comprises: drive for driving described testing execution module test execution.
Compared with prior art, the present invention is by setting up normal event cross reference storehouse and abnormal operation event base in advance, and generating automatic test cases according to normal event cross reference storehouse and abnormal operation event base, the risk concealed defects may be there is in what solve that incomplete, the abnormal scenario simulation of crossing event combination brings not; Need the item to be tested tested can determine from automatic test cases in test event, thus achieve batch-automated test; In addition, test result analyzed and upgrades normal event cross reference storehouse and abnormal operation event base according to test result, not only increasing Test coverage degree, also effectively save the test duration.
Other features and advantages of the present invention will be set forth in the following description, and, partly become apparent from instructions, or understand by implementing the present invention.Object of the present invention and other advantages realize by structure specifically noted in instructions, claims and accompanying drawing and obtain.
Accompanying drawing explanation
Accompanying drawing is used to provide the further understanding to embodiment of the present invention technical scheme, and forms a part for instructions, is used from and explains technical scheme of the present invention, do not form the restriction to technical solution of the present invention with the embodiment of the present invention one.
Fig. 1 is the structural representation of the crossing event automatization test system that the embodiment of the present invention provides.
Fig. 2 is the schematic flow sheet of the crossing event automated testing method that the embodiment of the present invention provides.
Fig. 3 is the schematic diagram of the topological sorting algorithm that the embodiment of the present invention provides.
Fig. 4 is the schematic flow sheet of the automatic test that the embodiment of the present invention provides.
Embodiment
For making the object, technical solutions and advantages of the present invention clearly understand, hereinafter will be described in detail to embodiments of the invention by reference to the accompanying drawings.It should be noted that, when not conflicting, the embodiment in the present invention and the feature in embodiment can combination in any mutually.
Can perform in the computer system of such as one group of computer executable instructions in the step shown in the process flow diagram of accompanying drawing.Further, although show logical order in flow charts, in some cases, can be different from the step shown or described by order execution herein.
Fig. 1 is the structural representation of the crossing event automatization test system that the embodiment of the present invention provides.In the embodiment of the present invention, crossing event automatic test course can be divided into the next stage: normal event cross reference storehouse and abnormal operation event base formation stages, robotization use-case generation phase, robotization use-case perform and result generation phase and normal event cross reference storehouse and abnormal operation event base optimizing phase.
Based on each stage of crossing event automatic test course, as shown in Figure 1, the crossing event automatization test system that the embodiment of the present invention provides comprises: human-computer interaction module 110, overall control module 120, crossing event driver module 130, normal event cross reference storehouse 140, abnormal operation event base 150, automatic test cases collection 160, test execution driving 170, test result report and analysis module 180 and crossing event storehouse 190.
Wherein, overall control module 120 comprises: normal event cross reference generation module 111, abnormal operation event generation module 112, automatic test cases combination producing module 113, testing execution module 114, test result module 115 and knowledge base improve module 116; Crossing event driver module 130 comprises the abstract driving of normal event cross reference 131, the abstract driving 132 of abnormal operation event and automatic test cases combination producing module drive 133.
Human-computer interaction module 110, for receiving subscriber control information, and pass to overall control module 120, mutual by human-computer interaction module 110 and overall control module 120, overall control module 120 is configured according to subscriber control information equipment (this equipment comprises test event to be tested) to be tested and tests, and goes back store test data information, store test data amendment information etc. simultaneously.Wherein, subscriber control information comprises operative configuration and operational order, for telecommunication apparatus, can comprise the management address of equipment, order, concrete configuration etc. to equipment.
Overall control module 120, for the communication between responsible own module and coordinate other modules and complete test process, wherein:
Normal event cross reference generation module 111, for generating normal event cross reference storehouse;
Abnormal operation event generation module 112, for generating abnormal operation event base;
Automatic test cases combination producing module 113, for according to the normal cross reference storehouse generated and abnormal operation event base, generates robotization set of uses case according to algorithm combination;
Testing execution module 114, for the execution, test record generation, detailed problems record etc. tested, the execution wherein tested specifically can comprise the item to be tested obtaining the test of test event needs, search automatic test cases collection according to the syntagmatic of item to be tested, obtain the automatic test cases mated with each item to be tested; According to the automatic test cases mated with each item to be tested, determine the automatic test cases corresponding with test event, perform the automatic test cases corresponding with test event to realize testing test event;
Further, testing execution module 114 needs the item to be tested of test for obtaining test event, search automatic test cases collection according to the syntagmatic of item to be tested, obtains the automatic test cases mated with each item to be tested, is specially:
Set up test event, test event comprises at least one Cross module;
Determine that test event needs the item to be tested of test;
Judge that the syntagmatic of item to be tested belongs to and specify crossing event relation or random crossing event relation;
If the syntagmatic of item to be tested belongs to specify crossing event relation, then search the automatic test cases collection of specifying crossing event, obtain the automatic test cases of the described appointment crossing event mated with each item to be tested;
If the syntagmatic of item to be tested belongs to random crossing event relation, then search the automatic test cases collection of random crossing event, if found, then obtain the automatic test cases of the random crossing event mated with each item to be tested, if do not found, then generate the automatic test cases mated with each item to be tested.
Further, the automatic test cases that testing execution module 114 is mated with each item to be tested for basis, determine the automatic test cases corresponding with test event, be specially:
If there is shut sequence between the automatic test cases that item multiple and to be tested mates, then according to shut sequence, determine the automatic test cases corresponding with test event;
If there is not shut sequence between the automatic test cases that item multiple and to be tested mates, then the weighted value of the automatic test cases that multiple and item to be tested mate is arranged, according to putting in order, determine the automatic test cases corresponding with test event.
Test result module 115, for On-board test progress and test result;
Knowledge base improves module 116, and for not occurring that the crossing event of expected results is analyzed, the error probability that can be formed after multiple exercise based on crossing event distributes, thus when edition upgrading is tested, is issued to higher coverage in the situation that risk is less;
Crossing event driver module 130, for mutual with overall control module 120, carries out the management and dispatching of model and realization, wherein:
The abstract driving 131 of normal event cross reference, for driving normal event cross reference generation module;
The abstract driving 132 of abnormal operation event, for driving abnormal operation event generation module;
Automatic test cases combination producing module drive 133, for driving automatic test cases combination producing module.
Normal event cross reference storehouse 140, for store interleaving module such as, in time, space and mutual relationship functionally, trigger condition and dependence etc.
Particularly, normal event cross reference storehouse 140 is first set up according to test experience by normal event cross reference generation module 121, such as, because the Cross module of the reason formation such as operating habit, testing requirement, module realization itself is in time, space and logical relation functionally.Normal event cross reference storehouse comprises essential option event and option event, and essential option event comprises selected server as carried out the distributed installation process of webmaster to server and client side, starts selected server, selected client in selected server startup situation, open the events such as selected client; Then supplement normal event cross reference according to follow-up test result, option event checks the events such as nms process ruuning situation as carried out server and client side when can also comprise startup of server in the distributed installation process of webmaster.
Abnormal operation event base 150, for storing the abnormal operation event affecting Cross module and normally run.
Particularly, abnormal operation event base 150 is first set up according to the anomalous event easily gone wrong in test experience by abnormal operation event generation module 122.Abnormal operation event base comprises essential option event and option event, and essential option event cannot select the events such as client, server exception closedown and the abnormal closedown of client under cannot starting selected server, selected server startup situation in the distributed installation process of webmaster as carried out server and client side; Then supplement anomalous event according to follow-up test result, option event cannot check the events such as nms process ruuning situation as carried out server and client side when can also comprise startup of server in the distributed installation process of webmaster;
Automatic test cases collection 160, comprise and specify the automatic test cases of crossing event and the automatic test cases of random crossing event, wherein, the essential option event that the essential option event comprised according to normal event cross reference storehouse and abnormal operation event base comprise, generates the automatic test cases of specifying crossing event; The option event that the option event comprised according to normal event cross reference storehouse and abnormal operation event base comprise, adopts topological sorting algorithm, generates the automatic test cases of random crossing event;
Test execution drives 170, for driving testing execution module 114;
Test result report and analysis module 180, generate report for gathering test result in test result module 115, the form of report is optional.For the problem in result, can carry out that problem gathers, chart display, point out the position and reason that have problems, to facilitate orientation problem;
Crossing event storehouse 190, comprise normal event cross reference storehouse 140 and abnormal operation event base 150, be understandable that, normal event cross reference storehouse 140 and abnormal operation event base 150 both can be co-located in crossing event storehouse 190, or, arrange independently.
Based on the crossing event automatization test system shown in Fig. 1, Fig. 2 is the schematic flow sheet of the crossing event automated testing method that the embodiment of the present invention provides.As shown in Figure 2, comprise the steps:
Step 21, determines normal event cross reference storehouse and abnormal operation event base.
In this step, normal event cross reference generation module generates according to test experience and is used for the normal event cross reference storehouse of store interleaving module in time, space and mutual relationship event functionally; Abnormal operation event generation module generates for storing the abnormal operation event base affecting the abnormal operation event that Cross module normally runs according to test experience.The event in normal event cross reference storehouse all comprises essential option event and option event, and normal event cross reference storehouse and abnormal operation event base can be used for the module performing test share and call.
Step 22, according to normal event cross reference storehouse and abnormal operation event base, generates automatic test cases collection.
In this step, specify crossing event to derive from essential option event that normal event cross reference storehouse comprises and the essential option event that abnormal operation event base comprises; Random crossing event derives from option event that normal event cross reference storehouse comprises and the option event that abnormal operation event base comprises.Import in the model bank of automatization test system by specifying crossing event and random crossing event, model bank generates respectively specifies the automatic test cases of crossing event and the automatic test cases of random crossing event, specifies the automatic test cases of crossing event and the automatic test cases of random crossing event to form described automatic test cases collection.In addition, according to the configuration of automatic test cases collection and equipment, the configuration file that generation equipment can identify, as the input of subsequent automated test, how generating configuration file belongs to the known of those skilled in the art, is not repeated herein.
In in preferred enforcement of the present invention, topological sorting algorithm belongs to depth-priority-searching method, refers to that formation generic sequence instruction event occurs to there being the loop-free relation event of order to sort in event relation use-case.
Such as, shown in figure 3, telecommunication apparatus needs webmaster to manage, webmaster management system is divided into two large divisions: NM server and NM client, here for the startup of the distributed installation system of webmaster, correctly install in network management system, and system computerized normally start after start, A is startup of server, B is server closing, when C is startup of server, client 1 is opened, D is that client 1 is closed, when E is startup of server, client 2 is opened, F is that client 2 is closed, G is selected server, H is selected client 1, I is selected client 2, J checks nms process ruuning situation when NM server starts, K is selected for cancelling.Such as, A can be selected to arrive the path of B through C, path is ACHDGB, illustrates the flow process that server and client side starts and closes: in startup of server-> startup of server situation, client 1 is opened-> and selected client 1-> client 1 and close-> selected server-> server closing; Further, also other path can be selected to travel through successively, such as, another path can be: ACHK, represents a kind of abnormal operating process: in startup of server-> startup of server situation, client 1 is opened-> and selected client 1-> and cancel selected.
Step 23, obtain the item to be tested that test event needs test, automatic test cases collection is searched according to the syntagmatic of item to be tested, obtain the automatic test cases mated with each item to be tested, according to the automatic test cases mated with each item to be tested, determine the automatic test cases corresponding with test event, perform the automatic test cases corresponding with test event to realize testing test event.
Step 24, generates test report according to test result, and analyzes test report, upgrades normal event cross reference storehouse and abnormal operation event base according to the analysis of test report.
Whether, in this step, after having tested, test result report and analysis module generate test report automatically according to test result, wherein test and complete and whether can complete the output state tested and judge according to verifying output state.
Test report comprises the test case number of combination and percent of pass, the concrete configuration of each test case and event, the information such as the details of the implementation status of each test case and the concrete check post of each test case.
Test report is generated according to test result, can periodically analyze test report, also some test report can be selected to analyze, such as, every 20 test report are carried out adding up or select 5 test results and are added up, the mode of array can be adopted to calculate implementation rate, mortality, average performance times etc. that automatic test cases concentrates crossing event, bubbling method is utilized to sort respectively, form the crossing event relation with different weighted value, normal event cross reference storehouse and abnormal operation event base are upgraded.
In addition, do not comprise can carry out adding and recording failed probability if mortality use-case from high to low can be contrasted successively.When carrying out the test of edition upgrading or test before issuing, can select carry out coverage test by weighted value, while greatly improving Test coverage degree, also effectively save time cost.
The schematic flow sheet of the automatic test that Fig. 4 embodiment of the present invention provides, the flow process of this automatic test is illustrating above-mentioned steps 23.As shown in Figure 4, comprise the steps:
Step 231, sets up test event.
Particularly, crossing event automatization test system runs on a client device, and receives the control information of user by human-computer interaction module, and when user needs to test, a newly-built test event, this test event at least comprises a Cross module.
Step 232, determines that test event needs the item to be tested of test.
Particularly, test event comprises at least one item to be tested, selects event to need the item to be tested of test as test event according to testing requirement in crossing event storehouse.Event in crossing event storehouse comprises essential option event and option event, in actual applications, can set to be defaulted as and select essential option event.
The configuration file of item to be tested is generated respectively according to Equipments Setting and the event selected in crossing event storehouse.In actual applications, if do not select crossing event storehouse option event, setting acquiescence uses the configuration file of the automatic test cases collection generated, to save time.
In addition, outgoing position and the file display format of test record and test report can also be set at the configuration file generating item to be tested.
Step 233, judge that the syntagmatic of item to be tested belongs to and specify crossing event relation or random crossing event relation, if the syntagmatic of item to be tested belongs to specify crossing event relation, enter step 234, if the syntagmatic of item to be tested belongs to random crossing event relation, enter step 235.
Step 234, searches the automatic test cases collection of specifying crossing event, obtains the automatic test cases of the appointment crossing event mated with each item to be tested, then enters step 238.
Specify crossing event relation to derive from essential option event that normal event cross reference storehouse comprises and the essential option event that abnormal operation event base comprises, therefore can find specifying the automatic test cases collection of crossing event.Particularly, generate the configuration file of read test item, search the automatic test cases collection of specifying crossing event, obtain the automatic test cases of the appointment crossing event mated with each item to be tested.
Step 235, searches the automatic test cases collection of random crossing event, judges to concentrate at the automatic test cases of random crossing event the automatic test cases whether finding and mate with item to be tested, if found, enter step 236, if do not found, enter step 237;
Random crossing event relation derives from the option event in normal event cross reference storehouse and the option event of abnormal operation event base, there are supplementary new option event or abnormal operation event if follow-up, likely cannot concentrate at the automatic test cases of random crossing event and find.
Step 236, obtains the automatic test cases of the random crossing event mated with each item to be tested;
Step 237, generates the automatic test cases mated with each item to be tested.
Particularly, generate random crossing event according to topological sorting algorithm, and generate the automatic test cases of test case as item to be tested of random crossing event.
Step 238, according to the automatic test cases mated with each item to be tested, determines the automatic test cases corresponding with test event.
Particularly, test event comprises at least one item to be tested, by the sequential combination of the automatic test cases of item to be tested according to setting, determine the automatic test cases of test event, such as, if the automatic test cases that item multiple and to be tested mates directly exists shut sequence, then according to shut sequence, the automatic test cases corresponding with test event can be determined; If there is not shut sequence between the automatic test cases that item multiple and to be tested mates, then can arrange the weighted value of multiple automatic test cases mated with test item, according to putting in order, determine the automatic test cases corresponding with test event.
Step 239, performs the automatic test cases of test event to realize testing test event.
Particularly, call testing execution module and perform the automatic test cases of test event, and preferably, in test process, ruuning situation can be checked at any time in test result module and by the end of current test process.
Crossing event automatization test system of the present invention and crossing event automated testing method are corresponding, and therefore, concrete in crossing event automatization test system and crossing event automated testing method realizes details can reference mutually, is not repeated herein.
In the present invention, by setting up normal event cross reference storehouse and abnormal operation event base in advance, and generating automatic test cases according to normal event cross reference storehouse and abnormal operation event base, the risk concealed defects may be there is in what solve that incomplete, the abnormal scenario simulation of crossing event combination brings not; Need the item to be tested tested can determine from automatic test cases in test event, thus achieve batch-automated test; In addition, test result analyzed and upgrades crossing event storehouse according to test result, not only increasing Test coverage degree, also effectively save the test duration.
Although the embodiment disclosed by the present invention is as above, the embodiment that described content only adopts for ease of understanding the present invention, and be not used to limit the present invention.Those of skill in the art belonging to any the present invention; under the prerequisite not departing from the spirit and scope disclosed by the present invention; any amendment and change can be carried out in the form implemented and details; but scope of patent protection of the present invention, the scope that still must define with appending claims is as the criterion.

Claims (12)

1. a crossing event automated testing method, is characterized in that, described method comprises:
Determine normal event cross reference storehouse and abnormal operation event base, described normal event cross reference storehouse is used for store interleaving module in time, space and mutual relationship functionally, the abnormal operation event that described abnormal operation event base normally runs for storing the described Cross module of impact;
According to described normal event cross reference storehouse and described abnormal operation event base, generate automatic test cases collection;
Obtain the item to be tested that test event needs test, search described automatic test cases collection according to the syntagmatic of described item to be tested, obtain the automatic test cases mated with each described item to be tested;
According to the automatic test cases mated with each described item to be tested, determine the automatic test cases corresponding with described test event, perform the automatic test cases corresponding with described test event to realize testing described test event.
2. method according to claim 1, is characterized in that, described normal event cross reference storehouse comprises essential option event and option event, and described abnormal operation event base comprises essential option event and option event;
Described according to described normal event cross reference storehouse and described abnormal operation event base, generate automatic test cases collection, specifically comprise:
The essential option event that the essential option event comprised according to described normal event cross reference storehouse and described abnormal operation event base comprise, generates the automatic test cases of specifying crossing event;
The option event that the option event comprised according to described normal event cross reference storehouse and described abnormal operation event base comprise, adopts topological sorting algorithm, generates the automatic test cases of random crossing event;
The automatic test cases of described appointment crossing event and the automatic test cases of described random crossing event form described automatic test cases collection.
3. method according to claim 2, it is characterized in that, described acquisition test event needs the item to be tested of test, searches described automatic test cases collection according to the syntagmatic of described item to be tested, obtain the automatic test cases mated with each described item to be tested, specifically comprise:
Set up test event, described test event comprises at least one Cross module;
Determine that described test event needs the item to be tested of test;
Judge that the syntagmatic of described item to be tested belongs to and specify crossing event relation or random crossing event relation;
If the syntagmatic of described item to be tested belongs to described appointment crossing event relation, then search the automatic test cases collection of described appointment crossing event, obtain the automatic test cases of the described appointment crossing event mated with each described item to be tested;
If the syntagmatic of described item to be tested belongs to described random crossing event relation, then search the automatic test cases collection of described random crossing event, if found, then obtain the automatic test cases of the described random crossing event mated with each described item to be tested, if do not found, then generate the automatic test cases mated with each described item to be tested.
4. method according to claim 1, is characterized in that, the automatic test cases that described basis is mated with each described item to be tested, determines the automatic test cases corresponding with described test event, specifically comprises:
If there is shut sequence between the automatic test cases that multiple and described item to be tested mates, then according to described shut sequence, determine the automatic test cases corresponding with described test event;
If there is not shut sequence between the automatic test cases that multiple and described item to be tested mates, then the weighted value of the automatic test cases that multiple and described item to be tested mates is arranged, put in order according to described, determine the automatic test cases corresponding with described test event.
5. the method according to any one of Claims 1 to 4, is characterized in that, the described execution automatic test cases corresponding with described test event, with after realizing testing described test event, also comprises:
Generate test report according to test result, and described test report is analyzed;
According to the analysis of described test report being upgraded to described normal event cross reference storehouse and described abnormal operation event base.
6. a crossing event automatization test system, is characterized in that, comprising: overall control module, normal event cross reference storehouse, abnormal operation event base and automatic test cases collection;
Described overall control module comprises: normal event cross reference generation module, abnormal operation event generation module, automatic test cases combination producing module and testing execution module;
Described normal event cross reference generation module, for determining described normal event cross reference storehouse, described normal event cross reference storehouse, for store interleaving module in time, space and mutual relationship functionally;
Described abnormal operation event generation module, for determining described abnormal operation event base, the abnormal operation event that described abnormal operation event base normally runs for storing the described Cross module of impact;
Described automatic test cases combination producing module, for generating described automatic test cases collection according to described normal event cross reference storehouse and abnormal operation event base, described automatic test cases collection is for storing automatic test cases;
Described testing execution module, needing the item to be tested of test, searching described automatic test cases collection according to the syntagmatic of described item to be tested for obtaining test event, obtain the automatic test cases mated with each described item to be tested; According to the automatic test cases mated with each described item to be tested, determine the automatic test cases corresponding with described test event, perform the automatic test cases corresponding with described test event to realize testing described test event.
7. system according to claim 6, is characterized in that, described normal event cross reference storehouse comprises essential option event and option event, and described abnormal operation event base comprises essential option event and option event;
Described automatic test cases combination producing module, for generating described automatic test cases collection according to described normal event cross reference storehouse and abnormal operation event base, is specially:
The essential option event that the essential option event comprised according to described normal event cross reference storehouse and described abnormal operation event base comprise, generates the automatic test cases of specifying crossing event;
The option event that the option event comprised according to described normal event cross reference storehouse and described abnormal operation event base comprise, adopts topological sorting algorithm, generates the automatic test cases of random crossing event;
The automatic test cases of described appointment crossing event and the automatic test cases of described random crossing event form described automatic test cases collection.
8. system according to claim 7, it is characterized in that, described testing execution module needs the item to be tested of test for obtaining test event, described automatic test cases collection is searched according to the syntagmatic of described item to be tested, obtain the automatic test cases mated with each described item to be tested, be specially:
Set up test event, described test event comprises at least one Cross module;
Determine that described test event needs the item to be tested of test;
Judge that the syntagmatic of described item to be tested belongs to and specify crossing event relation or random crossing event relation;
If the syntagmatic of described item to be tested belongs to described appointment crossing event relation, then search the automatic test cases collection of described appointment crossing event, obtain the automatic test cases of the described appointment crossing event mated with each described item to be tested;
If the syntagmatic of described item to be tested belongs to described random crossing event relation, then search the automatic test cases collection of described random crossing event, if found, then obtain the automatic test cases of the described random crossing event mated with each described item to be tested, if do not found, then generate the automatic test cases mated with each described item to be tested.
9. system according to claim 6, is characterized in that, described testing execution module is used for, according to the automatic test cases mated with each described item to be tested, determining the automatic test cases corresponding with described test event, being specially:
If there is shut sequence between the automatic test cases that multiple and described item to be tested mates, then according to described shut sequence, determine the automatic test cases corresponding with described test event;
If there is not shut sequence between the automatic test cases that multiple and described item to be tested mates, then the weighted value of the automatic test cases that multiple and described item to be tested mates is arranged, put in order according to described, determine the automatic test cases corresponding with described test event.
10. the system according to any one of claim 6 ~ 9, is characterized in that, described system also comprises: the report of test result module, test result and analysis module and knowledge base improve module;
Described test result module, for store test results;
Described test result report and analysis module, for generating test report according to described test result, and analyze described test report;
Described knowledge base improves module, upgrades described normal event cross reference storehouse and described abnormal operation event base for basis to the analysis of described test report;
Described test result module and described knowledge base improve module in described overall control module.
11. systems according to any one of claim 6 ~ 9, it is characterized in that, described system also comprises: human-computer interaction module, for receiving subscriber control information, and sends described subscriber control information to described overall control module; Wherein, described subscriber control information comprises operative configuration and operational order.
12. systems according to any one of claim 6 ~ 9, it is characterized in that, described system also comprises: crossing event driver module, and described crossing event driver module comprises for driving the abstract driving of normal event cross reference of described normal event cross reference generation module, for driving the abstract driving of abnormal operation event of described abnormal operation event generation module and for driving the automatic test cases combination producing module drive of described automatic test cases combination producing module;
Described system also comprises: drive for driving described testing execution module test execution.
CN201510213286.6A 2015-04-29 2015-04-29 A kind of crossing event automated testing method and device Active CN104794057B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510213286.6A CN104794057B (en) 2015-04-29 2015-04-29 A kind of crossing event automated testing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510213286.6A CN104794057B (en) 2015-04-29 2015-04-29 A kind of crossing event automated testing method and device

Publications (2)

Publication Number Publication Date
CN104794057A true CN104794057A (en) 2015-07-22
CN104794057B CN104794057B (en) 2017-12-12

Family

ID=53558866

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510213286.6A Active CN104794057B (en) 2015-04-29 2015-04-29 A kind of crossing event automated testing method and device

Country Status (1)

Country Link
CN (1) CN104794057B (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106326116A (en) * 2016-08-17 2017-01-11 北京奇虎科技有限公司 Method and device for testing product
CN106610899A (en) * 2016-12-30 2017-05-03 中国科学院长春光学精密机械与物理研究所 Test case generation method and device
CN106776261A (en) * 2015-11-23 2017-05-31 腾讯科技(深圳)有限公司 Object method of testing and device
CN108255653A (en) * 2018-01-02 2018-07-06 深圳壹账通智能科技有限公司 The test method and its terminal of a kind of product
CN109597762A (en) * 2018-11-28 2019-04-09 平安科技(深圳)有限公司 System transposition method of testing, system, electronic device and computer readable storage medium
CN109857671A (en) * 2019-02-15 2019-06-07 广州视源电子科技股份有限公司 Generation method, device, server and the storage medium of test case
CN110659215A (en) * 2019-09-30 2020-01-07 贵州航天云网科技有限公司 Open type industrial APP rapid development and test verification method
CN110851369A (en) * 2019-11-19 2020-02-28 泰康保险集团股份有限公司 Policy data processing method and device
CN111130938A (en) * 2019-12-25 2020-05-08 北京奇艺世纪科技有限公司 Index acquisition method and device, electronic equipment and computer readable storage medium
CN112506757A (en) * 2020-11-17 2021-03-16 中广核工程有限公司 Automatic test method, system, computer device and medium thereof

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101212362A (en) * 2006-12-26 2008-07-02 中兴通讯股份有限公司 Automatic testing device and method incorporating a variety of testing tools
CN101251798A (en) * 2008-04-01 2008-08-27 中兴通讯股份有限公司 Test case generating method based on relationship
US20140006865A1 (en) * 2012-06-29 2014-01-02 Sap Ag System and method for capturing and using web page views in a test environment

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101212362A (en) * 2006-12-26 2008-07-02 中兴通讯股份有限公司 Automatic testing device and method incorporating a variety of testing tools
CN101251798A (en) * 2008-04-01 2008-08-27 中兴通讯股份有限公司 Test case generating method based on relationship
US20140006865A1 (en) * 2012-06-29 2014-01-02 Sap Ag System and method for capturing and using web page views in a test environment

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106776261A (en) * 2015-11-23 2017-05-31 腾讯科技(深圳)有限公司 Object method of testing and device
CN106326116A (en) * 2016-08-17 2017-01-11 北京奇虎科技有限公司 Method and device for testing product
CN106610899A (en) * 2016-12-30 2017-05-03 中国科学院长春光学精密机械与物理研究所 Test case generation method and device
CN106610899B (en) * 2016-12-30 2020-01-14 中国科学院长春光学精密机械与物理研究所 Test case generation method and device
CN108255653B (en) * 2018-01-02 2021-05-04 深圳壹账通智能科技有限公司 Product testing method and terminal thereof
CN108255653A (en) * 2018-01-02 2018-07-06 深圳壹账通智能科技有限公司 The test method and its terminal of a kind of product
CN109597762A (en) * 2018-11-28 2019-04-09 平安科技(深圳)有限公司 System transposition method of testing, system, electronic device and computer readable storage medium
CN109857671A (en) * 2019-02-15 2019-06-07 广州视源电子科技股份有限公司 Generation method, device, server and the storage medium of test case
CN110659215A (en) * 2019-09-30 2020-01-07 贵州航天云网科技有限公司 Open type industrial APP rapid development and test verification method
CN110851369A (en) * 2019-11-19 2020-02-28 泰康保险集团股份有限公司 Policy data processing method and device
CN111130938A (en) * 2019-12-25 2020-05-08 北京奇艺世纪科技有限公司 Index acquisition method and device, electronic equipment and computer readable storage medium
CN111130938B (en) * 2019-12-25 2021-05-25 北京奇艺世纪科技有限公司 Index acquisition method and device, electronic equipment and computer readable storage medium
CN112506757A (en) * 2020-11-17 2021-03-16 中广核工程有限公司 Automatic test method, system, computer device and medium thereof

Also Published As

Publication number Publication date
CN104794057B (en) 2017-12-12

Similar Documents

Publication Publication Date Title
CN104794057A (en) Automatic testing method and device for crossed event
CN111142867B (en) Service visual arrangement system and method under micro service architecture
Benveniste et al. Diagnosis of asynchronous discrete-event systems: a net unfolding approach
CN104598380B (en) A kind of automated testing method and system based on control
CN101295280B (en) Automatic software debugging method and system
CN109947646A (en) Interface test method, device, computer equipment and storage medium
CN103823747A (en) Automatic regression testing method
CN107861876A (en) Method of testing, device, computer equipment and readable storage medium storing program for executing
CN102222043B (en) Testing method and testing device
CN105095059B (en) A kind of method and apparatus of automatic test
CN105068929A (en) Test script generation method, test script generation device, testing method, testing device and testing system
CN107135390A (en) The automated testing method and system of a kind of TV applications
CN106339312A (en) API (application programming interface) testing method and system
CN110134400A (en) Data capture method, device, electronic equipment and computer readable storage medium
CN109840206A (en) Data test method, apparatus, terminal and storage medium
CN102521700A (en) Electrical network informatization evaluation rapid test system
CN110134574A (en) A kind of software performance testing method, system, medium and electronic equipment
CN108536593A (en) CS Framework Softwares automated testing method based on UI and system
CN103605606B (en) A kind of embedded software test use-case batch execution method that can automatically change
CN104375943A (en) Embedded software black-box test case generation method based on static models
CN109240755A (en) A kind of configuration file comparison method and configuration file Compare System
CN104731587A (en) Unit testing data generating method and unit testing data generating system
CN108491321A (en) test case range determining method, device and storage medium
CN101482596B (en) Fast fault recognition method for multifactor industrial system
CN112597014A (en) Automatic testing method, device, medium and electronic equipment based on data driving

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
EXSB Decision made by sipo to initiate substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant