CN106155891B - Interface test method, interface description data library generating method and device - Google Patents

Interface test method, interface description data library generating method and device Download PDF

Info

Publication number
CN106155891B
CN106155891B CN201510155540.1A CN201510155540A CN106155891B CN 106155891 B CN106155891 B CN 106155891B CN 201510155540 A CN201510155540 A CN 201510155540A CN 106155891 B CN106155891 B CN 106155891B
Authority
CN
China
Prior art keywords
interface
data
tested
request
response
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
CN201510155540.1A
Other languages
Chinese (zh)
Other versions
CN106155891A (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.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201510155540.1A priority Critical patent/CN106155891B/en
Publication of CN106155891A publication Critical patent/CN106155891A/en
Application granted granted Critical
Publication of CN106155891B publication Critical patent/CN106155891B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

The embodiment of the invention provides a kind of interface test method, interface description data library generating method and device, which includes: to generate the request data for being directed to interface to be tested;The server request data being sent to where the interface to be tested;Receive the response data for the request data that the server returns;And the corresponding response data description of interface name that the interface to be tested is obtained from interface description data library;The received response data is verified using the constraint condition that the field value of each response field of response field collection and response field concentration in the response data description of acquisition should meet, obtains verification result.Due to the response field collection and constraint condition that should include including correct response data, the information of existing interface description is expanded, implicit restrict condition can be accurately expressed, thus it is ensured that the quality for passing through the interface after interface testing is relatively high and stability is relatively preferable.

Description

Interface test method, interface description data library generating method and device
Technical field
This application involves software testing technology field more particularly to a kind of interface test methods, the life of interface description data library At method and device.
Background technique
Interface refers to the rule of communication between same system different function layer.In service interface (in a manner of service pair One interface of outer offer) it is prevailing instantly, in interface system end to end, guarantee the quality for the interface that front and back end interacts It is particularly important with stabilization, and the quality and stability of interface is to be verified during interface exploitation by interface testing , this just proposes higher requirement to the accuracy of the verification result of interface testing.
In existing interface testing, since the front end exploitation of service software in same service system (refers to client here The exploitation at end) and rear end exploitation (refer to here server end exploitation) be often it is parallel, therefore, the survey of the interface of front end exploitation Examination and the testing for interface developed to rear end are also parallel.Survey of the front and back end interface testing engineer to each self-developed interface Examination is carried out respectively based on information such as software function and parameter, the return values for providing standard in the description of a interface, this connects Mouth description is the basis that operation is interacted between front end developer and rear end developer, also constructs a kind of bipartite base In the modality for co-operation of contract, both sides are to the basis that the consistency that contract understands is that interface testing is capable of precise and high efficiency progress.
However, since the function that interface provides usually has suitable an application range and scene, for example, parameter value range, Calling sequence of operation etc.;The test of interface is also established on the certain implicit assumptions for the function of providing interface, it is existing Interface description in lack enough information, these implicit restrict conditions can not be accurately expressed, therefore, based on existing Interface description carries out interface testing, and the accuracy for often resulting in the test result of interface testing is lower.
Summary of the invention
The embodiment of the present application provides a kind of interface test method, interface description data library generating method and device, to solve Interface testing is certainly carried out based on the description of existing interface, caused by interface testing test result the lower problem of accuracy.
A kind of interface test method, comprising:
Generate the request data for being directed to interface to be tested;
The server request data being sent to where the interface to be tested;
Receive the response data for the request data that the server returns;And
The corresponding response data description of interface name of the interface to be tested is obtained from interface description data library, it is described It include that interface name and its corresponding response data describe in interface description data library, the response data description includes correct The pact that the field value for each response field that the response field collection and the response field that response data should include are concentrated should meet Beam condition;
Utilize each response word of response field collection and response field concentration in the response data description of acquisition The constraint condition that the field value of section should meet verifies the received response data, obtains verification result.
A kind of interface description data library generating method, the interface description data library generating method are based on above-mentioned interface testing Method, interface description data library generating method include:
According to interface code to be tested, the interface testing script of the interface to be tested is generated;Establish generate it is described to The incidence relation of the interface name of the interface testing script and interface to be tested of test interface, and the incidence relation is stored In interface description data library, the interface code to be tested is generated according to the request data;And
The request data for interface to be tested will be generated as the interface testing use-case of the interface to be tested, this is established and connect The incidence relation of mouth test case and the interface name of the interface to be tested, and the incidence relation is stored in interface description In database;And
Using the received response data as the test data of interface to be tested, establish the interface testing data with should be to The incidence relation of the interface name of test interface, and the incidence relation is stored in interface description data library;And
The interface testing report for the interface to be tested is generated according to the verification result, establishes the interface testing report The incidence relation with the interface name of the interface to be tested is accused, and the incidence relation is stored in interface description data library, The interface testing report includes request data, verification result, verification result state and the verifying for the interface to be tested having verified that As a result one of Failure Causes Analysis or a variety of, the verification result state include successfully and failing.
A kind of interface test device, comprising:
Request data generation unit, for generating the request data for being directed to interface to be tested;
Transmission unit, the server for being sent to the request data where the interface to be tested;
Receiving unit, the response data for the request data returned for receiving the server;
Acquiring unit, for obtaining the corresponding response of interface name of the interface to be tested from interface description data library Data describe, and include that interface name and its corresponding response data describe in the interface description data library, the response data Description includes the word of the response field collection that correct response data should include and each response field that the response field is concentrated The constraint condition that segment value should meet;
Authentication unit, for utilizing the response field collection and response field concentration in the response data description obtained The constraint condition that should meet of field value of each response field the received response data is verified, obtain verifying knot Fruit.
A kind of interface description data library generating means, interface description data library generating means are based on above-mentioned interface testing Device, interface description data library generating means include:
First incidence relation establishes unit, for generating the interface of the interface to be tested according to interface code to be tested Test script;Establish the interface testing script of the interface to be tested and being associated with for the interface name of the interface to be tested generated Relationship, the interface code to be tested are generated according to the request data;
Second incidence relation establishes unit, and the request data for that will generate for interface to be tested to be measured is tried as this The interface testing use-case of mouth establishes the incidence relation of the interface name of the interface testing use-case and the interface to be tested;
Third incidence relation establishes unit, for using the received response data as the test number of interface to be tested According to establishing the incidence relation of the interface name of the interface testing data and the interface to be tested;
4th incidence relation establishes unit, for generating the interface for being directed to the interface to be tested according to the verification result Test report establishes the incidence relation of interface testing report and the interface name of the interface to be tested, the interface testing report Accuse request data, verification result, verification result state and verification result failure cause point including the interface to be tested having verified that One of analysis is a variety of, and the verification result state includes successfully and failing;
Storage unit, for by the interface name of the interface testing script of the interface to be tested and the interface to be tested Incidence relation, the incidence relation of the interface name of interface testing use-case and the interface to be tested, interface testing report with should be to The incidence relation of the interface name of the incidence relation of the interface name of test interface and interface to be tested is stored in interface and describes number According in library.
It in the embodiment of the present application, include that interface name and its corresponding response data describe in interface description data library, Response data description includes that the response field collection that correct response data should include and the response field concentrate each response The constraint condition that the field value of field should meet;This is allowed for when carrying out interface testing, can be from interface description data library The corresponding response data description of interface name of interface to be tested is obtained, and then using in the description of the response data of the acquisition Response field collection and constraint condition the received response data is verified, obtain verification result.Due to the application's Response data description in interface description data library includes the response field collection and constraint condition that correct response data should include, The information of existing interface description is expanded, and has made it possible therefore accurately expressing implicit restrict condition mentions The high accuracy of verification result, it is ensured that the quality of the interface after passing through interface testing is relatively high and stability is opposite Preferably.
Detailed description of the invention
Fig. 1 is the interface test method schematic diagram that the embodiment of the present application one provides;
Fig. 2 is the structural schematic diagram for the interface test device that the embodiment of the present application two provides;
Fig. 3 is the process that interface testing is executed using If-test interface testing platform that the embodiment of the present application three provides Schematic diagram;
Fig. 4 is the interface test method schematic diagram that the embodiment of the present application four provides;
Fig. 5 is that the interface test method that the embodiment of the present application four provides uses example schematic diagram in detailed programs;
Fig. 6 is the structural schematic diagram for the interface test device that the embodiment of the present application five provides;
Fig. 7 is the structural schematic diagram for the interface description data library generating means that the embodiment of the present application six provides.
Specific embodiment
The interface test method of the embodiment of the present application is the corresponding number of responses of the interface name comprising interface based on proposition According to what is carried out on the basis of the interface description data library of description, response data description includes that correct response data should include The constraint condition that response field collection and the response field concentrate the field value of each response field that should meet;This allow for into When line interface is tested, the corresponding response data of interface name that interface to be tested can be obtained from interface description data library is retouched State, so using the acquisition the response data description in response field collection and constraint condition to the received number of responses According to being verified, verification result is obtained.Since the response data description in the interface description data library of the application includes correct The response field collection and constraint condition that response data should include, have expanded the information of existing interface description, and make accurately The implicit restrict condition of expression is possibly realized, and this improves the accuracys of verification result, it is ensured that passes through interface The quality of interface after test is relatively high and stability is relatively preferable.
Preferred embodiment of the present application is illustrated below in conjunction with Figure of description, it should be understood that described herein Preferred embodiment is only used for describing and explaining the application, is not used to limit the application.And in the absence of conflict, this Shen Please in embodiment and embodiment in feature can be combined with each other.
Embodiment one
As shown in Figure 1, it is the interface test method schematic diagram of the embodiment of the present application one, test method here can be managed Solution is simulant-client (for example, browser, Webview (iOS calls UIWebview in the following text)) in the App of mobile terminal to server end Actual interface is tested, comprising the following steps:
Step 101: generating the request data for being directed to interface to be tested;
Specifically, in the request data can include: request the url of name, request, request type (get/post), request A variety of data in parameter value (get parameter value/post parameter value) etc.;
Such as: assuming that request data is http://example.com/demo.htm? searchNo=0, this this request Request name in data are as follows: demo, the url of request are http://example.com/demo, and request type is get request, are asked Seeking parameter is searchNo, and the value of the required parameter is 0.
Required parameter value in request data in this step 101, which can be, to be artificially arranged, and is also possible to pass through test Tool is automatically generated using the constraint condition that correct request data should meet.
Step 102: the server request data being sent to where the interface to be tested;
In this step 102, after request data is sent to the server, the server passes through the interface to be tested The request data is received, calculation process is carried out according to the required parameter value in the request data;And by processing result namely Response data returns to the request data sender.
Preferably, step 102 is specific can include:
According to the request data, the interface testing code of the interface to be tested is generated;
The interface testing code realization generated by operation sends the data to the interface to be tested.
It should be noted that being to construct and simulate transmission request data to try to be measured in above-mentioned steps 101 and step 102 The process of mouth;
Here, it is surveyed according to the interface that the interface testing code to be tested of generation can also generate the interface to be tested Training sheet, script here are executable scripts, can be used in the continuous integrating of subsequent code.
Step 103: receiving the response data for the request data that the server returns;
Step 104: the corresponding response data of interface name of the interface to be tested is obtained from interface description data library Description;
It is that can also be stored in code Entrust Server in system database that the interface description data library, which can be stored in, On, it is shared convenient for front and back end developer and tester;
It include that interface name and its corresponding response data describe in the interface description data library, the response data is retouched It states can include: each response field that the response field collection and the response field that correct response data should include are concentrated The constraint condition that field value should meet;
The number for the response field that the response field is concentrated can be one, be also possible to it is multiple, by software developer The specific interface of design determines;
Assuming that it is 2 that the response field that the correct response data of a certain interface should include, which concentrates the number of response field, Respectively response field 1 and response field 2, then at this point, the response data description of the interface includes response field 1, response field 1 The constraint condition that should meet of the field value of constraint condition and response field 2, response field 2 that should meet of field value;
Here response field can be understood as the field that response data must include;
Specifically, the description in the interface description data library follows/meets setting syntax format, in order to testing tool Interface testing scheme in the automated execution embodiment of the present invention one, further, the syntax format of the setting is for defeated The syntax format that syntax format used in the parameter exported out to the parameter of interface or interface is verified, such as: assuming that defeated The syntax format of the parameter exported out to the parameter of interface or interface is JSON (JavaScript Object Notiation, base In the data interchange format of the lightweight of Java Script language), then the syntax format set is JSON Schema (JSON Frame);Assuming that output is blueprint (source data exchange to the syntax format for the parameter that the parameter or interface of interface export Format), then the syntax format set is blueprint Schema (blueprint frame).
Step 105: utilizing response field collection and the response field in the response data description obtained to concentrate every The constraint condition that the field value of one response field should meet verifies the received response data, obtains verification result.
Specifically, the described setting syntax format may include the semantic mark being made of keyword and its corresponding semantic function Label, the language that the constraint condition that the field value of response field should meet is made of preset keyword and corresponding constraint condition function Adopted tag representation;
Here constraint condition function is the corresponding semantic function of preset keyword;
In addition, can also include the specification of the setting syntax format in the interface description data library, it should to utilize The specification whether specification meets the setting syntax format to the syntax format of received response data is verified.
It should be noted that semantic label here is the application on the basis of abiding by the syntax format, expand Come semantic label, exclusively for the constraint condition of the application expression and extend.
At this point, the specific verification process of step 105 may include the following three steps:
Step a1: determine that the response field in the response data obtained description concentrates each response field for including;
Step b1: for determining each response field, according to the preset keyword, from the number of responses of acquisition According to the corresponding constraint condition function of field value for determining the response field in description;
Step c1: judge the whole fields for including in the received response data constitute set whether the institute with acquisition Whether the field value for stating set equality and each response field that the response field collection in response data description is constituted is all satisfied pair The constraint condition function answered;
Step d1: if set and the response of acquisition that the whole fields for including in the received response data are constituted The set equality that response field collection in data description is constituted, and the field value of each response field is all satisfied corresponding constraint condition Function, it is determined that be proved to be successful;It is on the contrary, it is determined that authentication failed.
Above-mentioned steps c1 and step d1, specific implementation procedure can with but be not limited to such as under type:
For each response field, following operation is executed:
Judge whether the received response data includes whether the response field and the response field have field value;
If comprising the response field and there is field value, judge whether the field value meets the constraint item of the response field Part function;
If in the response data including whole response fields in response data description, the whole in response data description Response field is all contained in the response data and the field value of each response field is all satisfied corresponding constraint condition, then really Surely it is proved to be successful;Otherwise, it determines authentication failed.
If do not include whole response fields in the response data description obtained in the received response data, or Person includes that the field value of the part response field or each response field in the response data description obtained is not all satisfied pair The constraint condition function answered, it is determined that authentication failed.
Above-mentioned semantic label is illustrated below, for mockjs semantic label, it then follows IETF JSON Schema Two of the semantic label of the specification (this specification define syntax formats) of Draft-04 (ietf draft JSON mode) and format Example is as follows:
Example 1:
The example 1 description is that an attribute value is character string and value is the natural number greater than 60 less than 100.Wherein, $ Schema, type are the keyword in JSON Schema specification, and http://my.site/myschema# is keyword $ The value of schema shows the url where the specification that the description information of the natural number follows;String is the value of type, and indicating should The data type of natural number is character string type;
" iftest ": "@natural (60,100) ", the description of this sentence, is exactly a semantic label, wherein being by " crucial Word " and " semantic function " are constituted, it may be assumed that " keyword ": " semantic function ", iftest are keyword, and@natural (60,100) is Semantic function, the character string natural that@is used to identify thereafter is method function, which includes minimum value and maximum value two A parameter, in example 1, minimum value is 60, and maximum value is 100, and this demonstrate the value ranges of natural number.
Preset keyword, is the customized keyword of the application, and above-mentioned iftest keyword is to existing JSON The extension of keyword in Schema specification, will not necessarily indicate the preset keyword asked in itself using iftest, Other words (certainly, other words here refer to the word except the keyword in JSON Schema specification) can be used to indicate Preset keyword.
Example 2:
In the example 2, " iftest ": "@host_tmall (" ^detail ") " description of this sentence is also a semantic mark Label.What the example 2 indicated is uri (uniform resource identifier, the unification that a data type is character string Resource identifier), and be line heaven cat url (the uniform resoure of " detail " comprising keyword in the uri Locator: uniform resource locator) description information.
The basic method function that basic data type and offer are provided in following table (1), it should be noted that type It is not limited thereto, method function can also constantly extend:
Table (1)
Traffic ID (bizNum) method function that includes in type of service this Method type in above-mentioned table (1) and without association Discussing url (url_no_protocol) method function is extended according to practical business, is also as provided in the embodiment of the present application Method function can constantly extend, and the method function extended can have more business correlations, and then possess more Practical business application value.
Such as: " iftest ": "@bizNUm (3,5) ", this semantic label describe a business id, and length is 3 To 5;
" iftest ": "@url_no_protocol ", this semantic label describes a http request, without agreement Head, with remaining keeps url as, such as: be in http request //www.tmall.com when be exactly verify it is successful, in http Request is exactly verification failure when being http://www.tmall.com.
Since the verification process of correctness to received response data of the above-mentioned steps a1 into step d1 is to be based on asking Seek the semantic label (being made of preset keyword and corresponding constraint condition function) of each response field in descriptive data base It carries out, therefore, above-mentioned verification mode is properly termed as semantization verifying.
In addition, on the basis of the embodiment of the present application one, it is contemplated that the request data of interface need with required field (or The field that person must include) field value meet certain constraint condition, if if by the constraint condition in interface description data library In be described, be beneficial to test chemical industry tool according to this this automatically and the constraint condition automatic imitation utilize to generate for testing Request data then will enable the request data generated to cover all test points as far as possible, and can improve for test The quality of request data also correspondingly ensures the availability of the response data of acquisition, just further promotes the standard of test result True property, while can fast and effeciently find defect existing for interface to be tested, below by embodiment two to this preferred embodiment It is illustrated.
Embodiment two
As shown in Fig. 2, it is the interface test method schematic diagram in the embodiment of the present invention two, interface described in this method is retouched Stating not only includes interface name, the corresponding response data description of interface name in database, and further including that interface name is corresponding asks Type and request data is asked to describe, the request data description includes the request field and ask that correct request data should include The constraint condition for asking the field value of field that should meet;On this basis the interface test method the following steps are included:
Step 201: the interface name corresponding requests data that the interface to be tested is obtained from interface description data library are retouched It states and request type;
Step 202: according to each request field and each request field for including in the description of the request data of acquisition The constraint condition that field value should meet, generating request type is the request type obtained for the interface to be tested Request data;
Since request data description includes the field of request field and request field that correct request data should include The constraint condition that value should meet, therefore, when knowing that acquisition request data describe, so that it may know it includes each request field And the constraint condition that the field value of each request field should meet, and then each request field and corresponding constraint condition are utilized, it is raw It is the request data for the interface to be tested of the request type obtained at request type.
Preferably, the description in the interface description data library meets setting syntax format, which includes The semantic label being made of keyword and its corresponding semantic function, the constraint condition that the field value of request field should meet is by pre- If keyword and corresponding constraint condition function constitute semantic label indicate;
At this point, step 202 specifically can comprise the following steps that
Step a2: according to the preset keyword, each request word is determined from the description of the request data of acquisition The corresponding constraint condition function of field value of section;
Step b2: generating request type according to the corresponding constraint condition function of the field value of each request field is to obtain The request data for the interface to be tested of the request type.
Preferably, the step b2 can include:
Step b21: required parameter value is generated according to the corresponding constraint condition function of the field value of each request field, this is asked Seeking parameter value is the relevant parameter value of business or the unrelated parameter value of business;
Step b22: generating request type using each request field and corresponding required parameter value is the request obtained The request data for the interface to be tested of type.
Step 203: the server request data being sent to where the interface to be tested;
Step 204: receiving the response data for the request data that the server returns;
Step 205: the corresponding response data of interface name of the interface to be tested is obtained from interface description data library Description;
Step 206: utilizing response field collection and the response field in the response data description obtained to concentrate every The constraint condition that the field value of one response field should meet verifies the received response data, obtains verification result.
Above-mentioned steps 203 to step 206 specific implementation process and embodiment one in step 102 to step 105 tool Body implementation process is identical, and which is not described herein again.
That implements the scheme of the embodiment of the present invention one or embodiment two can be a test device.Below by implementation The specific implementation process of the application is described in detail in a specific example shown in example three.
Embodiment three
It describes to follow using test device as interface testing platform in the embodiment of the present application three, in interface description data library pre- Fixed data format is that JSON passes through Fig. 3 and one for test environment is the client server environment by http protocol communication The scheme of the embodiment of the present invention two is described in detail in a specific example.
If-test the abbreviation of InterFace (If be) interface testing platform in Fig. 3 include: If-HttpTest module, If-Builder module and If-Validator module;Wherein:
If-httptest module be for real simulation in specific context environment and business scenario http request The module of data, the http request are based on apache commons httpclient 3.0.1.
If-validator module is that the data for returning to interface respond the module verified, which is based on Json-schema-validator Open Framework introduces mockjs semantic label, increases customized keyword " iftest ", Here customized keyword is preset keyword, to provide expansible semantization verification mode;
If-builder module is for describing the module that automation generates required parameter value according to the request data of interface;
It is said so that the interface to the entitled http://example.com/demo.htm of interface is tested as an example below It is bright:
Assuming that the corresponding request type of http://example.com/demo.htm is asked in interface description data library for get It asks, request data description and response data description are respectively the following contents:
1) request data describes:
The meaning that above-mentioned request data description indicates is this interface name institute of http://example.com/demo.htm The parameter that must be filled out in the request data of the interface of expression is searchNo, must fill out in parameter namely this hair embodiment two here Request field, the searchNo can be described as " search number ", and the data type of search number is character string type, and value range is In 0 natural number less than 5;
2) response data describes are as follows:
Above-mentioned 2) response data description expression is meant that: three response fields comprising core: itemId/detail/ Pic, these three response fields be all it is necessary, cannot lack, secondly, itemId is one 11 numbers, detail needs As http://detail.tmall.com/item.htm? equally, pic is a figure to id=15179732651&q=iphoney " Piece link, and picture pixels are: 344x228.
Above-mentioned interface testing platform carry out the process of interface testing the following steps are included:
Step 1: it is the to be measured of http://example.com/demo.htm that If-builder module, which obtains interface name, It tries the request data description of mouth, such as above-mentioned given 1) request data description, which is also that the get of http is asked It asks;
Step 2: If-builder module is described according to the above-mentioned 1) request data of acquisition, request wherein included is determined Field is search number searchNo, which is also that must fill out parameter field;Include in above-mentioned 1) request data description Must fill out parameter field using this keyword of required indicate, only search one field of number;
Step 3: if-builder module according to iftest this preset keyword, from above-mentioned 1) request data describe The constraint condition function of middle searchNo is@natural (0,5);
Step 4: if-builder module has one must fill out parameter as searchNo according to request, and searchNo Value is only 0 to 5 natural number, the required parameter value of generation are as follows: 0,5, do not fill out parameter, null, -1,6, xyz;Such as table (2) institute Show, naturally it is also possible to including others be worth, the required parameter value generated here be category determine, theoretically for these ginseng Numerical value can represent all parameter values.
Table (2)
5th step, if-builder module are asked according to searchNo and according to each interface that each required parameter value actually generates It asks shown in data such as table (3):
Table (3)
case1 Http:// example.com/demo? searchNo=0
case2 Http:// example.com/demo? searchNo=5
case3 http://example.com/demo
case4 Http:// example.com/demo? searchNo=
case5 Http:// example.com/demo? searchNo=-1
case6 Http:// example.com/demo? searchNo=6
case7 Http:// example.com/demo? searchNo=xyz
Step 6: If-httptest module respectively sends each request data (request data of the case1 into case6) To the system under test (SUT) server-side (System Under Test, SUT) namely server where the interface to be tested;
Here If-httptest module sends request data, sends for simulation.
Step 7: If-validator module receives the number of responses for the request data that the server returns According to;Assuming that being directed to http://example.com/demo at this time? the response data of this request data of searchNo=0 is as follows:
3) response data:
Above-mentioned 3) response data indicates to mean in the response of return comprising these three responses of itemId, detail, pic Field, and the field value of itemId field be 12323231451, detail field field value be " http: // Detail.tmall.com/item.htm? the field value of this field of id=15179732651&q=iphone ", pic are as follows: " http://g.ald.alicdn.com/bao/uploaded/TB1Y7t4FVXXXXc0XFXXtKXbFXXX.GIF"。
Step 8: If-validator module obtains the interface name of the interface to be tested from interface description data library Corresponding response data description, such as above-mentioned 2) response data describe.
Step 9: If-validator module determines each of the response field concentration in the response data description obtained Response field is respectively as follows: itemId, detail and pic;
Step 10: If-validator module according to iftest this preset keyword, from the number of responses of acquisition It is@bizNum (11,11) according to determining that the field value of this response field of itemId should meet constraint condition function in description; The constraint condition function that the field value of this response field of detail should meet be@url (' http: // Detail.tmall.com/item.htm? id=15179732651&q=iphone', ' all'), what which indicated Url where the meaning is the detail should the title including server, the path in the server, goods number and inquiry ginseng Number, in the constraint condition ' all' indicates all protocol name, domain name, the path in the server, goods number and inquiry Does is parameter intended to and http://detail.tmall.com/item.htm? phase in id=15179732651&q=iphone Match, refers to for the matching here of this example in the present embodiment three identical;The field value of this response field of pic should expire Sufficient constraint condition function is@img (' 344x228');
Step 11: If-validator module utilizes itemId and@bizNum (11,11), the detail in the 9th step With@url (' http://detail.tmall.com/item.htm? id=15179732651&q=iphone', ' all'), Pic and img (' 344x228') verify above-mentioned 3) response data, at this time known to above-mentioned 3) response data include These three response fields of itemId, detail and pic, and the field value of each response field meets corresponding constraint condition, Therefore, the verification result of acquisition is to be proved to be successful.
If server-side returns to following situation 1, situation 2 or situation 3, verification result is failure:
Situation 1:
Situation 2:
Situation 3:
{
"data":{
"items":[
{
"itemId":"1232323",
" detail ": " http://detail.tmall.com/item.htm? id=15179732651&q= iphone",
"pic":"This is a picture"
}
]
}
}
ItemId is not 11 digits in situation 1, and therefore, verification result is authentication failed;It is provided in detail in situation 2 The address of server is http://detail.taobao.com, rather than therefore http://detail.tmall.com is tested Card result is authentication failed;Pic is This is a picture in situation 3, this is a string of character strings, rather than a picture Link, therefore, verification result is authentication failed;
In addition, during running interface test method of the embodiment of the present invention one to embodiment three or running it Afterwards, also the data of the output of each step can also be described as the interface for the interface to be tested for carrying out interface testing, Fig. 3 Content in the dotted line frame in middle interface description data library is the data that a step generates, below by example IV to this side Case is illustrated.
Example IV
On the basis of the interface test method described in embodiment one to embodiment three, the interface test method can also be wrapped Following steps 1 are included to any one or more steps in step 4:
Step 1: using the request data for interface to be tested of generation as the interface testing use-case of the interface to be tested; Establish the incidence relation of the interface name of the interface testing use-case and the interface to be tested.
Step 2: according to the interface code to be tested, generating the interface testing script of the interface to be tested;Establish life At the interface to be tested interface testing script and the interface to be tested interface name incidence relation.
Step 3: the interface testing report for the interface to be tested being generated according to the verification result, and establishes this and connects The incidence relation of mouth test report and the interface name of the interface to be tested, the interface testing report are to be measured including having verified that Try mouth one of request data, verification result, verification result state and verification result Failure Causes Analysis or a variety of, institute Stating verification result state includes successfully and failing.
Step 4: using the received response data as the test data of interface to be tested;Establish the interface testing data With the incidence relation of the interface name of the interface to be tested.
It should be noted that being above to facilitate statement with the literary style of step 1 to step 4, between actually each step simultaneously Sequence in no particular order.
The addition storage incidence relation to interface is retouched after each step into step 4 of above-mentioned steps 1 establishes incidence relation When stating the step of database, connecing on the basis of the interface test method any into embodiment three of embodiment one can also be formed in Mouth descriptive data base generation method.
The process of above-mentioned steps 1 to step 4 can be as shown in figure 4, be a circulation shown in Fig. 4, to a certain interface A After being tested, obtain interface A complete interface description data (including interface A interface requests data description, The description of interface response data, interface testing data, interface testing use-case, interface testing script and interface testing report), suceeding generation When being tested when code continuous integrating (Code Continuous Integration) for interface A, can also directly it utilize The complete interface description data of acquired interface A.That is circulation here refers to the lasting collection of subsequent code The circulation of the interface test method in, the continuous integrating of code here are a kind of practice of software, new when being integrated with Code or after having modified original code, automation carries out verifying and regression test, guarantee it is integrated after quality.
Four scheme through the embodiment of the present invention, the description of originally requested content data and response data are retouched in interface description data library It states, is described after smoothly completing primary test comprehensively in the interface of each test, can get the interface includes interface testing Use-case, interface testing report, interface testing data and interface testing script further enrich the interface description of interface, and Since the interface description of this part of interface to be tested may be also used in the lasting concentration of the subsequent interface code, have activated to The interface of test interface describes, so that interface description has accuracy, maintainability, testability, verifiability, so that Project team member can rely on by force this part of interface specification and respectively subsequent work is unfolded, and solve front and back end research and development and be respectively detached from other side The efficient test of environment reduces front and back end and links up cost, improves joint debugging efficiency, and can efficiently develop stable automation Test script guarantees the quality and stability of interface Life cycle, and then guarantees interface quality or even entire software systems and product Quality, promoted efficiency of research and development, reduce research and development cost.
Below to the above-mentioned interface testing use-case of acquisition, interface testing report, interface testing data and interface testing script It is specific that how the use in interface continuous integrating is illustrated:
The continuous integrating of code can be divided into front-end code continuous integrating and back-end code continuous integrating, and code continuous integrating Two elements of needs, one is executable script, the second is task scheduling system;Each executable script cans be compared to one Executable test case, include in test case: test data, expected results (assertion verification point) etc. work as script execution Afterwards, so that it may obtain test report corresponding to this use-case;And task scheduling system, that industry mainstream is hudson flat at present Platform, effect are exactly automatic trigger script execution under given conditions, and specifically i will not repeat them here.At present in the scene of this patent In, device generates required executable script (junit test script) in back-end code continuous integrating, this script is put into In the projects of one java, then code can be realized and continue regression test, then lead to postponing on hudson platform Test report is crossed to provide the foundation for judging code continuous integrating quality for user;The interface testing number generated in this same device According to, provide test data for front-end code continuous integrating, can be used for front-end code continuous integrating or UI automation return survey Examination.
The example that the scheme of the embodiment of the present application is used in detailed programs is provided in Fig. 5:
Detailed process is described as follows:
Step 1: the common provisioning interface description in front and back end (mainly includes that interface requests description and interface response are retouched here State), interface description is recorded in interface description data library by certain mode (being currently third party's interface management platform);
Step 2: interface description is tested in test intervention, and increase semantic label according to the actual situation;
It is above-mentioned that interface description is tested, it is in fact exactly " static test " described in soft project.Here it is mainly Whether test interface describes perfect, if appropriate, if to meet best practices, if to meet business convention and specification, be one The process of a verifying.
Step 3: front end, rear end, the full decoupled concurrent working of test and from surveying, test is carried out by If-Test platform Test script exploitation;
Step 4: can timely feed back and currently connect by the stable automatic test script that can be used for continuous integrating The life state of mouth, and the true returned data of server-side obtained is sent by simulation true request, back feeding is retouched in interface It states, providing for further expanding function may (such as: the lasting recurrence of front-end code).
Embodiment five
Based on the same inventive concept with embodiment one to example IV, the embodiment of the present application five provides a kind of interface testing Device, structural schematic diagram are as shown in Figure 6, comprising: request data generation unit 61, receiving unit 63, obtains transmission unit 62 Unit 64 and authentication unit 65, in which:
Request data generation unit 61, for generating the request data for being directed to interface to be tested;
Transmission unit 62, the server for being sent to the request data where the interface to be tested;
Receiving unit 63, the response data for the request data returned for receiving the server;
Acquiring unit 64, for obtaining the corresponding sound of interface name of the interface to be tested from interface description data library It answers data to describe, includes that interface name and its corresponding response data describe in the interface description data library, the number of responses It include the response field collection that correct response data should include and each response field that the response field is concentrated according to description The constraint condition that field value should meet;
Authentication unit 65, for utilizing the response field collection and the response field collection in the response data description obtained In the constraint condition that should meet of field value of each response field the received response data is verified, verified As a result.
Preferably, the description in the interface description data library meets setting syntax format, which includes The semantic label being made of keyword and its corresponding semantic function, the constraint condition that the field value of response field should meet is by pre- If keyword and its corresponding constraint condition function constitute semantic label indicate;
The authentication unit 65, the response field concentration in response data description obtained specifically for determination include Each response field;For determining each response field, according to the preset keyword, from the response data of acquisition The corresponding constraint condition function of field value of the response field is determined in description;Judge include in the received response data The set equality whether set that whole fields are constituted is constituted with the response field collection in the response data description of acquisition, with And whether the field value of each response field is all satisfied corresponding constraint condition function;If including in the received response data The set equality that the set that whole fields are constituted is constituted with the response field collection in the response data description obtained, and each sound The field value of field is answered to be all satisfied corresponding constraint condition function, it is determined that be proved to be successful;It is on the contrary, it is determined that authentication failed.
It preferably, further include interface name and its corresponding request type and request data in the interface description data library Description, the request data description include that the request field collection that correct request data should include and the request field are concentrated The constraint condition that each request field should meet;
The request data generation unit 61, specifically for obtaining the interface to be tested from interface description data library The description of interface name corresponding requests data and request type;According to each request word for including in the description of the request data of acquisition The constraint condition that the field value of section field and each request field should meet, generating request type is the request type obtained The request data for the interface to be tested.
Preferably, the description in the interface description data library meets setting syntax format, which includes The semantic label being made of keyword and its corresponding semantic function, the constraint condition that the field value of request field should meet is by pre- If keyword and corresponding constraint condition function constitute semantic label indicate;The request data generation unit 61, comprising: Constraint condition function obtains subelement and request data generates subelement;
The constraint condition function obtains subelement, is used for according to the preset keyword, from the request of acquisition The corresponding constraint condition function of field value of each request field is determined in data description;
The request data generates subelement, for the corresponding constraint condition function of field value according to each request field Generate the request data for the interface to be tested that request type is the request type obtained.
Preferably, the request data generates subelement, corresponding specifically for the field value according to each request field Constraint condition function generates required parameter value, which is the relevant parameter value of business or the unrelated parameter of business Value;Generating request type using each request field and corresponding required parameter value is the request type obtained for described The request data of interface to be tested.
Preferably, described device further include:
First incidence relation establishes unit 66, and the request data for interface to be tested for that will generate is to be measured as this It tries the interface testing use-case of mouth;Establish the incidence relation of the interface name of the interface testing use-case and the interface to be tested.
Preferably, the transmission unit 62 is specifically used for generating connecing for the interface to be tested according to the request data Mouth test code;The interface testing code realization generated by operation sends the data to the interface to be tested;
Preferably, described device further include:
Second incidence relation establishes unit 67, for generating the interface to be tested according to the interface code to be tested Interface testing script;Establish the interface testing script of the interface to be tested generated and the interface name of the interface to be tested Incidence relation.
Preferably, described device further include:
Third incidence relation establishes unit 68, using the received response data as the test data of interface to be tested; Establish the incidence relation of the interface testing data and the interface name of the interface to be tested.
Preferably, described device further include:
4th incidence relation establishes unit 69, generates the interface survey for the interface to be tested according to the verification result Examination report, and establish the incidence relation of interface testing report and the interface name of the interface to be tested, the interface testing report Accuse request data, verification result, verification result state and verification result failure cause point including the interface to be tested having verified that One of analysis is a variety of, and the verification result state includes successfully and failing.
The specific implementation process of each unit can refer to the interface into example IV of embodiment one and survey in the embodiment of the present application five The description of method for testing part, which is not described herein again.
Embodiment six
Based on the same inventive concept with embodiment one to example IV, the embodiment of the present application six is based in embodiment five Interface test device provides a kind of interface description data library generating means, structural schematic diagram as shown in fig. 7, comprises: first close Connection relationship establishes unit 71, the second incidence relation establishes unit 72, third incidence relation establishes unit 73, the 4th incidence relation is built Vertical unit 74 and storage unit 75;Wherein:
First incidence relation establishes unit 71, for generating connecing for the interface to be tested according to interface code to be tested Mouth test script;Establish the pass of the interface testing script of the interface to be tested generated and the interface name of the interface to be tested Connection relationship, the interface code to be tested are generated according to the request data;
Second incidence relation establishes unit 72, for will generate be directed to interface to be tested request data it is to be tested as this The interface testing use-case of interface establishes the incidence relation of the interface name of the interface testing use-case and the interface to be tested;
Third incidence relation establishes unit 73, for using the received response data as the test number of interface to be tested According to establishing the incidence relation of the interface name of the interface testing data and the interface to be tested;
4th incidence relation establishes unit 74, for generating connecing for the interface to be tested according to the verification result Mouth test report, establishes the incidence relation of interface testing report and the interface name of the interface to be tested, the interface testing Report includes request data, verification result, verification result state and the verification result failure cause for the interface to be tested having verified that One of analysis is a variety of, and the verification result state includes successfully and failing;
Storage unit 75, for by the interface name of the interface testing script of the interface to be tested and the interface to be tested Incidence relation, the incidence relation of interface name of interface testing use-case and the interface to be tested, interface testing report and should The incidence relation of the interface name of the incidence relation of the interface name of interface to be tested and interface to be tested is stored in interface description In database.
The specific implementation process of each unit can refer to the interface into example IV of embodiment one and survey in the embodiment of the present application six The description of method for testing part, which is not described herein again.
Through the above description of the embodiments, those skilled in the art can be understood that the embodiment of the present invention The mode of necessary general hardware platform can also be added to realize by software by hardware realization.Based on this understanding, The technical solution of the embodiment of the present invention can be embodied in the form of software products, which can store non-at one In volatile storage medium (can be CD-ROM, USB flash disk, mobile hard disk etc.), including some instructions are used so that a computer Equipment (can be personal computer, server or the network equipment etc.) executes method described in each embodiment of the present invention.
It will be appreciated by those skilled in the art that attached drawing is the schematic diagram of a preferred embodiment, module or stream in attached drawing Journey is not necessarily implemented necessary to the present invention.
It will be appreciated by those skilled in the art that the module in embodiment in terminal can describe to be distributed according to embodiment In the terminal of embodiment, corresponding change can also be carried out and be located in one or more terminals different from the present embodiment.It is above-mentioned The module of embodiment can be merged into a module, can also be further split into multiple submodule.
The serial number of the above embodiments of the invention is only for description, does not represent the advantages or disadvantages of the embodiments.
Obviously, various changes and modifications can be made to the invention without departing from essence of the invention by those skilled in the art Mind and range.In this way, if these modifications and changes of the present invention belongs to the range of the claims in the present invention and its equivalent technologies Within, then the present invention is also intended to include these modifications and variations.

Claims (12)

1. a kind of interface test method characterized by comprising
Generate the request data for being directed to interface to be tested;
The server request data being sent to where the interface to be tested;
Receive the response data for the request data that the server returns;And
The corresponding response data description of interface name of the interface to be tested, the interface are obtained from interface description data library It include that interface name and its corresponding response data describe in descriptive data base, the response data description includes correctly response The constraint item that the field value for each response field that the response field collection and the response field that data should include are concentrated should meet Part;
Utilize the response field collection and each response field concentrated of the response field in the response data description of acquisition The constraint condition that field value should meet verifies the received response data, obtains verification result.
2. the method as described in claim 1, which is characterized in that the description in the interface description data library meets setting grammer Format, the setting syntax format include the semantic label being made of keyword and its corresponding semantic function, the word of response field The semantic label that the constraint condition that segment value should meet is made of preset keyword and its corresponding constraint condition function indicates;
Utilize the response field collection and each response field concentrated of the response field in the response data description of acquisition The constraint condition that field value should meet verifies the received response data, obtains verification result, comprising:
Determine that the response field in the response data obtained description concentrates each response field for including;
For determining each response field, according to the preset keyword, from the description of the response data of acquisition really The corresponding constraint condition function of field value of the fixed response field;
Judge the whole fields for including in the received response data constitute set whether the response data with acquisition Whether the field value of set equality and each response field that the response field collection in description is constituted is all satisfied corresponding constraint item Part function;
During if the set that the whole fields for including in the received response data are constituted is described with the response data obtained The set equality that constitutes of response field collection, and the field value of each response field is all satisfied corresponding constraint condition function, then really Surely it is proved to be successful;It is on the contrary, it is determined that authentication failed.
3. the method as described in claim 1, which is characterized in that further include in the interface description data library interface name and its Corresponding request type and request data description, the request data description include the request word that correct request data should include The constraint condition that each request field that section collection and the request field are concentrated should meet;
Generate the request data for being directed to interface to be tested, comprising:
The description of interface name corresponding requests data and the request type of the interface to be tested are obtained from interface description data library;
It is answered according to the field value of each request field field and each request field that include in the description of the request data of acquisition The constraint condition of satisfaction generates the number of request for the interface to be tested that request type is the request type obtained According to.
4. method as claimed in claim 3, which is characterized in that the description in the interface description data library meets setting grammer Format, the setting syntax format include the semantic label being made of keyword and its corresponding semantic function, the word of request field The semantic label that the constraint condition that segment value should meet is made of preset keyword and corresponding constraint condition function indicates;
It should be met according to the field value of each request field and each request field that include in the description of the request data of acquisition Constraint condition generate be directed to the interface to be tested request data, comprising:
According to the preset keyword, the field value pair of each request field is determined from the description of the request data of acquisition The constraint condition function answered;
Generating request type according to the corresponding constraint condition function of the field value of each request field is the request class obtained The request data for the interface to be tested of type.
5. method as claimed in claim 4, which is characterized in that according to the corresponding constraint condition of the field value of each request field Function generates the request data for the interface to be tested that request type is the request type obtained, comprising:
Required parameter value is generated according to the corresponding constraint condition function of the field value of each request field, which is industry It is engaged in relevant parameter value or the unrelated parameter value of business;
Using each request field and corresponding required parameter value generate the request type that request type is acquisition for institute State the request data of interface to be tested.
6. method a method as claimed in any one of claims 1 to 5, which is characterized in that the method also includes:
Using the request data for interface to be tested of generation as the interface testing use-case of the interface to be tested;
Establish the incidence relation of the interface name of the interface testing use-case and the interface to be tested.
7. method a method as claimed in any one of claims 1 to 5, which is characterized in that the request data is sent to described to be measured try Mouthful, comprising:
According to the request data, the interface testing code of the interface to be tested is generated;
The interface testing code realization generated by operation sends the data to the interface to be tested;
The method also includes:
According to the interface code to be tested, the interface testing script of the interface to be tested is generated;
Establish the incidence relation of the interface testing script of the interface to be tested generated and the interface name of the interface to be tested.
8. method a method as claimed in any one of claims 1 to 5, which is characterized in that the method also includes:
The interface testing report for the interface to be tested is generated according to the verification result, and establishes interface testing report With the incidence relation of the interface name of the interface to be tested, the interface testing report includes asking for the interface to be tested having verified that Ask one of data, verification result, verification result state and verification result Failure Causes Analysis or a variety of, the verification result State includes successfully and failing.
9. method a method as claimed in any one of claims 1 to 5, which is characterized in that the method also includes:
Using the received response data as the test data of interface to be tested;
Establish the incidence relation of the interface testing data and the interface name of the interface to be tested.
10. a kind of interface description data library generating method, which is characterized in that the interface description data library generating method is based on power Benefit requires any interface test method of 1-5, and interface description data library generating method includes:
According to interface code to be tested, the interface testing script of the interface to be tested is generated;Establish the described to be tested of generation The incidence relation of the interface name of the interface testing script and interface to be tested of interface, and the incidence relation is stored in and is connect In mouth descriptive data base, the interface code to be tested is generated according to the request data;And
The request data for interface to be tested will be generated as the interface testing use-case of the interface to be tested, establish interface survey The incidence relation of example on probation and the interface name of the interface to be tested, and the incidence relation is stored in interface description data In library;And
Using the received response data as the test data of interface to be tested, it is to be tested with this to establish the interface testing data The incidence relation of the interface name of interface, and the incidence relation is stored in interface description data library;And
According to the verification result generate for the interface to be tested interface testing report, establish the interface testing report with The incidence relation of the interface name of the interface to be tested, and the incidence relation is stored in interface description data library, it is described Interface testing report includes request data, verification result, verification result state and the verification result for the interface to be tested having verified that One of Failure Causes Analysis is a variety of, and the verification result state includes successfully and failing.
11. a kind of interface test device characterized by comprising
Request data generation unit, for generating the request data for being directed to interface to be tested;
Transmission unit, the server for being sent to the request data where the interface to be tested;
Receiving unit, the response data for the request data returned for receiving the server;
Acquiring unit, for obtaining the corresponding response data of interface name of the interface to be tested from interface description data library It describes, includes that interface name and its corresponding response data describe in the interface description data library, the response data description The field value for each response field that the response field collection that should include including correct response data and the response field are concentrated The constraint condition that should meet;
Authentication unit, for using obtain the response data description in response field collection and the response field concentrate it is every The constraint condition that the field value of one response field should meet verifies the received response data, obtains verification result.
12. a kind of interface description data library generating means, which is characterized in that interface description data library generating means are based on power Benefit require 11 described in interface test device, interface description data library generating means include:
First incidence relation establishes unit, for generating the interface testing of the interface to be tested according to interface code to be tested Script;Establish the interface testing script of the interface to be tested and being associated with for the interface name of the interface to be tested generated System, the interface code to be tested is generated according to the request data;
Second incidence relation establishes unit, for that will generate the request data for being directed to interface to be tested as the interface to be tested Interface testing use-case establishes the incidence relation of the interface name of the interface testing use-case and the interface to be tested;
Third incidence relation establishes unit, for building using the received response data as the test data of interface to be tested Found the incidence relation of the interface testing data and the interface name of the interface to be tested;
4th incidence relation establishes unit, for generating the interface testing for being directed to the interface to be tested according to the verification result The incidence relation of interface testing report and the interface name of the interface to be tested, the interface testing report packet are established in report It includes in request data, verification result, verification result state and the verification result Failure Causes Analysis for the interface to be tested having verified that It is one or more, the verification result state include successfully and failure;
Storage unit, for being associated with the interface testing script of the interface to be tested and the interface name of the interface to be tested Incidence relation, the interface testing of relationship, interface testing use-case and the interface name of the interface to be tested are reported to be tested with this The incidence relation of the interface name of the incidence relation of the interface name of interface and interface to be tested is stored in interface description data library In.
CN201510155540.1A 2015-04-02 2015-04-02 Interface test method, interface description data library generating method and device Active CN106155891B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510155540.1A CN106155891B (en) 2015-04-02 2015-04-02 Interface test method, interface description data library generating method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510155540.1A CN106155891B (en) 2015-04-02 2015-04-02 Interface test method, interface description data library generating method and device

Publications (2)

Publication Number Publication Date
CN106155891A CN106155891A (en) 2016-11-23
CN106155891B true CN106155891B (en) 2019-07-05

Family

ID=57338358

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510155540.1A Active CN106155891B (en) 2015-04-02 2015-04-02 Interface test method, interface description data library generating method and device

Country Status (1)

Country Link
CN (1) CN106155891B (en)

Families Citing this family (46)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106776345A (en) * 2017-01-16 2017-05-31 北京恒华伟业科技股份有限公司 A kind of interface delivery system and interface docking method of testing
CN106909492B (en) * 2017-03-07 2020-05-12 北京盛世全景科技股份有限公司 Method and device for tracking service data
CN108664388A (en) * 2017-03-31 2018-10-16 北京京东尚科信息技术有限公司 Dynamic field data return to test system, method, electronic equipment and the readable storage medium storing program for executing of interface
CN107122296B (en) * 2017-04-18 2020-06-19 上海雷腾软件股份有限公司 Method and apparatus for data assertion for test interface
CN108874654B (en) * 2017-05-15 2022-08-16 创新先进技术有限公司 Idempotent validity test method, device and equipment and readable medium
CN107171889A (en) * 2017-05-27 2017-09-15 北京金山安全软件有限公司 Network application interface test method and device and electronic equipment
CN107403112B (en) * 2017-07-31 2020-07-31 北京京东尚科信息技术有限公司 Data checking method and equipment thereof
CN109495334B (en) * 2017-09-13 2021-05-28 杭州海康威视系统技术有限公司 Test method and device
CN107608902A (en) * 2017-10-23 2018-01-19 中国联合网络通信集团有限公司 Routine interface method of testing and device
CN107741911A (en) * 2017-11-01 2018-02-27 广州爱九游信息技术有限公司 Interface test method, device, client and computer-readable recording medium
CN108038125B (en) * 2017-11-07 2021-06-01 平安科技(深圳)有限公司 Method, device, equipment and storage medium for automatically comparing fund system test values
CN109726098A (en) * 2018-03-16 2019-05-07 平安科技(深圳)有限公司 Interface test method, device and computer readable storage medium
CN108664396A (en) * 2018-05-08 2018-10-16 平安普惠企业管理有限公司 Bank's interactive interface verification method, device, computer equipment and storage medium
CN108628750B (en) * 2018-05-16 2021-11-05 无线生活(杭州)信息科技有限公司 Test code processing method and device
CN108733569B (en) * 2018-05-25 2022-09-02 北京五八信息技术有限公司 Interface automatic testing method and device, storage medium and equipment
CN108804267A (en) * 2018-05-30 2018-11-13 平安普惠企业管理有限公司 Database polling method, device, computer equipment and storage medium
CN108900369B (en) * 2018-05-31 2021-08-27 武汉虹信技术服务有限责任公司 Interface testing method based on post request
CN110554929B (en) * 2018-06-04 2023-07-07 百度在线网络技术(北京)有限公司 Data verification method, device, computer equipment and storage medium
CN109101415A (en) * 2018-06-25 2018-12-28 平安科技(深圳)有限公司 Interface test method, system, equipment and the storage medium compared based on database
CN108897687B (en) * 2018-06-29 2022-04-01 泰华智慧产业集团股份有限公司 API automatic testing method and system based on data driving
CN109062784B (en) * 2018-07-06 2021-04-27 北京大学 Interface parameter constraint code entry positioning method and system
CN109298997A (en) * 2018-08-08 2019-02-01 平安科技(深圳)有限公司 Interface test method, system, computer equipment and storage medium
CN109189622A (en) * 2018-08-21 2019-01-11 上海起作业信息科技有限公司 Interface test method and device, electronic equipment, storage medium
CN109165127B (en) * 2018-08-29 2022-09-02 北京奇艺世纪科技有限公司 Problem interface positioning method and device and electronic equipment
CN109032956B (en) * 2018-09-11 2022-03-22 郑州云海信息技术有限公司 Interface testing method and device
CN109376079A (en) * 2018-09-26 2019-02-22 深圳壹账通智能科技有限公司 The test method and server that interface calls
CN109308266A (en) * 2018-11-30 2019-02-05 北京微播视界科技有限公司 Construction method, test method, device, equipment and the medium of test case
CN109857634A (en) * 2018-12-15 2019-06-07 中国平安人寿保险股份有限公司 Interface testing parameter verification method, apparatus, electronic equipment and storage medium
CN109889402B (en) * 2019-01-23 2021-03-12 北京字节跳动网络技术有限公司 Method and apparatus for generating information
CN109800168A (en) * 2019-01-24 2019-05-24 北京奇艺世纪科技有限公司 The test method and device of the action event data of software
CN110109656B (en) * 2019-03-25 2024-06-28 平安科技(深圳)有限公司 Interface simulation method, device, computer equipment and storage medium
CN109902026A (en) * 2019-03-27 2019-06-18 北京奇艺世纪科技有限公司 A kind of processing method and test platform of interface testing information
CN110188036A (en) * 2019-05-10 2019-08-30 深圳前海微众银行股份有限公司 A kind of method for testing software and device
CN110334021B (en) * 2019-06-25 2023-04-18 深圳前海微众银行股份有限公司 Interface test case generation method, device, equipment and storage medium
CN110543428B (en) * 2019-09-09 2023-11-24 中国工商银行股份有限公司 Application system testing method and device
CN110489349B (en) * 2019-09-23 2022-06-03 四川长虹电器股份有限公司 JSON configuration file-based interface test method
CN110704328B (en) * 2019-10-15 2021-09-07 北京城市网邻信息技术有限公司 Interface testing method and device, electronic equipment and readable storage medium
CN110990276A (en) * 2019-11-29 2020-04-10 泰康保险集团股份有限公司 Automatic testing method and device for interface field and storage medium
CN111555928A (en) * 2020-04-14 2020-08-18 珠海格力电器股份有限公司 Method and device for monitoring system abnormity, computer equipment and storage medium
CN111950252A (en) * 2020-07-31 2020-11-17 上海中通吉网络技术有限公司 HTTP response message format verification method, device and equipment
CN112346775B (en) * 2020-09-21 2024-02-02 杭州数智政通科技有限公司 Index data general processing method, electronic device and storage medium
CN112835782B (en) * 2020-12-22 2022-06-03 北京健康之家科技有限公司 Interface access test method and system
CN112860552B (en) * 2021-02-02 2023-12-15 贝壳找房(北京)科技有限公司 Keyword mechanism operation method and device
CN112965909B (en) * 2021-03-19 2024-04-09 湖南大学 Test data, test case generation method and system and storage medium
CN113886221B (en) * 2021-09-13 2022-09-23 前海飞算云智软件科技(深圳)有限公司 Test script generation method and device, storage medium and electronic equipment
CN113687965B (en) * 2021-10-25 2022-03-01 深圳市工易付电子科技有限公司 Data interaction method, device, equipment and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103136095A (en) * 2011-11-28 2013-06-05 阿里巴巴集团控股有限公司 Method, device and system of test application program interface
CN103312551A (en) * 2012-03-12 2013-09-18 腾讯科技(深圳)有限公司 Test method and test device of common gateway interface

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104346366B (en) * 2013-07-30 2017-11-24 国际商业机器公司 Extend the method and apparatus of test data

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103136095A (en) * 2011-11-28 2013-06-05 阿里巴巴集团控股有限公司 Method, device and system of test application program interface
CN103312551A (en) * 2012-03-12 2013-09-18 腾讯科技(深圳)有限公司 Test method and test device of common gateway interface

Also Published As

Publication number Publication date
CN106155891A (en) 2016-11-23

Similar Documents

Publication Publication Date Title
CN106155891B (en) Interface test method, interface description data library generating method and device
CN105099811B (en) Interface testing method and device
Marrs JSON at work: practical data integration for the web
CN105138448B (en) A kind of method and apparatus in the head end test page
US8949792B2 (en) Methods and systems for data service development
CN106776349B (en) Method and system for setting interface detection flow
US20190213116A1 (en) Generation of automated testing scripts by converting manual test cases
DK3011444T3 (en) METHOD AND APPARATUS FOR CODE VIRTUALIZATION AND GENERATION OF REMOTE PROCESS CALLS
CN106649103B (en) A kind of method and system of Android application program Automated Black Box Testing
CN109902016B (en) Web test method and test platform
CN109101415A (en) Interface test method, system, equipment and the storage medium compared based on database
CN108897687A (en) A kind of API automated testing method and system based on data-driven
CN109726098A (en) Interface test method, device and computer readable storage medium
CN109542791A (en) A kind of program large-scale concurrent evaluating method based on container technique
CN110096434A (en) Interface testing method and device
CN108459850B (en) Method, device and system for generating test script
US10079738B1 (en) Using a network crawler to test objects of a network document
CN106484488B (en) Integrated cloud Compilation Method and system
de Cleva Farto et al. Reuse of model-based tests in mobile apps
CN111881043B (en) Page testing method and device, storage medium and processor
Emanuel et al. Modularity index metrics for java-based open source software projects
KR102165037B1 (en) Code coverage measuring apparatus, code coverage measuring method of the code coverage mearusing apparatus, and code coverage measuring system
CN106155848B (en) A kind of test method and equipment
Sohan et al. SpyREST in action: An automated RESTful API documentation tool
CN107239265A (en) The binding method and device of Java functions and C function

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant