CN106528418B - A kind of test method and device - Google Patents
A kind of test method and device Download PDFInfo
- Publication number
- CN106528418B CN106528418B CN201610972705.9A CN201610972705A CN106528418B CN 106528418 B CN106528418 B CN 106528418B CN 201610972705 A CN201610972705 A CN 201610972705A CN 106528418 B CN106528418 B CN 106528418B
- Authority
- CN
- China
- Prior art keywords
- target
- interface
- program
- current
- test case
- 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
Links
- 238000010998 test method Methods 0.000 title claims abstract description 13
- 238000012360 testing method Methods 0.000 claims abstract description 115
- 230000005540 biological transmission Effects 0.000 claims abstract description 69
- 238000000034 method Methods 0.000 claims abstract description 20
- 238000012545 processing Methods 0.000 claims description 23
- 238000002224 dissection Methods 0.000 claims description 6
- 230000001960 triggered effect Effects 0.000 claims description 6
- 108010001267 Protein Subunits Proteins 0.000 claims description 4
- 238000010586 diagram Methods 0.000 description 4
- 230000008901 benefit Effects 0.000 description 3
- 235000013399 edible fruits Nutrition 0.000 description 2
- 241000208340 Araliaceae Species 0.000 description 1
- 235000005035 Panax pseudoginseng ssp. pseudoginseng Nutrition 0.000 description 1
- 235000003140 Panax quinquefolius Nutrition 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 235000008434 ginseng Nutrition 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3684—Test management for test design, e.g. generating new test cases
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
Abstract
The present invention provides a kind of test method and devices, wherein method includes: S0: according to the incidence relation in software under testing between at least two interface routines, at least one test case of the corresponding software under testing of setting;S1: parsing current test case, to correspond at least two target interface programs of current test case in the determination software under testing, and determines the logical order of at least two target interfaces program;S2: configured transmission is obtained, and each described target interface program is successively called according to the logical order, so that the target interface program called for the first time exports the corresponding target component of current goal interface routine according to the configured transmission, and the interface routine for calling n-th exports the target component for the interface routine that corresponding n-th is called according to the target component of the target interface program output of (n-1)th calling, wherein, n is the integer greater than 1.According to the technical solution of the present invention, testing efficiency can be improved.
Description
Technical field
The present invention relates to field of computer technology, in particular to a kind of test method and device.
Background technique
With the continuous development of computer technology, various application software increase significantly, in order to ensure application software
Availability with higher usually requires to test its business function accordingly before issuing application software, with determination
Application software whether there is defect.
When being tested for the function of application software, except (User Interface is used the UI for needing to be directed to user side
Family interface) layer carry out automatic test outside, it is also necessary to the reliability of interface routine each in application software is tested, mesh
Before, when the reliability for each interface routine in application software is tested, that is, tests each interface routine and whether can
Corresponding target component is accurately exported according to configured transmission, it usually needs tested respectively for each interface routine.
As it can be seen that needing when each interface routine for application software is tested respectively for each interface journey
Sequence provides configured transmission respectively, it will expends a large amount of length of testing speech, testing efficiency is lower.
Summary of the invention
The embodiment of the invention provides a kind of test method and devices, and testing efficiency can be improved.
In a first aspect, the present invention provides a kind of test methods, comprising:
S0: according to the incidence relation in software under testing between at least two interface routines, the corresponding software under testing of setting
At least one test case;
S1: parsing current test case, to correspond at least two mesh of current test case in the determination software under testing
Interface routine is marked, and determines the logical order of at least two target interfaces program;
S2: obtaining configured transmission, and successively call each described target interface program according to the logical order, so that
The target interface program called for the first time exports the corresponding target component of current goal interface routine according to the configured transmission, and
The target component for the target interface program output that the interface routine for calling n-th is called according to (n-1)th time exports corresponding n-th
The target component of the interface routine of calling, wherein n is the integer greater than 1.
Preferably,
The logical order of the determination at least two target interfaces program further comprises: determining described at least two
The corresponding routing information of a target interface program, and according to the logical order of at least two target interfaces program, benefit
Sequential queue is formed with the corresponding routing information of at least two target interfaces program;
The logical order according at least two target interfaces program successively calls each described target interface
Program, comprising:
The sequential queue is traversed, when traversing the current path information in the sequential queue, determines current path
Sequential bits m of the information in the sequential queue, wherein m is the integer greater than 0;
Judge whether the sequential bits m is equal to 1, if it is, calling corresponding target interface according to current path information
Program, so that current goal interface routine exports corresponding target component according to the configured transmission;Otherwise, it determines the m-1 times
The target component of the target interface program output of calling, and using current target parameter as reference transmission parameter;According to current road
Diameter information calls corresponding target interface program, corresponds to so that current goal interface routine is exported according to the reference transmission parameter
Target component.
Preferably,
The routing information includes interface name, and/or, storage address.
Preferably, further includes:
Obtain the standard parameter of the corresponding configured transmission;
Judge whether the standard parameter is identical as the target component of the target interface program output of last time calling, such as
Fruit is not identical, it is determined that in the corresponding at least two target interfaces program of current test case, there are at least one target interfaces
It is unreliable;Otherwise, it determines each corresponding interface routine of current test case is reliable.
Second aspect, the embodiment of the invention provides a kind of test devices, comprising:
Setup module, for corresponding institute to be arranged according to the incidence relation in software under testing between at least two interface routines
State at least one test case of software under testing;
Dissection process module is used for parsing current test case with current test corresponding in the determination software under testing
At least two target interface programs of example, and determine the logical order of at least two target interfaces program;
Processing module is called, successively calls each described mesh for obtaining configured transmission, and according to the logical order
Interface routine is marked, is corresponded to so that the target interface program called for the first time exports current goal interface routine according to the configured transmission
Target component, and make n-th call interface routine according to (n-1)th time call target interface program output target join
Number exports the target component for the interface routine that corresponding n-th is called, wherein n is the integer greater than 1.
Preferably,
The dissection process module is further used for determining the corresponding path of at least two target interfaces program
Information, and according to the logical order of at least two target interfaces program, utilize at least two target interfaces program point
Not corresponding routing information forms sequential queue;
The calling processing module, comprising: traversal subelement, judgment sub-unit, the first processing subelement and second processing
Subelement;Wherein,
The traversal subelement is traversing the current path in the sequential queue for traversing the sequential queue
When information, sequential bits m of the current path information in the sequential queue is determined, wherein m is the integer greater than 0;
The judgment sub-unit, for judging whether the sequential bits m is equal to 1, if it is, triggering first processing
Subelement;Otherwise, the second processing subelement is triggered;
The first processing subelement, for calling corresponding target interface program according to current path information, so as to work as
Preceding target interface program exports corresponding target component according to the configured transmission;
The second processing subelement, the target component of the target interface program output for determining the m-1 times calling, and
Using current target parameter as reference transmission parameter;Corresponding target interface program is called according to current path information, so as to work as
Preceding target interface program exports corresponding target component according to the reference transmission parameter.
Preferably,
The routing information includes interface name, and/or, storage address.
Preferably,
Further include: obtain module, judgment module, the first determining module and the second determining module;Wherein,
The acquisition module, for obtaining the standard parameter of the corresponding configured transmission;
The judgment module, the mesh exported for judging the target interface program that the standard parameter and last time are called
Whether identical parameter is marked, if it is not the same, then triggering first determining module;Otherwise, second determining module is triggered;
First determining module is deposited for determining in the corresponding at least two target interfaces program of current test case
It is unreliable at least one target interface;
Second determining module, for determining that each corresponding interface routine of current test case is reliable.
The embodiment of the invention provides a kind of test method and devices, in the method, according in software under testing at least two
Incidence relation setting between a interface routine corresponds at least one test case of the software under testing, uses the test of setting
Example parsed, that is, can determine at least two target interface programs that current test case is corresponded in software under testing and its patrol
Sequence is collected, correspondingly, can successively call each mesh of software under testing according to logical order after getting configured transmission
Interface routine is marked, so that the target interface program that logical order ranks the first can export its corresponding target according to the configured transmission
Parameter, meanwhile, in logical order in two adjacent target interface programs, a relatively forward target interface program of sequential bits
The target component of output can be used as reference transmission parameter and be supplied to the target interface program of sequential bits relatively rearward, so that leaning on
A target interface program afterwards exports the target component of corresponding current goal interface routine, i.e. partial target interface routine exports
Target component can be used as reference transmission parameter sharing to other target interface programs, it is not necessary to for each target interface program point
Its corresponding configured transmission is indescribably supplied, length of testing speech is saved, improves testing efficiency.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below
There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is the present invention
Some embodiments for those of ordinary skill in the art without creative efforts, can also basis
These attached drawings obtain other attached drawings.
Fig. 1 is a kind of flow chart for test method that one embodiment of the invention provides;
Fig. 2 is the flow chart for another test method that one embodiment of the invention provides;
Fig. 3 is a kind of structural schematic diagram for sequential queue that one embodiment of the invention provides;
Fig. 4 is a kind of structural schematic diagram for test device that one embodiment of the invention provides;
Fig. 5 is the structural schematic diagram for another test device that one embodiment of the invention provides;
Fig. 6 is the structural schematic diagram for another test device that one embodiment of the invention provides.
Specific embodiment
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention
In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is
A part of the embodiment of the present invention, instead of all the embodiments, based on the embodiments of the present invention, those of ordinary skill in the art
Every other embodiment obtained without making creative work, shall fall within the protection scope of the present invention.
As shown in Figure 1, the embodiment of the invention provides a kind of test methods, comprising:
S0: according to the incidence relation in software under testing between at least two interface routines, the corresponding software under testing of setting
At least one test case;
S1: parsing current test case, to correspond at least two mesh of current test case in the determination software under testing
Interface routine is marked, and determines the logical order of at least two target interfaces program;
S2: obtaining configured transmission, and successively call each described target interface program according to the logical order, so that
The target interface program called for the first time exports the corresponding target component of current goal interface routine according to the configured transmission, and
The target component for the target interface program output that the interface routine for calling n-th is called according to (n-1)th time exports corresponding n-th
The target component of the interface routine of calling, wherein n is the integer greater than 1.
In the above embodiment of the present invention, according to the incidence relation setting pair in software under testing between at least two interface routines
The test case of setting should be parsed, that is, can determine in software under testing at least one test case of the software under testing
At least two target interface programs and its logical order of corresponding current test case, correspondingly, getting configured transmission
Later, each target interface program that software under testing can be successively called according to logical order, so that logical order comes head
The target interface program of position can export its corresponding target component according to the configured transmission, meanwhile, adjacent two in logical order
In a target interface program, the target component of the relatively forward target interface program output of sequential bits can be used as reference transmission
Parameter is supplied to the target interface program of sequential bits relatively rearward, so that a target interface program rearward is exported and corresponded to
The target component of the target component of current goal interface routine, i.e. partial target interface routine output can be used as reference transmission parameter
Share to other target interface programs, it is not necessary to provide its corresponding configured transmission respectively for each target interface program, save
Length of testing speech improves testing efficiency.
Specifically, in order to realize that at least two target interface corresponding to current test case is successively called, simultaneously
Realize using reference transmission parameter that an interface routine exports as reference transmission parameter be supplied to it is associated there another
Interface routine, in one embodiment of the invention, the logical order of the determination at least two target interfaces program, further
It comprises determining that the corresponding routing information of at least two target interfaces program, and is connect according at least two target
The logical order of mouth program utilizes the corresponding routing information of at least two target interfaces program to form sequential queue;
The logical order according at least two target interfaces program successively calls each described target interface
Program, comprising:
The sequential queue is traversed, when traversing the current path information in the sequential queue, determines current path
Sequential bits m of the information in the sequential queue, wherein m is the integer greater than 0;
Judge whether the sequential bits m is equal to 1, if it is, calling corresponding target interface according to current path information
Program, so that current goal interface routine exports corresponding target component according to the configured transmission;Otherwise, it determines the m-1 times
The target component of the target interface program output of calling, and using current target parameter as reference transmission parameter;According to current road
Diameter information calls corresponding target interface program, corresponds to so that current goal interface routine is exported according to the reference transmission parameter
Target component.
Specifically, in one embodiment of the invention, the routing information includes interface name, and/or, storage address.
Further, when in order to facilitate user according to the testing case software under testing of setting, determine that current test is used
Whether the corresponding at least two target interfaces program of example is reliable, in one embodiment of the invention, further includes:
Obtain the standard parameter of the corresponding configured transmission;
Judge whether the standard parameter is identical as the target component of the target interface program output of last time calling, such as
Fruit is not identical, it is determined that in the corresponding at least two target interfaces program of current test case, there are at least one target interfaces
It is unreliable;Otherwise, it determines each corresponding interface routine of current test case is reliable.
As shown in Fig. 2, technical solution and advantage in order to more clearly illustrate the embodiment of the present invention, below with reference to this hair
May include following each step for the test method that bright embodiment provides tests a cloud desktop management software:
Step 201, for user according to the business function of cloud desktop management system, it is user Shen that a corresponding operation flow, which is arranged,
Please cloud desktop, administrator examine user application test case.
It should be understood that, according to the business function of cloud desktop management system, can also be arranged in practical business scene
Test case corresponding to other operation flows.
In the embodiment of the present invention, staff can need to adjust according in cloud desktop management system when realizing the operation flow
At least two target interface programs and incidence relation existing for it, are arranged corresponding test case, and the test of setting is used
In example, it may include the corresponding routing information of each interface routine and realize each target interface when the operation flow
The calling sequence of program, the i.e. logical order of at least two target interfaces;For example, apply for cloud desktop, administrator in user
In the operation flow for examining cloud desktop, user logs in cloud desktop management system and needs calling interface program A, cloud desktop management system
Check that the legitimacy of user's login parameters needs calling interface program B, user needs to adjust when submitting cloud desktop application after login
With interface routine C, administrator examines user's application and needs calling interface program D, then can be according to interface routine A, B, C, D setting pair
The test case answered, meanwhile, the test case should also record interface program A, B, C, D logical order and its respectively correspond
Routing information.
In the embodiment of the present invention, routing information can be the corresponding interface name of each target interface program and/or deposit
Store up path, here by taking store path as an example, the i.e. corresponding URL of current goal interface routine (Uniform Resoure
Locator, uniform resource locator) for address.
Step 202, the test case of setting is parsed, corresponds to current test case extremely to determine in cloud desktop management system
Few two target interface programs determine the logical order of at least two target interface programs and determine each target interface journey
The corresponding store path of sequence.
Here, i.e., determining at least two target interfaces program A, B, C, D, logical order A-B-C-D and its difference
The corresponding address URL A1, B1, C1 and D1.
Step 203, according to the logical order of at least two target interface programs, at least two target interface programs point are utilized
Not corresponding storage address forms sequential queue.
With reference to Fig. 3, sequential queue may include sequence bit field and storage address field.
Step 204, configured transmission is obtained.
Here, that is, a user login information is obtained.
Step 205, traversal order queue determines currently stored when traversing the currently stored path in sequential queue
Path corresponding sequential bits m in sequential queue.
Step 206, judge whether m is equal to 1, if it is not the same, 207 are thened follow the steps, it is no to then follow the steps 208.
Step 207, according to routing information A1 invocation target interface routine A, so that interface routine A is exported according to configured transmission
Corresponding target component.
Step 208, the target component of the target interface program output of the m-1 times calling is determined, and by current target parameter
As reference transmission parameter.
Step 209, corresponding target interface program is called according to currently stored path, so that current goal interface routine root
Corresponding target component is exported according to reference transmission parameter.
For example, by calling interface program A to be performed corresponding processing to configured transmission (i.e. user login information)
After (for example going to decrypt corresponding ciphertext using user login information decryption), a decrypted result (plaintext of corresponding ciphertext is exported
Or the prompt information of decryption failure), i.e. the decrypted result of callable interface program B, interface routine A output then can be used as interface journey
The reference transmission parameter of sequence B, interface routine B can verify its legitimacy.In this process, it is only necessary to input interface journey
The corresponding configured transmission of sequence A, can be realized while test interface program A and interface routine B, it is not necessary to such as traditional test side
When testing interface routine A and interface routine B respectively in method, need to input corresponding interface program A and interface routine B respectively
Configured transmission, save length of testing speech, improve testing efficiency.
In the embodiment of the present invention, circulation executes step 205 to step 209, until called target interface program D it
Afterwards, step 210 is just executed.
Step 210, the standard parameter of the corresponding configured transmission is obtained.
For example, when getting correct user login information in step 204, corresponding standard parameter then should be right
It should be administrator and examine the cloud desktop application submitted by user;Conversely, being stepped on when getting a wrong user in step 204
Information is recorded, corresponding standard parameter should then correspond to the cloud desktop application that administrator's examination & approval are not submitted by user.
Step 211, whether the target component that judgment criteria parameter and target interface program D are exported is identical, if it is not the same,
Then follow the steps 212;Otherwise, step 213 is executed.
Here, i.e. whether the target component that exports of judgment criteria parameter and interface routine D is identical.
Step 212, it determines in the corresponding at least two target interfaces program of current test case, there are at least one targets
Interface is unreliable.
Step 213, determine that each corresponding interface routine of current test case is reliable.
In the embodiment of the present invention, the standard parameter of the configured transmission of acquisition and the corresponding configured transmission is provided by user,
For user when providing correct user login information, corresponding standard parameter should then correspond to administrator " examination & approval pass through " user
The cloud desktop application of submission should also be as if interface routine D, that is, administrator examines the target component exported when user's application " to examine
Criticize and pass through ", illustrate that interface routine A, B, C, D of cloud desktop management system are reliable at this time;Otherwise, then illustrate cloud desktop management system
It is unreliable that there are at least one in interface routine A, B, C and D of system, that is, there is at least one interface routine cannot normally execute it
Corresponding business.
As shown in figure 4, the embodiment of the invention provides a kind of test devices, comprising:
Setup module 401, for according to the incidence relation in software under testing between at least two interface routines, setting to be corresponded to
At least one test case of the software under testing;
Dissection process module 402, for parsing current test case, with current test corresponding in the determination software under testing
At least two target interface programs of use-case, and determine the logical order of at least two target interfaces program;
Processing module 403 is called, for obtaining configured transmission, and described in successively calling each according to the logical order
Target interface program, so that the target interface program called for the first time exports current goal interface routine pair according to the configured transmission
The target component answered, and make the interface routine of n-th calling according to the target of the target interface program output of (n-1)th calling
Parameter exports the target component for the interface routine that corresponding n-th is called, wherein n is the integer greater than 1.
As shown in figure 5, in one embodiment of the invention, it is described extremely to be further used for determination for the dissection process module 402
Few corresponding routing information of two target interface programs, and it is suitable according to the logic of at least two target interfaces program
Sequence forms sequential queue using the corresponding routing information of at least two target interfaces program;
The calling processing module 403, comprising: traversal subelement 4031, judgment sub-unit 4032, first handle subelement
4033 and second processing subelement 4034;Wherein,
The traversal subelement 4031, it is current in the sequential queue traversing for traversing the sequential queue
When routing information, sequential bits m of the current path information in the sequential queue is determined, wherein m is the integer greater than 0;
The judgment sub-unit 4032, for judging whether the sequential bits m is equal to 1, if it is, triggering described first
Handle subelement 4033;Otherwise, the second processing subelement 4034 is triggered;
The first processing subelement 4033, for calling corresponding target interface program according to current path information, with
Current goal interface routine is set to export corresponding target component according to the configured transmission;
The second processing subelement 4034, the target ginseng of the target interface program output for determining the m-1 times calling
Number, and using current target parameter as reference transmission parameter;Corresponding target interface program is called according to current path information, with
Current goal interface routine is set to export corresponding target component according to the reference transmission parameter.
The present invention one preferably in, the routing information includes interface name, and/or, storage address.
As shown in fig. 6, in one embodiment of the invention, further includes: obtain module 601, judgment module 602, first determines
Module 603 and the second determining module 604;Wherein,
The acquisition module 601, for obtaining the standard parameter of the corresponding configured transmission;
The judgment module 602, the target interface program for judging that the standard parameter and last time are called export
Target component it is whether identical, if it is not the same, then triggering first determining module 603;Otherwise, described second is triggered to determine
Module 604;
First determining module 603, for determining in the corresponding at least two target interfaces program of current test case,
There are at least one target interface is unreliable;
Second determining module 604, for determining that each corresponding interface routine of current test case is reliable.
The contents such as the information exchange between each unit, implementation procedure in above-mentioned apparatus, due to implementing with the method for the present invention
Example is based on same design, and for details, please refer to the description in the embodiment of the method for the present invention, and details are not described herein again.
In conclusion each embodiment of the present invention at least has the following beneficial effects:
1, in one embodiment of the invention, according to the incidence relation setting pair in software under testing between at least two interface routines
The test case of setting should be parsed, that is, can determine in software under testing at least one test case of the software under testing
At least two target interface programs and its logical order of corresponding current test case, correspondingly, getting configured transmission
Later, each target interface program that software under testing can be successively called according to logical order, so that logical order comes head
The target interface program of position can export its corresponding target component according to the configured transmission, meanwhile, adjacent two in logical order
In a target interface program, the target component of the relatively forward target interface program output of sequential bits can be used as reference transmission
Parameter is supplied to the target interface program of sequential bits relatively rearward, so that a target interface program rearward is exported and corresponded to
The target component of the target component of current goal interface routine, i.e. partial target interface routine output can be used as reference transmission parameter
Share to other target interface programs, it is not necessary to provide its corresponding configured transmission respectively for each target interface program, save
Length of testing speech improves testing efficiency.
2, in one embodiment of the invention, the standard parameter of configured transmission is corresponded to by obtaining, by comparing last
Whether the target component and standard parameter of the target interface program output of secondary calling are identical, when identical, then can determine to be measured soft
In part, each target interface corresponding to current test case is reliable, otherwise, it may be determined that there are at least one target interfaces
Program is unreliable.
It should be noted that, in this document, such as first and second etc relational terms are used merely to an entity
Or operation is distinguished with another entity or operation, is existed without necessarily requiring or implying between these entities or operation
Any actual relationship or order.Moreover, the terms "include", "comprise" or its any other variant be intended to it is non-
It is exclusive to include, so that the process, method, article or equipment for including a series of elements not only includes those elements,
It but also including other elements that are not explicitly listed, or further include solid by this process, method, article or equipment
Some elements.In the absence of more restrictions, the element limited by sentence " including one ", is not arranged
Except there is also other identical factors in the process, method, article or apparatus that includes the element.
Finally, it should be noted that the foregoing is merely presently preferred embodiments of the present invention, it is merely to illustrate skill of the invention
Art scheme, is not intended to limit the scope of the present invention.Any modification for being made all within the spirits and principles of the present invention,
Equivalent replacement, improvement etc., are included within the scope of protection of the present invention.
Claims (4)
1. a kind of test method characterized by comprising
According to the incidence relation in software under testing between at least two interface routines, at least the one of the corresponding software under testing of setting
A test case;Further include:
Current test case is parsed, to correspond at least two target interface journeys of current test case in the determination software under testing
Sequence, and determine the logical order of at least two target interfaces program;
Configured transmission is obtained, and each described target interface program is successively called according to the logical order, so as to adjust for the first time
Target interface program exports the corresponding target component of current goal interface routine according to the configured transmission, and makes n-th
The target component for the target interface program output that the interface routine of secondary calling is called according to (n-1)th time exports corresponding n-th and calls
Interface routine target component, wherein n is integer greater than 1;
The logical order of the determination at least two target interfaces program, further comprises: determining at least two mesh
The corresponding routing information of interface routine is marked, and according to the logical order of at least two target interfaces program, utilizes institute
It states the corresponding routing information of at least two target interface programs and forms sequential queue;
The logical order according at least two target interfaces program successively calls each described target interface program,
Include:
The sequential queue is traversed, when traversing the current path information in the sequential queue, determines current path information
Sequential bits m in the sequential queue, wherein m is the integer greater than 0;
Judge whether the sequential bits m is equal to 1, if it is, corresponding target interface program is called according to current path information,
So that current goal interface routine exports corresponding target component according to the configured transmission;Otherwise, it determines the m-1 times calling
The target component of target interface program output, and using current target parameter as reference transmission parameter;According to current path information
Corresponding target interface program is called, so that current goal interface routine exports corresponding target according to the reference transmission parameter
Parameter.
2. test method according to claim 1, which is characterized in that
The routing information includes interface name, and/or, storage address;
Further include:
Obtain the standard parameter of the corresponding configured transmission;
Judge whether the standard parameter is identical as the target component of the target interface program output of last time calling, if not
It is identical, it is determined that in the corresponding at least two target interfaces program of current test case, there are at least one target interfaces can not
It leans on;Otherwise, it determines each corresponding interface routine of current test case is reliable.
3. a kind of test device characterized by comprising
Setup module, for according to the incidence relation in software under testing between at least two interface routines, be arranged it is corresponding it is described to
Survey at least one test case of software;
Dissection process module, for parsing current test case, to correspond to current test case in the determination software under testing
At least two target interface programs, and determine the logical order of at least two target interfaces program;
Processing module is called, successively calls each described target to connect for obtaining configured transmission, and according to the logical order
Mouth program, so that the target interface program called for the first time exports the corresponding mesh of current goal interface routine according to the configured transmission
Parameter is marked, and the interface routine for calling n-th is defeated according to the target component of the target interface program output of (n-1)th calling
The target component of the interface routine of n-th calling is corresponded to out, wherein n is the integer greater than 1;
The dissection process module is further used for determining the corresponding path letter of at least two target interfaces program
Breath, and according to the logical order of at least two target interfaces program, distinguished using at least two target interfaces program
Corresponding routing information forms sequential queue;
The calling processing module, comprising: traversal subelement, judgment sub-unit, the first processing subelement and second processing are single
Member;Wherein,
The traversal subelement is traversing the current path information in the sequential queue for traversing the sequential queue
When, determine sequential bits m of the current path information in the sequential queue, wherein m is the integer greater than 0;
The judgment sub-unit, for judging whether the sequential bits m is equal to 1, if it is, triggering the first processing is single
Member;Otherwise, the second processing subelement is triggered;
The first processing subelement, for calling corresponding target interface program according to current path information, so that current mesh
It marks interface routine and corresponding target component is exported according to the configured transmission;
The second processing subelement, the target component of the target interface program output for determining the m-1 times calling, and will work as
Preceding target component is as reference transmission parameter;Corresponding target interface program is called according to current path information, so that current mesh
It marks interface routine and corresponding target component is exported according to the reference transmission parameter.
4. test device according to claim 3, which is characterized in that
The routing information includes interface name, and/or, storage address;
Further include: obtain module, judgment module, the first determining module and the second determining module;Wherein,
The acquisition module, for obtaining the standard parameter of the corresponding configured transmission;
The judgment module, the target for judging that the target interface program that the standard parameter and last time are called exports are joined
Whether number is identical, if it is not the same, then triggering first determining module;Otherwise, second determining module is triggered;
First determining module, for determining in the corresponding at least two target interfaces program of current test case, exist to
A few target interface is unreliable;
Second determining module, for determining that each corresponding interface routine of current test case is reliable.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610972705.9A CN106528418B (en) | 2016-10-28 | 2016-10-28 | A kind of test method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610972705.9A CN106528418B (en) | 2016-10-28 | 2016-10-28 | A kind of test method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106528418A CN106528418A (en) | 2017-03-22 |
CN106528418B true CN106528418B (en) | 2019-01-22 |
Family
ID=58349568
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610972705.9A Active CN106528418B (en) | 2016-10-28 | 2016-10-28 | A kind of test method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106528418B (en) |
Families Citing this family (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107329861B (en) * | 2017-06-12 | 2020-12-22 | 奇安信科技集团股份有限公司 | Multi-interface testing method and device |
CN109150643B (en) * | 2017-06-16 | 2022-09-23 | 创新先进技术有限公司 | Service processing abnormity detection method and device |
CN109213671B (en) * | 2017-06-30 | 2021-08-03 | 中国航发商用航空发动机有限责任公司 | Software testing method and platform thereof |
CN109426572B (en) * | 2017-08-29 | 2021-07-02 | 杭州海康威视数字技术股份有限公司 | Task processing method and device and electronic equipment |
CN107809332A (en) * | 2017-11-10 | 2018-03-16 | 中国民生银行股份有限公司 | Compound interface configures and compound interface call method, device |
CN108763071A (en) * | 2018-05-17 | 2018-11-06 | 平安科技(深圳)有限公司 | A kind of webpage test method and terminal device |
CN110737575B (en) * | 2018-07-20 | 2023-09-01 | 北京金山云网络技术有限公司 | Interface testing method and device, electronic equipment and storage medium |
CN109471796A (en) * | 2018-10-16 | 2019-03-15 | 平安证券股份有限公司 | Interface test method, device, computer equipment and storage medium |
CN109857667B (en) * | 2019-02-03 | 2021-10-08 | 苏州市龙测智能科技有限公司 | Interface automation test method, test device, test equipment and storage medium |
CN111159028B (en) * | 2019-12-23 | 2023-08-01 | 望海康信(北京)科技股份公司 | Webpage testing method and device |
CN111949537A (en) * | 2020-08-14 | 2020-11-17 | 北京锐安科技有限公司 | Interface test method, device, equipment and medium |
CN112101949B (en) * | 2020-09-18 | 2022-12-16 | 支付宝(杭州)信息技术有限公司 | Safe service request processing method and device |
CN112416763A (en) * | 2020-11-17 | 2021-02-26 | 杭州安恒信息技术股份有限公司 | Method, device and equipment for automatically testing interface and storage medium |
CN113094264B (en) * | 2021-03-31 | 2022-02-18 | 北京深思数盾科技股份有限公司 | Interface testing method and device |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101145993A (en) * | 2007-10-11 | 2008-03-19 | 中兴通讯股份有限公司 | A multi-point access interface test method and its test system |
US7603658B2 (en) * | 2004-02-19 | 2009-10-13 | Oracle International Corporation | Application functionality for a test tool for application programming interfaces |
CN103235759A (en) * | 2013-05-15 | 2013-08-07 | 百度在线网络技术(北京)有限公司 | Method and device for generating test cases |
CN105117345A (en) * | 2015-09-23 | 2015-12-02 | 网易(杭州)网络有限公司 | Interface testing method and device for application program |
CN105138461A (en) * | 2015-09-23 | 2015-12-09 | 网易(杭州)网络有限公司 | Interface testing method and device for application program |
-
2016
- 2016-10-28 CN CN201610972705.9A patent/CN106528418B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7603658B2 (en) * | 2004-02-19 | 2009-10-13 | Oracle International Corporation | Application functionality for a test tool for application programming interfaces |
CN101145993A (en) * | 2007-10-11 | 2008-03-19 | 中兴通讯股份有限公司 | A multi-point access interface test method and its test system |
CN103235759A (en) * | 2013-05-15 | 2013-08-07 | 百度在线网络技术(北京)有限公司 | Method and device for generating test cases |
CN105117345A (en) * | 2015-09-23 | 2015-12-02 | 网易(杭州)网络有限公司 | Interface testing method and device for application program |
CN105138461A (en) * | 2015-09-23 | 2015-12-09 | 网易(杭州)网络有限公司 | Interface testing method and device for application program |
Also Published As
Publication number | Publication date |
---|---|
CN106528418A (en) | 2017-03-22 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106528418B (en) | A kind of test method and device | |
CN106095677B (en) | The RESTful Webservice automatic interface testing methods realized based on Robot Framework | |
CN107943768B (en) | A kind of measurement verification calibration digital certificates intelligent editing method and system | |
CN107478455B (en) | Timing truncation reliability test method suitable for Weibull distribution type product | |
CN104796240B (en) | A kind of fuzz testing system of stateful procotol | |
CN106033393B (en) | A kind of applied program testing method and system and mobile terminal | |
CN104750588B (en) | A kind of method for testing pressure based on serial communication | |
CN107122258A (en) | Method and apparatus for the state code check of test interface | |
CN106293977B (en) | A kind of data verification method and equipment | |
CN106933709A (en) | A kind of method of testing and device | |
CN102291274B (en) | A kind of system and method realizing automatic adaptation of network testing instrument | |
CN102510346A (en) | Method, system and device for testing network equipment | |
CN107360233A (en) | Method, apparatus, equipment and the readable storage medium storing program for executing that file uploads | |
CN110535654A (en) | Parallel system dispositions method, device and computer equipment based on block chain | |
WO2017000916A1 (en) | Pre-emphasis parameter configuration method and apparatus | |
CN110213284A (en) | Detection method, system and the relevant apparatus of SSH server weak passwurd loophole | |
CN108234246A (en) | A kind of method and system of multidirectional server network performance | |
CN110399304B (en) | Script testing method and system | |
CN103425558B (en) | A kind of method realizing the test of board I/O port based on test configurations table | |
CN101931462A (en) | Testing control method and device for optical transmission network | |
CN106855843B (en) | Performance analysis method and device of Web system | |
CN111079148B (en) | Method, device, equipment and storage medium for detecting SQL injection attack | |
CN105490878B (en) | NM server performance test methods and equipment | |
CN114416597A (en) | Test case record generation method and device | |
CN109743203B (en) | Distributed service security combination system and method based on quantitative information flow |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |