CN101247292B - Test equipment and method based on universal test meter API - Google Patents

Test equipment and method based on universal test meter API Download PDF

Info

Publication number
CN101247292B
CN101247292B CN2008101008147A CN200810100814A CN101247292B CN 101247292 B CN101247292 B CN 101247292B CN 2008101008147 A CN2008101008147 A CN 2008101008147A CN 200810100814 A CN200810100814 A CN 200810100814A CN 101247292 B CN101247292 B CN 101247292B
Authority
CN
China
Prior art keywords
test
instrumentation
api
storehouse
module
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.)
Active
Application number
CN2008101008147A
Other languages
Chinese (zh)
Other versions
CN101247292A (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.)
ZTE Corp
Original Assignee
ZTE Corp
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 ZTE Corp filed Critical ZTE Corp
Priority to CN2008101008147A priority Critical patent/CN101247292B/en
Publication of CN101247292A publication Critical patent/CN101247292A/en
Application granted granted Critical
Publication of CN101247292B publication Critical patent/CN101247292B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention discloses a test equipment based on the general test meter application programming joint. The equipment comprises a test information input module, a test equipment initializing module, a test script explanation executing module, a test script analysis and amendment module, and a test meter base dynamic load module. Wherein, the test script analysis and amendment module is used for tracing the test action controlling test meter in the test script by transferring the general test meter application program joint (API) layer, according to the level structure of the joint in the general test meter API layer. The test meter base dynamic load module is used for obtaining judgment result from the test script analysis and amendment module, with corresponding load operation of test meter base. The invention further discloses a test method based on the general test meter application programming joint. By adopting the test equipment and method of the invention, the test instrument is enabled to satisfy the requirement in using efficiency for favorable and rapid operation test.

Description

Testing equipment and method of testing based on the general test instrument API
Technical field
The present invention relates to measuring technology, relate in particular to a kind of testing equipment and method of testing based on general test instrument API (API).
Background technology
Fast development along with data communication industry, various data communication new technologies and emerging data communications equipment emerge in an endless stream, thereupon, it is also developed in large quantities and use such as test instrumentation to be used for the measuring technology of data communications equipment test and various special use, universal test instrument.But,,, the demand of test instrumentation each side is also constantly being improved for the needs of adaptive testing along with improving constantly of testing level and deepening continuously of levels of testing.New demand is: test instrumentation also will satisfy the demand on the service efficiency except can satisfying the primary demand on the test function.Thereby can move test rapidly and healthily,, reduce R﹠D costs for data communications equipment manufacturer saves the testing time.
Yet, because actual at present data communications equipment is in the test process of equipment under test, the test instrumentation type that the Test Engineer uses is often a kind of incessantly, and the function of the equipment under test of testing is also a lot, therefore, in whole test process, only use a kind of test instrumentation, and test instrumentation adopts prior art can not run into too big problem when only testing the simple function of equipment under test under the control of testing equipment; When a plurality of functions in the face of multiple test instrumentation and equipment under test participate in test, adopt prior art more insoluble problem will occur, its reason is: according to the otherness on each test instrumentation type, and the otherness that each test instrumentation is provided with based on the test of equipment under test function, when the Test Engineer writes test script on testing equipment, need be at the concrete condition of current test instrumentation, all develop at every turn and be provided with a corresponding interface again, so that current test instrumentation is under the control of testing equipment, by the test of this corresponding interface realization to equipment under test.Like this, the frequent setting of interface between test instrumentation and the equipment under test certainly will cause testing efficiency low, that is to say and can't satisfy above-mentioned new demand.
Below to adopting the existing in prior technology problem to be specifically addressed.
On the one hand, because the otherness of test instrumentation, therefore the Test Engineer is in the function of being familiar with test instrumentation with aspect being provided with, and based on the function of this test instrumentation be provided with and seek or be provided with an interface suitable aspect on the basis and dropped into too much energy, thereby cause the Test Engineer energy can't be concentrated in the realization of testing scheme itself, and the realization of testing scheme itself is only the main purpose of automatic test.On the other hand, because the method difference of test instrumentation definition API, therefore the OO again method of existing processor-oriented method offers user's interface difference.Under this environment, the test script that the Test Engineer writes based on a kind of test instrumentation can't move under other test instrumentation so, and the test script versatility is not strong.
Summary of the invention
In view of this, main purpose of the present invention is to provide a kind of testing equipment based on general test instrument API, adopts this equipment, and test instrumentation can also satisfy the demand on the service efficiency except can satisfying the primary demand on the test function.Thereby can move test rapidly and healthily,, reduce R﹠D costs for data communications equipment manufacturer saves the testing time.
Another object of the present invention is to provide a kind of method of testing based on general test instrument API, adopt this method, test instrumentation can also satisfy the demand on the service efficiency except can satisfying the primary demand on the test function.Thereby can move test rapidly and healthily,, reduce R﹠D costs for data communications equipment manufacturer saves the testing time.
For achieving the above object, technical scheme of the present invention is achieved in that
A kind of testing equipment based on the general test instrument API, this testing equipment comprises detecting information input module, testing equipment initialization module and test script explanation Executive Module, and this equipment also comprises test script analysis and correcting module and test instrumentation storehouse dlm (dynamic loading module); Wherein,
Test script is analyzed and correcting module, after being used to read all test scripts, by calling the general test instrument api layer, and, the test action of control test instrumentation in the described test script is traced back according to the hierarchical structure of interface in the described general test instrument api layer; Wherein, described general test instrument api layer is positioned on the bottom API of existing test instrumentation;
Test instrumentation storehouse dlm (dynamic loading module) is used at described test script analysis and correcting module obtaining result of determination from described test script analysis and correcting module, and carrying out the storehouse load operation of corresponding test instrumentation according to after tracing back the result and judging.
Wherein, described test instrumentation storehouse dlm (dynamic loading module), being further used for obtaining current is the result of determination of single test instrumentation environment, and the bottom API storehouse of loading general test instrument API storehouse and test instrumentation is to the global namespace space.
Wherein, described test instrumentation storehouse dlm (dynamic loading module), being further used for obtaining current is the result of determination of an above test instrumentation environment, and loads the name space of the bottom API storehouse of general test instrument API storehouse and test instrumentation to correspondence.
A kind of method of testing based on the general test instrument API, this method may further comprise the steps:
The hierarchical structure of interface in the level framework of A, structure API and the general test instrument api layer; After test script analysis and correcting module read all test scripts, by calling described general test instrument api layer, and, the test action of control test instrumentation in the described test script is traced back according to the hierarchical structure of interface in the general test instrument api layer; Wherein, described general test instrument api layer is positioned on the bottom API of existing test instrumentation;
B, at described test script analysis and correcting module according to after tracing back the result and judging, obtain result of determination from described test script analysis and correcting module, and carry out the storehouse load operation of corresponding test instrumentation.
Wherein, in the steps A, the mode of the level framework of structure API is specially: increase the general test instrument api layer on the bottom API of described test instrumentation.
Wherein, also comprise behind the step B:
After C, test script explain that Executive Module reads the phase related control information of test script operation in the described test script operation control documents, call interpreter the test script that loads is construed to executable code, on described test instrumentation, carry out described executable code then.
Wherein, among the step B, carrying out the storehouse load operation of corresponding test instrumentation is specially: when test instrumentation storehouse dlm (dynamic loading module) obtains currently when being the result of determination of single test instrumentation environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to the global namespace space.
Wherein, among the step B, carrying out the storehouse load operation of corresponding test instrumentation is specially: when test instrumentation storehouse dlm (dynamic loading module) obtains currently when being the result of determination of an above test instrumentation environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to corresponding name space.
At api layer time framework, the present invention is different from prior art, on the bottom API of existing test instrumentation, increase a general test instrument api layer, and at this general test instrument api layer, unitized overall development also is provided with test instrumentation API.Here, this general test instrument api layer is used for bottom API is encapsulated, and the API client that will offer the upper strata to the unified interface of test instrumentation operation is used, so that finish the test of test instrumentation to equipment under test under the control of testing equipment of the present invention.So, after increasing the general test instrument api layer, the Test Engineer is on testing equipment of the present invention, the unified interface that provides based on this general test instrument api layer is provided writes test script, make the test script of writing under situation about changing, under any one test instrumentation, move, not only improved the versatility of test script, avoided repeatedly writing test script; And shielded the otherness of test instrumentation.Thereby improved testing efficiency, reduced R﹠D costs.
Corresponding to the general test instrument api layer that increases, and the test script of writing based on this general test instrument api layer, testing equipment of the present invention is different from existing testing equipment, has increased test script analysis and correcting module and test instrumentation storehouse dlm (dynamic loading module).Wherein, test script analysis and correcting module are used for by calling the general test instrument api layer, and according to the hierarchical structure of interface in the general test instrument api layer, the test action of control test instrumentation in the test script are traced back.Afterwards, test script analysis and correcting module carry out corresponding operation according to tracing back the result, such as to determine current be single test instrumentation environment or many test instrumentations environment according to tracing back the result, and result of determination are sent to test instrumentation storehouse dlm (dynamic loading module).Test instrumentation storehouse dlm (dynamic loading module) is used for carrying out the storehouse load operation of corresponding test instrumentation according to the result of determination of test script analysis and correcting module.Specifically, when test instrumentation storehouse dlm (dynamic loading module) obtains currently when being the result of determination of single test instrumentation environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to the global namespace space.When test instrumentation storehouse dlm (dynamic loading module) obtains currently when being the result of determination of many test instrumentations environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to corresponding name space.
In sum, adopt the present invention, when test instrumentation changed, testing equipment of the present invention was carried out the storehouse load operation of corresponding test instrumentation according to user's input.Thereby shielded the otherness of test instrumentation.For the Test Engineer, the mode of calling the general test instrument api layer under many test instrumentations environment and the single test instrumentation environment is consistent, only need based on the general test instrument api layer, create corresponding test instrumentation object, and call corresponding method test instrumentation is operated, which, be responsible for by test script analysis and correcting module and test instrumentation storehouse dlm (dynamic loading module) as for the corresponding test instrumentation of method call.Thereby that has improved test script writes efficient and versatility, makes test script be easy to safeguard.
Description of drawings
Fig. 1 is the composition structural representation of testing equipment of the present invention;
Fig. 2 is the realization flow schematic diagram of method of testing principle of the present invention;
Fig. 3 increases the composition schematic diagram of api layer time framework behind the general test instrument api layer for the present invention;
Fig. 4 finishes the schematic diagram that traces back under many test instrumentations of the present invention environment based on the hierarchical structure of interface in the general test instrument api layer.
Embodiment
Core concept of the present invention is: at api layer time framework, the present invention is different from prior art, on the bottom API of existing test instrumentation, increases a general test instrument api layer, and at this general test instrument api layer, unitized overall development also is provided with test instrumentation API.Corresponding to the general test instrument api layer that increases, and the test script of writing based on this general test instrument api layer, testing equipment of the present invention is different from existing testing equipment, has increased test script analysis and correcting module and test instrumentation storehouse dlm (dynamic loading module).Adopt the present invention, not only improved the versatility of test script, avoided repeatedly writing test script; And shielded the otherness of test instrumentation.Thereby improved testing efficiency, reduced R﹠D costs.
Be described in further detail below in conjunction with the enforcement of accompanying drawing technical scheme.
As shown in Figure 1, a kind of testing equipment based on general test instrument API, this equipment comprise detecting information input module 1, testing equipment initialization module 2, test script analysis and correcting module 3, test instrumentation storehouse dlm (dynamic loading module) 4 and test script explanation Executive Module 5.
Wherein, detecting information input module 1 is used to receive the information of user's input.Here, the information of user input comprises the type information of test instrumentation, and the test topology structural information of being made up of test instrumentation and equipment under test.After testing equipment initialization module 2 is used for carrying out initialization according to the information of user input, refresh test script operation control documents.Here, initialization comprises the operation of creating name space according to the type information of user's input test instrument.Here, preserved the phase related control information of test script operation in the test script operation control documents.Testing equipment initialization module 2 starts test script analysis and correcting module 3 and reads all test scripts after carrying out initialization according to the information of user's input.
After test script analysis and correcting module 3 are used to read all test scripts, by calling the general test instrument api layer, and, the test action of control test instrumentation in the test script is traced back according to the hierarchical structure of interface in the general test instrument api layer; Afterwards, test script analysis and correcting module 3 carry out corresponding operation according to tracing back the result.Here, at tracing back, abstract by to test instrumentation constructs the hierarchical structure of interface in the general test instrument api layer, facilitates the use this hierarchical structure test instrumentation is traced back operation.So under this hierarchical structure,,, traverse the operation of carrying out this interface top layer entity from the interface of hierarchical structure lower floor and be and trace back operation according to the logical level of this interface in the hierarchical structure based on an interface of this test action correspondence.Here, the top layer entity is a test instrumentation.Here, corresponding operation comprises: after test script analysis and correcting module 3 generate a new test script, and refresh test script operation control documents.Corresponding operation also comprises: test script analysis and correcting module 3 judge that according to tracing back the result determining current is single test instrumentation environment or many test instrumentations environment, and result of determination is sent to test instrumentation storehouse dlm (dynamic loading module) 4.
Test instrumentation storehouse dlm (dynamic loading module) 4 is used for carrying out the storehouse load operation of corresponding test instrumentation after the result of determination of acceptance test script and correcting module 3.Specifically, when test instrumentation storehouse dlm (dynamic loading module) 4 obtains currently when being the result of determination of single test instrumentation environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to the global namespace space.When test instrumentation storehouse dlm (dynamic loading module) 4 obtains currently when being the result of determination of many test instrumentations environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to corresponding name space.
After test script explains that Executive Module 5 is used for the phase related control information of read test script operation control documents test script operation, call interpreter the test script that loads is construed to executable code such as the JAVA code, on test instrumentation, carry out this executable code then.
As shown in Figure 2, a kind of method of testing based on general test instrument API, this method may further comprise the steps:
The level framework of step 101, structure API, and the hierarchical structure of interface in the general test instrument api layer are write test script based on the general test instrument api layer; Afterwards, after the testing equipment initialization module carries out initialization according to the user's input information that reads from the detecting information input module, refresh test script operation control documents.
In the step 101, the testing equipment initialization module reads user's input information to carry out initialization and comprises the operation of creating name space according to the type information of user's input test instrument.Here, preserved the phase related control information of test script operation in the test script operation control documents.
In the step 101, the mode of the level framework of structure API is specially: increase the general test instrument api layer on the bottom API of existing test instrumentation.
Here, at the level framework of API, as shown in Figure 3, Fig. 3 increases the composition schematic diagram of api layer time framework behind the general test instrument api layer for the present invention.Comprise existing test instrumentation bottom API11 and general test instrument api layer 22 among Fig. 3.And general test instrument api layer 22 offers the API client on upper strata and uses.Wherein, the bottom API11 of existing test instrumentation comprises four part levels, is respectively test instrumentation hardware layer 111, hardware abstraction layer 112, test instrumentation operating system layer 113, test instrumentation bottom function library place layer 114 from the bottom to top.Here it is pointed out that calling existing test instrumentation bottom API11 by general test instrument api layer 22 is finished by the test instrumentation Control Server.The test instrumentation Control Server just calls existing test instrumentation bottom API11 after receiving the call operation of general test instrument api layer 22 triggerings, operates with complete call.And the test instrumentation Control Server can also offer the graphic user interface client and use.The test instrumentation bottom function library here also can be understood as the bottom API storehouse of test instrumentation.
Wherein, because hardware abstraction layer is between test instrumentation hardware layer and test instrumentation operating system layer, so hardware abstraction layer is generally used for downwards directly test instrumentation hardware layer, upwards provides unified interface for the test instrumentation operating system layer.Thereby shielded the hardware differences of test instrumentation.So,, be positioned at owing to the general test instrument api layer that increases on the bottom API of existing test instrumentation, and offer the API client use on upper strata with this type.And at this general test instrument api layer, unitized overall development also is provided with test instrumentation API.Therefore, the general test instrument api layer is used for bottom API is encapsulated, and will offer upper strata API client to the unified interface of test instrumentation operation and use, so that finish the test of test instrumentation to equipment under test under the control of testing equipment of the present invention.Thereby shielded the otherness of test instrumentation.
After step 102, test script analysis and correcting module read all test scripts, by calling the general test instrument api layer, and, the test action of control test instrumentation in the test script is traced back according to the hierarchical structure of interface in the general test instrument api layer; Afterwards, test script analysis and correcting module carry out corresponding operation according to tracing back the result.
Here, corresponding operation comprises: test script analysis and correcting module be according to after tracing back the result and generating a new test script, refresh test script operation control documents.Corresponding operation also comprises: test script analysis and correcting module are judged according to tracing back the result, determining current is single test instrumentation environment or many test instrumentations environment, and result of determination sent to test instrumentation storehouse dlm (dynamic loading module), so that follow-up test instrument storehouse dlm (dynamic loading module) carries out the storehouse load operation of corresponding test instrumentation according to result of determination.
Here, finish at the hierarchical structure of interface in the general test instrument api layer and to trace back, as shown in Figure 4, Fig. 4 finishes the schematic diagram that traces back under many test instrumentations of the present invention environment based on the hierarchical structure of interface in the general test instrument api layer.Fig. 4 has provided the example of an OO hierarchical structure of general test instrument api layer, comprises test instrumentation object 311 among Fig. 4; Port object (po) 321 and dispatcher object 322; Protocol emulation object 331, flow send engine object 332 and statistical analysis engine object 333.And from top to bottom test instrumentation object 311 is positioned at top layer, port object (po) 321 and dispatcher object 322 and is positioned at the intermediate layer, and protocol emulation object 331, flow send engine object 332 and statistical analysis engine object 333 is positioned at bottom.So, under this hierarchical structure, dotted arrow among Fig. 4 represents that bottom from this hierarchical structure is such as protocol emulation object 331, port object (po) 321 via the intermediate layer, traverse the test instrumentation object 311 of top layer, just,, finish from the interface of this hierarchical structure lower floor and traverse the operation of tracing back of carrying out this interface top layer entity according to the logical level of this interface in the hierarchical structure based on an interface of this test action correspondence.Here, the top layer entity is a test instrumentation.Here it is pointed out that every layer to as if by what create corresponding to the class of upper strata object, create port object (po) such as the method for calling the test instrumentation class.
The example that Fig. 4 provides is to face test instrumentation from the logical layer of test instrumentation software function to carry out abstract processing, by the abstract processing of test instrumentation being constructed the hierarchical structure of interface in the general test instrument api layer, facilitate the use this hierarchical structure test instrumentation is traced back operation.Concrete abstraction process is: regard test instrumentation as a concrete object.At first, the polymerization according to class will be decomposed into port class, protocol emulation class, flow transmission engine class and statistical analysis engine class corresponding to the test instrumentation class of test instrumentation object.Other classes that also have some assisted tester table handlings in addition are such as scheduler class and scheduling events class.Then, carrying out level according to the extensive class to each part mentioned above of class divides.Such as derive concrete port class from the port class, exist inheritance between concrete port class and the port class.
So, for instance, under the example of the OO hierarchical structure of this general test instrument api layer, the process of creating a protocol emulation object is as follows:
A1, establishment two test instrumentation object objTester1, objTester2.
A2, make respectively corresponding two test instrumentations of objTester1, objTester2, the IP address Fen Biewei $chassisAddr1, $chassisAddr2 of two test instrumentations.
CTestDevice?objTester1?$chassisAddr1;
CTestDevice?objTester2?$chassisAddr2;
A3, the method for calling the test instrumentation class are created port object (po).
objTester1?CreateTestPort-PortName?objPort1;
objTester2?CreateTestPort-PortName?objPort2;
A4, the method for calling the port class are created the protocol emulation object.
objPort1?CreateRouter-RouterName?objRouter1;
objPort2?CreateRouter-RouterName?objRouter2;
More than the test action of control test instrumentation can be the test instrumentation entity by passing up to the top layer entity of carrying out this test action shown in the dotted arrow among Fig. 4.In this embodiment, the test instrumentation object objTester1 that carries out this test action can be passed up to from objPort1CreateRouter, the test instrumentation object objTester2 that carries out this test action can be passed up to from objPort2 CreateRouter.
Provide the concrete abstraction process of example except Fig. 4, the another one embodiment of the OO hierarchical structure of general test instrument api layer, its concrete abstraction process is: regard test instrumentation as a concrete object and carry out abstract, the class that takes out comprises port class, concrete port class, the protocol emulation class, concrete protocol emulation class.These classes are in parallel relation, just realize these classes based on OO method.This abstraction process adopts the class hierarchy division of this abstraction process each part mentioned above unintelligible, and is unfavorable for improving the development efficiency of test script and the maintenance of test script compared to the concrete abstraction process that Fig. 4 provides example.
Step 103, at test script analysis and correcting module according to after tracing back the result and judging, test instrumentation storehouse dlm (dynamic loading module) obtains result of determination from test script analysis and correcting module, and carries out the storehouse load operation of corresponding test instrumentation.
Here, the load operation of test instrumentation storehouse comprises two kinds of situations.First kind of situation, when test instrumentation storehouse dlm (dynamic loading module) obtains currently when being the result of determination of single test instrumentation environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to the global namespace space.Second kind of situation, when test instrumentation storehouse dlm (dynamic loading module) obtains currently when being the result of determination of many test instrumentations environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to corresponding name space.
After step 104, test script are explained the phase related control information of test script operation in the Executive Module read test script operation control documents, call interpreter the test script that loads is construed to executable code such as the JAVA code, on test instrumentation, carry out this executable code then.
Below at the specific implementation process of step 102, cite an actual example and set forth.The specific implementation process of step 102 may further comprise the steps:
Step 201, test script analysis and correcting module read all test scripts, and each test action in the read test script in order.
Here, each test action in the read test script is by calling the general test instrument api layer, and according to the hierarchical structure of interface in the general test instrument api layer, the test action of control test instrumentation in the test script traced back finish.
Step 202, judge that whether current test action is the control action to tester, if then execution in step 203; Otherwise, change execution in step 205 over to.
Step 203, the principles of construction that provides the concrete abstraction process of example by Fig. 4 go out the hierarchical structure of interface in the general test instrument api layer, and according to this hierarchical structure operation are traced back in the test action of control test instrumentation in the test script.
Here, Fig. 4 principle of providing the concrete abstraction process of example promptly adopts and regards test instrumentation as a concrete object.At first, will decompose corresponding to the test instrumentation class of test instrumentation object, and carry out level according to the extensive each several part class of class then and divide above-mentioned decomposition according to the polymerization of class.
Here, tracing back operation is interface from lower floor, is test instrumentation until traversing the final execution entity of carrying out this test action.
Step 204, judge finally to carry out in the list of entities whether had this executions entity, if there is no, then should carry out entity and write final execution list of entities, and will finally carry out the entity number and add 1 back execution in step 205; Otherwise, direct execution in step 205.
Step 205, judge whether current test script analyzes end, finish that then execution in step 206 if analyze; Otherwise, change execution in step 202 over to.
Step 206, basis are traced back the result and are judged whether this test script is applied to many test instrumentations environment, judge that just whether the final entity number of carrying out is greater than 1, if, then create a new test script, will in the former test script method call of test instrumentation be added execution in step 207 behind the corresponding name space; Otherwise, execution in step 208.
Here, at the method call to test instrumentation in the former test script is added corresponding name space for instance.
Test action is as follows in the former test script:
CTestDevice?objTester1?$chassisAddr1;
CTestDevice?objTester2?$chassisAddr2;
Test action is as follows in the new test script of creating:
::TESTER1::CTestDevice?objTester1?$chassisAddr1;
::TESTER2::TestDevice?objTester2?$chassisAddr2;
So, name space is mapped to the type information of the test instrumentation of user's input in the detecting information input module, has just shielded the otherness of test instrumentation type like this concerning the Test Engineer.And if, then do not need to add again name space to creating the method call of object.
Step 207, refresh test script move control documents, the phase related control information that is applied to the test script operation of many test instrumentations environment are updated to the phase related control information of the test script operation of new establishment.Afterwards, test script analysis and correcting module are carried out the new test script of creating.
Step 208, judge whether all test scripts analyze end, finish, then finish the flow process of current test script analysis and correcting module analysis and correction if analyze; Otherwise, change execution in step 201 over to.
Below at the specific implementation process of step 103, cite an actual example and set forth.The specific implementation process of step 103 is:
Judge according to the final execution entity number that test script analysis and correcting module draw whether this test script is applied to many test instrumentations environment, judge that just whether the final entity number of carrying out is greater than 1; If then current is many test instrumentations environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation so is to corresponding name space.Arrive such as the general test instrument API storehouse of load tester table Tester1 and the bottom API storehouse of test instrumentation:: the TESTER1 name space; Perhaps the bottom API storehouse of the general test instrument API storehouse of load tester table Tester2 and test instrumentation is arrived:: the TESTER2 name space.If not, then current is single test instrumentation environment, and the bottom API storehouse that loads general test instrument API storehouse and test instrumentation so is to the global namespace space, thus compatible test under single test instrumentation environment.
The above is preferred embodiment of the present invention only, is not to be used to limit protection scope of the present invention.

Claims (8)

1. testing equipment based on the general test instrument API, this testing equipment comprises detecting information input module, testing equipment initialization module and test script explanation Executive Module, it is characterized in that this equipment also comprises test script analysis and correcting module and test instrumentation storehouse dlm (dynamic loading module); Wherein,
Test script is analyzed and correcting module, after being used to read all test scripts, by calling general test instrument API api layer, and, the test action of control test instrumentation in the described test script is traced back according to the hierarchical structure of interface in the described general test instrument api layer; Wherein, described general test instrument api layer is positioned on the bottom API of existing test instrumentation;
Test instrumentation storehouse dlm (dynamic loading module) is used at described test script analysis and correcting module obtaining result of determination from described test script analysis and correcting module, and carrying out the storehouse load operation of corresponding test instrumentation according to after tracing back the result and judging.
2. testing equipment according to claim 1, it is characterized in that, described test instrumentation storehouse dlm (dynamic loading module), being further used for obtaining current is the result of determination of single test instrumentation environment, and the bottom API storehouse of loading general test instrument API storehouse and test instrumentation is to the global namespace space.
3. testing equipment according to claim 1, it is characterized in that, described test instrumentation storehouse dlm (dynamic loading module), being further used for obtaining current is the result of determination of an above test instrumentation environment, and loads the name space of the bottom API storehouse of general test instrument API storehouse and test instrumentation to correspondence.
4. the method for testing based on the general test instrument API is characterized in that, this method may further comprise the steps:
The hierarchical structure of interface in the level framework of A, structure API and the general test instrument api layer; After test script analysis and correcting module read all test scripts, by calling described general test instrument api layer, and, the test action of control test instrumentation in the described test script is traced back according to the hierarchical structure of interface in the general test instrument api layer; Wherein, described general test instrument api layer is positioned on the bottom API of existing test instrumentation;
B, at described test script analysis and correcting module according to after tracing back the result and judging, obtain result of determination from described test script analysis and correcting module, and carry out the storehouse load operation of corresponding test instrumentation.
5. method of testing according to claim 4 is characterized in that, in the steps A, the mode of the level framework of structure API is specially: increase the general test instrument api layer on the bottom API of described test instrumentation.
6. method of testing according to claim 4 is characterized in that, also comprises behind the step B:
After C, test script explain that Executive Module reads the phase related control information of test script operation in the described test script operation control documents, call interpreter the test script that loads is construed to executable code, on described test instrumentation, carry out described executable code then.
7. according to each described method of testing in the claim 4 to 6, it is characterized in that, among the step B, carrying out the storehouse load operation of corresponding test instrumentation is specially: when test instrumentation storehouse dlm (dynamic loading module) obtains currently when being the result of determination of single test instrumentation environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to the global namespace space.
8. according to each described method of testing in the claim 4 to 6, it is characterized in that, among the step B, carrying out the storehouse load operation of corresponding test instrumentation is specially: when test instrumentation storehouse dlm (dynamic loading module) obtains currently when being the result of determination of an above test instrumentation environment, the bottom API storehouse that loads general test instrument API storehouse and test instrumentation is to corresponding name space.
CN2008101008147A 2008-02-22 2008-02-22 Test equipment and method based on universal test meter API Active CN101247292B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2008101008147A CN101247292B (en) 2008-02-22 2008-02-22 Test equipment and method based on universal test meter API

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2008101008147A CN101247292B (en) 2008-02-22 2008-02-22 Test equipment and method based on universal test meter API

Publications (2)

Publication Number Publication Date
CN101247292A CN101247292A (en) 2008-08-20
CN101247292B true CN101247292B (en) 2011-08-10

Family

ID=39947518

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2008101008147A Active CN101247292B (en) 2008-02-22 2008-02-22 Test equipment and method based on universal test meter API

Country Status (1)

Country Link
CN (1) CN101247292B (en)

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104796797B (en) * 2014-01-16 2018-11-20 深圳市双翼科技有限公司 The back-stage management method and device of optical line terminal
CN104615534B (en) * 2015-01-28 2017-08-01 广州酷狗计算机科技有限公司 interface test method and device
CN106325117B (en) * 2015-06-30 2020-04-10 中兴通讯股份有限公司 Method, device and system for automatically controlling instrument
CN105162664B (en) * 2015-09-29 2019-06-25 上海斐讯数据通信技术有限公司 A kind of automation platform test method and system based on the exploitation of instrument middle layer
US10635407B2 (en) 2015-10-08 2020-04-28 Micro Focus Llc Identification of differences between scripts for testing applications
US10592370B2 (en) * 2017-04-28 2020-03-17 Advantest Corporation User control of automated test features with software application programming interface (API)
CN108319516B (en) * 2017-12-28 2021-11-23 上海科梁信息科技股份有限公司 Test system and test method
CN109656622A (en) * 2018-12-04 2019-04-19 安徽皖通邮电股份有限公司 A kind of packaging method for realizing network tester in communication equipment automatic test
CN111130927B (en) * 2019-12-04 2021-12-17 中国电子科技集团公司第三十研究所 Method for automatically realizing service test of network layer communication terminal equipment
CN112285545B (en) * 2020-10-14 2021-06-04 江门市电力工程输变电有限公司 GIS disconnecting switch opening and closing test method

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1963782A (en) * 2006-11-28 2007-05-16 北京中星微电子有限公司 Method and system for testing embeded file system
CN101025686A (en) * 2007-03-22 2007-08-29 中兴通讯股份有限公司 Automation test system and test script generating and operating method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1963782A (en) * 2006-11-28 2007-05-16 北京中星微电子有限公司 Method and system for testing embeded file system
CN101025686A (en) * 2007-03-22 2007-08-29 中兴通讯股份有限公司 Automation test system and test script generating and operating method

Also Published As

Publication number Publication date
CN101247292A (en) 2008-08-20

Similar Documents

Publication Publication Date Title
CN101247292B (en) Test equipment and method based on universal test meter API
US6539501B1 (en) Method, system, and program for logging statements to monitor execution of a program
CN101227345B (en) Automatic testing method based on application program interface
CN101382915B (en) Software debugging system and debugging method
CN106598751B (en) Method and system for distributing events through event bus
CN102866944B (en) Pressure testing system and method
CN105159833A (en) Automatic testing device and method
CN101150463A (en) Testing method and system
CN103198009A (en) Universal testing method, system and corresponding device
CN103077024A (en) Device and method for supporting customization and running of software-as-a-service (SaaS) application processes
CN109697159A (en) A kind of development of automation operational system based on mixing cloud platform
US20070214178A1 (en) Multi-project verification environment
CN105468465A (en) ACE based inter-process communication system and method
CN105847319A (en) Mobile terminal network request method and system
CN101216804B (en) Testing device and method
CN102013993B (en) Physical topology use management method and system
CN101296462A (en) Method and system for batch execution of mobile terminal software automatic test
CN105162645A (en) Interoperability test method based on PIIF configuration
CN114385258B (en) Automatic test method, device, electronic equipment and storage medium
CN102779036B (en) For the Software tool of automatic technology
CN109144486A (en) A kind of workflow implementation method statelessly changed
CN101217332A (en) Alarming test method and test control platform of synchronous digital system device
CN109857638B (en) Universal framework for test system software
CN103019927A (en) Performance testing method and system
CN112925658A (en) Bridging method and device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant