[go: up one dir, main page]

CN106201864A - A kind of application programming interface API method of testing, device and mobile device - Google Patents

A kind of application programming interface API method of testing, device and mobile device Download PDF

Info

Publication number
CN106201864A
CN106201864A CN201610479846.7A CN201610479846A CN106201864A CN 106201864 A CN106201864 A CN 106201864A CN 201610479846 A CN201610479846 A CN 201610479846A CN 106201864 A CN106201864 A CN 106201864A
Authority
CN
China
Prior art keywords
api
measured
test
server
response message
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.)
Pending
Application number
CN201610479846.7A
Other languages
Chinese (zh)
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.)
LeTV Holding Beijing Co Ltd
LeTV Information Technology Beijing Co Ltd
Original Assignee
LeTV Holding Beijing Co Ltd
LeTV Information Technology Beijing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by LeTV Holding Beijing Co Ltd, LeTV Information Technology Beijing Co Ltd filed Critical LeTV Holding Beijing Co Ltd
Priority to CN201610479846.7A priority Critical patent/CN106201864A/en
Publication of CN106201864A publication Critical patent/CN106201864A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Prevention of errors by analysis, debugging or testing of software
    • G06F11/3668Testing of software
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites

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 open a kind of application programming interface API method of testing of the embodiment of the present invention, device and mobile device.In the method, first obtain the test parameter of each API and store, if there is API to be measured in each API described, function according to described API to be measured determines the type of interaction of described API to be measured and server, and according to described API to be measured and the type of interaction of server and the test parameter of described API to be measured, generate the test request of described API to be measured;By the test request of described API to be measured by described API to be measured transmission to described server, and after described server produces response message, receive described response message by described API to be measured;According to described response message, determine the test performance of described API to be measured.Pass through the program, it is possible to realize test to API, and test process need not tester be operated manually, thus save manpower and time.

Description

A kind of application programming interface API method of testing, device and mobile device
Technical field
The present embodiments relate to software testing technology field, particularly relate to a kind of application programming interface API test Method, device and mobile device.
Background technology
Along with the development of scientific and technological level, the application of various mobile devices (such as smart mobile phone etc.) is increasingly extensive.The biggest portion Point mobile device is CS (Client/Server Structs, client-server structure), by with the holding alternately of server Row operations.In this case, mobile device is provided with API (Application Programming Interface, Application programming interface), when user needs mobile device to perform a certain operation, mobile device produces and asks letter accordingly Breath, and pass through API by described request message transmission to server, in order to server produces corresponding sound according to described solicited message Answer data.Then, described mobile device receives the response data of described server feedback by API, and according to described number of responses According to performing corresponding operating.Therefore, the performance of API influences whether the use of mobile device, needs to test API.
At present, when API is tested, it usually needs tester installs test application in a mobile device, and right Mobile device carries out touch control operation, so that described mobile device produces the corresponding solicited message of described touch control operation, will the most again The response data of server feedback, to server, is analyzed by described test application, obtains by described request message transmission The performance test results of API.
But, inventor finds in the research process of the application, when using prior art to carry out API test, needs to survey Examination personnel be operated manually mobile device, can expend a large amount of manpower and time.
Summary of the invention
For overcoming problem present in correlation technique, the embodiment of the present invention provides a kind of application programming interface API to survey Method for testing, device and mobile device.
In order to solve above-mentioned technical problem, the embodiment of the invention discloses following technical scheme:
First aspect according to embodiments of the present invention, it is provided that a kind of application programming interface API method of testing, including:
Obtain the test parameter of each API and store;
If each API described exists API to be measured, determine described API to be measured and service according to the function of described API to be measured The type of interaction of device, and according to described API to be measured and the type of interaction of server and the test parameter of described API to be measured, raw Become the test request of described API to be measured;
By the test request of described API to be measured by described API to be measured transmission to described server, and at described server After producing response message, receive described response message by described API to be measured;
According to described response message, determine the test performance of described API to be measured.
Optionally, also include:
Whether detection each API described exists API to be measured.
Optionally, whether each API described in described detection exists API to be measured, including:
If being respectively each API in advance to arrange corresponding test period, obtain the time of target API the last time test, When the time difference of current time with the time of described the last test is not less than test period, determine that described target API is API to be measured, wherein, described target API is the arbitrary API in each API described.
Optionally, whether each API described in described detection exists API to be measured, including:
Whether detection each API described there is software reconfiguration;
If each API described exists the API that software reconfiguration occurs, determine that the API of described generation software reconfiguration is to be measured API。
Optionally, also include:
Prestore the email address of target mailbox;
According to described response message, after determining the test performance of described API to be measured, according to the described mailbox ground of storage Location, transmits the performance test results of described API to be measured to described target mailbox.
Optionally, described API to be measured includes with the type of interaction of server: search type and amendment type.
Second aspect according to embodiments of the present invention, it is provided that a kind of application programming interface API test device, including:
Parameter memory module, for obtaining the test parameter of each API and storing;
, if there is API to be measured, according to the function of described API to be measured in each API described in test request generation module Determine the type of interaction of described API to be measured and server, and according to described API to be measured and the type of interaction of server and described The test parameter of API to be measured, generates the test request of described API to be measured;
Response message receiver module, for the most described by described API to be measured transmission by the test request of described API to be measured Server, and after described server produces response message, receive described response message by described API to be measured;
Test performance determines module, for according to described response message, determines the test performance of described API to be measured.
Optionally, also include:
Detection module, is used for detecting in each API described whether there is API to be measured.
Optionally, described detection module includes:
First detector unit, if being respectively each API in advance to arrange corresponding test period, described first detector unit is used In obtaining time of target API the last time test, current time and the time of described the last test time difference not During less than test period, determining that described target API is API to be measured, wherein, described target API is arbitrary in each API described API。
Optionally, described detection module includes:
Second detector unit, is used for detecting whether each API described occurs software reconfiguration, if existing in each API described There is the API of software reconfiguration, determine that the API of described generation software reconfiguration is API to be measured.
Optionally, also include:
Address memory module, for prestoring the email address of target mailbox;
Test result transport module, for according to described response message, after determining the test performance of described API to be measured, According to the described email address of storage, the performance test results of described API to be measured is transmitted to described target mailbox.
Optionally, described API to be measured includes with the type of interaction of server: search type and amendment type.
The third aspect according to embodiments of the present invention, it is provided that a kind of mobile device, including:
Processor;
For storing the memorizer of processor executable;
Wherein, described processor is configured to:
Obtain the test parameter of each API and store;
If each API described exists API to be measured, determine described API to be measured and service according to the function of described API to be measured The type of interaction of device, and according to described API to be measured and the type of interaction of server and the test parameter of described API to be measured, raw Become the test request of described API to be measured;
By the test request of described API to be measured by described API to be measured transmission to described server, and at described server After producing response message, receive described response message by described API to be measured;
According to described response message, determine the test performance of described API to be measured.
The technical scheme that embodiments of the invention provide can include following beneficial effect:
By scheme disclosed in the embodiment of the present invention, it is possible to realize the test to API, and test process need not survey Examination personnel be operated manually, thus saves manpower and time.
It should be appreciated that it is only exemplary and explanatory, not that above general description and details hereinafter describe The present invention can be limited.
Accompanying drawing explanation
Accompanying drawing herein is merged in description and constitutes the part of this specification, it is shown that meet the enforcement of the present invention Example, and for explaining the principle of the present invention together with description.
Fig. 1 is according to a kind of application programming interface API method of testing shown in the present invention one exemplary embodiment Configuration diagram;
Fig. 2 is according to a kind of application programming interface API method of testing shown in the present invention one exemplary embodiment Workflow schematic diagram;
Fig. 3 is according to another the application programming interface API method of testing shown in the present invention one exemplary embodiment Workflow schematic diagram;
Fig. 4 is according to another the application programming interface API method of testing shown in the present invention one exemplary embodiment Workflow schematic diagram;
Fig. 5 is to test device according to a kind of application programming interface API shown in the present invention one exemplary embodiment Structural representation;
Fig. 6 is to test device according to another application programming interface API shown in the present invention one exemplary embodiment Structural representation.
Detailed description of the invention
Here will illustrate exemplary embodiment in detail, its example represents in the accompanying drawings.Explained below relates to During accompanying drawing, unless otherwise indicated, the same numbers in different accompanying drawings represents same or analogous key element.Following exemplary embodiment Described in embodiment do not represent all embodiments consistent with the present invention.On the contrary, they are only with the most appended The example of the apparatus and method that some aspects that described in detail in claims, the present invention are consistent.
The open a kind of application programming interface API method of testing of the embodiment of the present invention, device and mobile device, to solve When utilizing prior art that API is tested, the problem that a large amount of manpower and time can be expended.
Configuration diagram shown in Figure 1, this schematic diagram includes mobile device 100 and server 200.Wherein, institute State in mobile device 100 and be built-in with API, it is possible to produce test by API method of testing disclosed in the embodiment of the present invention and device Request, and by built-in API by test request transmission extremely described server 200, then receive described server by described API The response message of 200 feedbacks, then according to described response message, obtains the test performance of described API to be measured.
The open a kind of application programming interface API method of testing of the embodiment of the present invention one.Workflow shown in Figure 2 Journey schematic diagram, described API method of testing comprises the following steps:
Step S11, obtain the test parameter of each API and store.
Wherein, the various information that described test parameter is required when referring to test API, generally include API's Version number, operation platform (such as Android platform or ios platform) and the channel number etc. of API, this is not limited by the application.
If step S12 each API described exists API to be measured, determine described to be measured according to the function of described API to be measured API and the type of interaction of server, and according to described API to be measured and the type of interaction of server and the survey of described API to be measured Examination parameter, generates the test request of described API to be measured.
Wherein, described API to be measured includes with the type of interaction of server: search type (i.e. GET type) and amendment type (i.e. POST type) etc..According to the function of described API to be measured, i.e. can determine that the type of interaction of described API to be measured and server.
It addition, if two API are different from the type of interaction of server, then the form of test request is the most different.Therefore, originally In inventive embodiments, generate institute according to described API to be measured with the type of interaction of server and the test parameter of described API to be measured State test request.
Step S13, by the test request of described API to be measured by described API to be measured transmission to described server, and in institute After stating server generation response message, receive described response message by described API to be measured.
Wherein, described response message be usually JSON (data interchange format of lightweight based on JavaScript language, JavaScript Object Notation) form.Described server is receiving the test request of described API to be measured transmission After, corresponding response message can be produced according to described test request, and feed back to mobile device, described mobile device is by described API to be measured receives described response message.
Step S14, according to described response message, determine the test performance of described API to be measured.
In a mobile device, API can be prestored in the case of functional, it should the response message got, and By it with this test process in the response message that receives compare, determine described API to be measured according to the matching degree of the two Test performance.Wherein, the two matching degree is the highest, illustrates that the test performance of described API to be measured is the best.
The open a kind of application programming interface API method of testing of embodiments of the invention one, sets with it, mobile Standby be capable of the test to API, and test process need not tester be operated manually, thus save manpower and Time.
Further, in application programming interface API method of testing disclosed in the embodiment of the present invention one, also include:
Prestore the email address of target mailbox;
According to described response message, after determining the test performance of described API to be measured, according to the described mailbox ground of storage Location, transmits the performance test results of described API to be measured to described target mailbox.
Wherein, described target mailbox can be the mailbox of project leader, or the mailbox of other testers.By described The performance test results transmission of API to be measured is to described target mailbox, it is possible to make project leader or other testers timely Obtain the test result of API.
It addition, before being transmitted, it is also possible to described the performance test results is classified, only will indicate that API poor-performing The performance test results transmit to target mailbox, in order to project leader or other testers API to poor performance in time Take measures.
Further, in application programming interface API method of testing disclosed in the present application, also include: detect each Whether API exists API to be measured.This operation can be accomplished in several ways.
The open a kind of application programming interface API method of testing of the embodiment of the present invention two, survey according to API in the method Whether examination each API of cycle detection exists API to be measured.Workflow schematic diagram shown in Figure 3, described API test side Method comprises the following steps:
Step S21, obtain the test parameter of each API and store.
Whether step S22, detection each API described exist API to be measured.Whether each API described in described detection deposits At API to be measured, including: if being respectively each API in advance to arrange corresponding test period, obtain the test of target API the last time Time, when the time difference of current time and the time of described the last test is not less than test period, determine described mesh Mark API is API to be measured, and wherein, described target API is the arbitrary API in each API described.
Such as, if the test period of target API is one hour, current time distance objective API the last time tests After time difference between time reaches one hour, it is determined that this target API is API to be measured.
If step S23 each API described exists API to be measured, determine described to be measured according to the function of described API to be measured API and the type of interaction of server, and according to described API to be measured and the type of interaction of server and the survey of described API to be measured Examination parameter, generates the test request of described API to be measured.
Step S24, by the test request of described API to be measured by described API to be measured transmission to described server, and in institute After stating server generation response message, receive described response message by described API to be measured.
Step S25, according to described response message, determine the test performance of described API to be measured.
Wherein, step S21 is identical with the operating process of step S11, and step S23 to step S25 and step S12 are to step The operating process of S14 is identical, can be cross-referenced, and here is omitted.
By API method of testing disclosed in the embodiment of the present invention two, it is possible to determine each according to the test period of each API Whether API exists API to be measured such that it is able to realize each API is periodically tested.
Further, in API method of testing disclosed in the embodiment of the present invention two, it is also possible to including:
Prestore the email address of target mailbox;
According to described response message, after determining the test performance of described API to be measured, according to the described mailbox ground of storage Location, transmits the performance test results of described API to be measured to described target mailbox.
Wherein, described target mailbox can be the mailbox of project leader, or the mailbox of other testers.By described The performance test results transmission of API to be measured is to described target mailbox, it is possible to make project leader or other testers timely Obtain the test result of API.
It addition, before being transmitted, it is also possible to described the performance test results is classified, only will indicate that API poor-performing The performance test results transmit to target mailbox, in order to project leader or other testers API to poor performance in time Take measures.
The open a kind of application programming interface API method of testing of the embodiment of the present invention three, in the method according to API whether Occur software reconfiguration detects whether there is API to be measured in each API.Workflow schematic diagram shown in Figure 4, described application Program Interfaces API method of testing comprises the following steps:
Step S31, obtain the test parameter of each API and store.
Whether step S32, detection each API described exist API to be measured.Wherein, each API described in described detection is No there is API to be measured, including: whether detection each API described there is software reconfiguration, if each API described exists occur soft The API of part reconstruct, determines that the API of described generation software reconfiguration is API to be measured.
Wherein, if API occurs code build event, then it is assumed that this API occurs software reconfiguration.It addition, it is logical in mobile device Often can create Jenkins task, and by Jenkins task detection API, whether code build event occur, and detect After a certain API occurs code build event, determine that this API is API to be measured.
If step S33 each API described exists API to be measured, determine described to be measured according to the function of described API to be measured API and the type of interaction of server, and according to described API to be measured and the type of interaction of server and the survey of described API to be measured Examination parameter, generates the test request of described API to be measured.
Step S34, by the test request of described API to be measured by described API to be measured transmission to described server, and in institute After stating server generation response message, receive described response message by described API to be measured.
Step S35, according to described response message, determine the test performance of described API to be measured.
Wherein, step S31 is identical with the operating process of step S11, and step S33 to step S35 and step S12 are to step The operating process of S14 is identical, can be cross-referenced, and here is omitted.
By API method of testing disclosed in the embodiment of the present invention three, it is possible to when API occurs software reconfiguration, it is surveyed Examination, thus obtain the performance test results of the API after software reconfiguration in time.
Further, in API method of testing disclosed in the embodiment of the present invention three, it is also possible to including:
Prestore the email address of target mailbox;
According to described response message, after determining the test performance of described API to be measured, according to the described mailbox ground of storage Location, transmits the performance test results of described API to be measured to described target mailbox.
Wherein, described target mailbox can be the mailbox of project leader, or the mailbox of other testers.By described The performance test results transmission of API to be measured is to described target mailbox, it is possible to make project leader or other testers timely Obtain the test result of API.
It addition, before being transmitted, it is also possible to described the performance test results is classified, only will indicate that API poor-performing The performance test results transmit to target mailbox, in order to project leader or other testers API to poor performance in time Take measures.
Accordingly, the open a kind of application programming interface API test device of the embodiment of the present invention four.Shown in Figure 5 API test device structural representation, described API test device include: parameter memory module 110, test request generate mould Block 120, response message receiver module 130 and test performance determine module 140.
Wherein, described parameter memory module 110, for obtaining the test parameter of each API and storing.Described test parameter Various information required when referring to test API, generally include the version number of API, operation platform (such as Android platform or ios platform) and the channel number etc. of API, this is not limited by the application.
, if there is API to be measured, according to described to be measured in each API described in described test request generation module 120 The function of API determines the type of interaction of described API to be measured and server, and according to the interactive class of described API to be measured Yu server Type and the test parameter of described API to be measured, generate the test request of described API to be measured.
Described API to be measured includes with the type of interaction of server: searches type (i.e. GET type) and revises type (i.e. POST type) etc..According to the function of described API to be measured, i.e. can determine that the type of interaction of described API to be measured and server.
Described response message receiver module 130, for passing the test request of described API to be measured by described API to be measured Transport to described server, and after described server produces response message, receive described response message by described API to be measured.
Described test performance determines module 140, for according to described response message, determines the testability of described API to be measured Energy.
In a mobile device, API can be prestored in the case of functional, it should the response message got, and By it with this test process in the response message that receives compare, determine described API to be measured according to the matching degree of the two Test performance.Wherein, the two matching degree is the highest, illustrates that the test performance of described API to be measured is the best.
Device is tested, it is possible to realize the test to API by API disclosed in the embodiment of the present invention, and in test process Need not tester mobile device is operated manually, thus save manpower and time.
Further, in API test device disclosed in the embodiment of the present invention four, also include: detection module 150, described Detection module is used for detecting in each API described whether there is API to be measured.
Structural representation shown in Figure 6, wherein, described detection module 150 includes: the first detector unit 151, and/ Or second detector unit 152.
Wherein, if being respectively each API in advance to arrange corresponding test period, described first detector unit 151 is used for obtaining Taking the time of target API the last time test, the time difference in current time with the time of described the last test is not less than During test period, determining that described target API is API to be measured, wherein, described target API is the arbitrary API in each API described.
Such as, if the test period of target API is one hour, current time distance objective API the last time tests After time difference between time reaches one hour, it is determined that this target API is API to be measured.
By described first detector unit 151, it is possible to determine in each API whether deposit according to the test period of each API At API to be measured such that it is able to realize each API is periodically tested.
Described second detector unit 152 is used for detecting whether each API described occurs software reconfiguration, if each API described The middle API that there is generation software reconfiguration, determines that the API of described generation software reconfiguration is API to be measured.
Wherein, if API occurs code build event, then it is assumed that this API occurs software reconfiguration.It addition, it is logical in mobile device Often can create Jenkins task, and by Jenkins task detection API, whether code build event occur, and detect After a certain API occurs code build event, determine that this API is API to be measured.
By the second detector unit 152, it is possible to obtain the performance test results of the API after software reconfiguration in time.
Further, disclosed in the embodiment of the present invention, API test device also includes:
Address memory module, for prestoring the email address of target mailbox;
Test result transport module, for according to described response message, after determining the test performance of described API to be measured, According to the described email address of storage, the performance test results of described API to be measured is transmitted to described target mailbox.
Wherein, described target mailbox can be the mailbox of project leader, or the mailbox of other testers.By described The performance test results transmission of API to be measured is to described target mailbox, it is possible to make project leader or other testers timely Obtain the test result of API.
About the device in above-described embodiment, wherein modules performs the concrete mode of operation in relevant the method Embodiment in be described in detail, explanation will be not set forth in detail herein.
Accordingly, the open a kind of mobile device of the embodiment of the present invention five.Described mobile device includes:
Processor;
For storing the memorizer of processor executable;
Wherein, described processor is configured to:
Obtain the test parameter of each API and store;
If each API described exists API to be measured, determine described API to be measured and service according to the function of described API to be measured The type of interaction of device, and according to described API to be measured and the type of interaction of server and the test parameter of described API to be measured, raw Become the test request of described API to be measured;
By the test request of described API to be measured by described API to be measured transmission to described server, and at described server After producing response message, receive described response message by described API to be measured;
According to described response message, determine the test performance of described API to be measured.
Further, whether described processor exists API to be measured in being also configured to detection each API described.
Wherein, whether each API described in described detection exists API to be measured, including: set if being respectively each API in advance Put corresponding test period, obtain the time of target API the last time test, in current time and described the last test When the time difference of time is not less than test period, determining that described target API is API to be measured, wherein, described target API is described Arbitrary API in each API.
Or, whether each API described in described detection exists API to be measured, including:
Whether detection each API described there is software reconfiguration;
If each API described exists the API that software reconfiguration occurs, determine that the API of described generation software reconfiguration is to be measured API。
Further, described processor is also configured to
Prestore the email address of target mailbox;
According to described response message, after determining the test performance of described API to be measured, according to the described mailbox ground of storage Location, transmits the performance test results of described API to be measured to described target mailbox.
Wherein, described API to be measured includes with the type of interaction of server: search type and amendment type.
By mobile device disclosed in the embodiment of the present invention, it is possible to realize the test to API, and test process is not required to Want tester that mobile device is operated manually, thus save manpower and time.
Those skilled in the art, after considering description and putting into practice invention disclosed, will readily occur to other reality of the present invention Execute scheme.The application is intended to any modification, purposes or the adaptations of the present invention, these modification, purposes or suitable The change of answering property is followed the general principle of the present invention and includes the undocumented common knowledge or used in the art of the present invention Use technological means.Description and embodiments is considered only as exemplary, and true scope and spirit of the invention are by following right Requirement is pointed out.
It should be appreciated that the invention is not limited in precision architecture described above and illustrated in the accompanying drawings, and And various modifications and changes can carried out without departing from the scope.The scope of the present invention is only limited by appended claim.

Claims (13)

1. an application programming interface API method of testing, it is characterised in that including:
Obtain the test parameter of each API and store;
If each API described exists API to be measured, determine described API to be measured and server according to the function of described API to be measured Type of interaction, and according to described API to be measured and the type of interaction of server and the test parameter of described API to be measured, generate institute State the test request of API to be measured;
By the test request of described API to be measured by described API to be measured transmission to described server, and produce at described server After response message, receive described response message by described API to be measured;
According to described response message, determine the test performance of described API to be measured.
API method of testing the most according to claim 1, it is characterised in that also include:
Whether detection each API described exists API to be measured.
API method of testing the most according to claim 2, it is characterised in that whether exist in each API described in described detection API to be measured, including:
If being respectively each API in advance to arrange corresponding test period, obtaining the time of target API the last time test, working as When the time difference of the time that front time and described the last time test is not less than test period, determine that described target API is to be measured API, wherein, described target API is the arbitrary API in each API described.
API method of testing the most according to claim 2, it is characterised in that whether exist in each API described in described detection API to be measured, including:
Whether detection each API described there is software reconfiguration;
If each API described exists the API that software reconfiguration occurs, determine that the API of described generation software reconfiguration is API to be measured.
5. according to the API method of testing described in any one of Claims 1-4, it is characterised in that also include:
Prestore the email address of target mailbox;
According to described response message, after determining the test performance of described API to be measured, according to the described email address of storage, incite somebody to action The performance test results transmission of described API to be measured is to described target mailbox.
API method of testing the most according to claim 1, it is characterised in that
Described API to be measured includes with the type of interaction of server: search type and amendment type.
7. an application programming interface API test device, it is characterised in that including:
Parameter memory module, for obtaining the test parameter of each API and storing;
Test request generation module, if there is API to be measured in each API described, determines according to the function of described API to be measured The type of interaction of described API to be measured and server, and according to described API to be measured and the type of interaction of server and described to be measured The test parameter of API, generates the test request of described API to be measured;
Response message receiver module, for transmitting the test request of described API to be measured to described service by described API to be measured Device, and after described server produces response message, receive described response message by described API to be measured;
Test performance determines module, for according to described response message, determines the test performance of described API to be measured.
API the most according to claim 7 tests device, it is characterised in that also include:
Detection module, is used for detecting in each API described whether there is API to be measured.
API the most according to claim 8 tests device, it is characterised in that described detection module includes:
First detector unit, if being respectively each API in advance to arrange corresponding test period, described first detector unit is used for obtaining Taking the time of target API the last time test, the time difference in current time with the time of described the last test is not less than During test period, determining that described target API is API to be measured, wherein, described target API is the arbitrary API in each API described.
API the most according to claim 8 tests device, it is characterised in that described detection module includes:
Second detector unit, is used for detecting whether each API described occurs software reconfiguration, occurs if existing in each API described The API of software reconfiguration, determines that the API of described generation software reconfiguration is API to be measured.
11. test device according to the API described in any one of claim 7 to 10, it is characterised in that also include:
Address memory module, for prestoring the email address of target mailbox;
Test result transport module, for according to described response message, after determining the test performance of described API to be measured, according to The described email address of storage, transmits the performance test results of described API to be measured to described target mailbox.
12. API according to claim 7 test device, it is characterised in that
Described API to be measured includes with the type of interaction of server: search type and amendment type.
13. 1 kinds of mobile devices, including:
Processor;
For storing the memorizer of processor executable;
Wherein, described processor is configured to:
Obtain the test parameter of each API and store;
If each API described exists API to be measured, determine described API to be measured and server according to the function of described API to be measured Type of interaction, and according to described API to be measured and the type of interaction of server and the test parameter of described API to be measured, generate institute State the test request of API to be measured;
By the test request of described API to be measured by described API to be measured transmission to described server, and produce at described server After response message, receive described response message by described API to be measured;
According to described response message, determine the test performance of described API to be measured.
CN201610479846.7A 2016-06-27 2016-06-27 A kind of application programming interface API method of testing, device and mobile device Pending CN106201864A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610479846.7A CN106201864A (en) 2016-06-27 2016-06-27 A kind of application programming interface API method of testing, device and mobile device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610479846.7A CN106201864A (en) 2016-06-27 2016-06-27 A kind of application programming interface API method of testing, device and mobile device

Publications (1)

Publication Number Publication Date
CN106201864A true CN106201864A (en) 2016-12-07

Family

ID=57461946

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610479846.7A Pending CN106201864A (en) 2016-06-27 2016-06-27 A kind of application programming interface API method of testing, device and mobile device

Country Status (1)

Country Link
CN (1) CN106201864A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107273277A (en) * 2017-05-11 2017-10-20 珠海金山网络游戏科技有限公司 A kind of depth captures the method and device of mobile phone application runnability data
CN109492391A (en) * 2018-11-05 2019-03-19 腾讯科技(深圳)有限公司 A kind of defence method of application program, device and readable medium
WO2019104869A1 (en) * 2017-11-29 2019-06-06 平安科技(深圳)有限公司 Storage process-based testing method, apparatus and device, and readable storage medium
WO2019223070A1 (en) * 2018-05-25 2019-11-28 平安科技(深圳)有限公司 Application testing method, apparatus, device, and readable storage medium
CN112506762A (en) * 2020-11-27 2021-03-16 北京百度网讯科技有限公司 Application program interface parameter screening method, device, equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070294673A1 (en) * 2006-06-16 2007-12-20 Microsoft Corporation Automated method and system for collecting and reporting API performance profiles
CN101227345A (en) * 2008-02-05 2008-07-23 中兴通讯股份有限公司 Automatic testing method based on application program interface
CN102968371A (en) * 2012-11-26 2013-03-13 武汉天喻信息产业股份有限公司 Method and device for testing JAVA API unit component

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070294673A1 (en) * 2006-06-16 2007-12-20 Microsoft Corporation Automated method and system for collecting and reporting API performance profiles
CN101227345A (en) * 2008-02-05 2008-07-23 中兴通讯股份有限公司 Automatic testing method based on application program interface
CN102968371A (en) * 2012-11-26 2013-03-13 武汉天喻信息产业股份有限公司 Method and device for testing JAVA API unit component

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107273277A (en) * 2017-05-11 2017-10-20 珠海金山网络游戏科技有限公司 A kind of depth captures the method and device of mobile phone application runnability data
WO2019104869A1 (en) * 2017-11-29 2019-06-06 平安科技(深圳)有限公司 Storage process-based testing method, apparatus and device, and readable storage medium
WO2019223070A1 (en) * 2018-05-25 2019-11-28 平安科技(深圳)有限公司 Application testing method, apparatus, device, and readable storage medium
CN109492391A (en) * 2018-11-05 2019-03-19 腾讯科技(深圳)有限公司 A kind of defence method of application program, device and readable medium
CN109492391B (en) * 2018-11-05 2023-02-28 腾讯科技(深圳)有限公司 Application program defense method and device and readable medium
CN112506762A (en) * 2020-11-27 2021-03-16 北京百度网讯科技有限公司 Application program interface parameter screening method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
US10725095B2 (en) Maintenance management systems and methods
CN106201864A (en) A kind of application programming interface API method of testing, device and mobile device
CN112650670B (en) Application testing method, device, system, electronic equipment and storage medium
CN104461894B (en) The operation record device and method of Android software
CN107515826A (en) Test case accurate recommendation method, device, system, equipment and storage medium
CN110413529A (en) Applied to the test method of electronic equipment, device, calculate equipment and medium
CN108446221A (en) System detection method, device, computer equipment and storage medium
CN105511977B (en) A kind of vehicle navigation system testing method and device
CN109408375B (en) Method and device for generating interface document
CN106126410B (en) Method and device for prompting code conflict
CN108959059A (en) A kind of test method and test platform
CN107729227A (en) Application testing range determining method, system, server and storage medium
CN107145438A (en) Code test method, code tester device and code tester system
WO2020096665A2 (en) System error detection
CN107211024A (en) Many granularity verification techniques
CN105138461A (en) Interface testing method and device for application program
CN110140179A (en) The long-range monitoring of Laboratory Instruments
CN106201865A (en) A kind of application programming interface API method of testing, device and terminal unit
CN109426611A (en) A kind of method for testing software and device
CN109542780A (en) Test method, test equipment and the storage medium of natural language processing application
CN105117345A (en) Interface testing method and device for application program
CN110119354A (en) Method for testing software, device and electronic equipment based on Test cases technology
JP2016170011A (en) Positioning device, method for positioning, positioning program, and positioning system
Strandberg Automated system-level software testing of industrial networked embedded systems
CN107577600A (en) A kind of method of testing of equipment, device and computer equipment

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20161207