CN111026672A - Test method, terminal equipment and mock server - Google Patents

Test method, terminal equipment and mock server Download PDF

Info

Publication number
CN111026672A
CN111026672A CN201911305579.1A CN201911305579A CN111026672A CN 111026672 A CN111026672 A CN 111026672A CN 201911305579 A CN201911305579 A CN 201911305579A CN 111026672 A CN111026672 A CN 111026672A
Authority
CN
China
Prior art keywords
request
test
testing
target data
client
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
CN201911305579.1A
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.)
Guangzhou Pinwei Software Co Ltd
Original Assignee
Guangzhou Pinwei Software 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 Guangzhou Pinwei Software Co Ltd filed Critical Guangzhou Pinwei Software Co Ltd
Priority to CN201911305579.1A priority Critical patent/CN111026672A/en
Publication of CN111026672A publication Critical patent/CN111026672A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3684Test management for test design, e.g. generating new test cases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/08Protocols specially adapted for terminal emulation, e.g. Telnet
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/544Remote

Abstract

The invention discloses a test method, which comprises the following steps: the testing end receives a testing request forwarded by the mock server, wherein the mock server sends the testing request to the testing end corresponding to the client after receiving the testing request of the client; acquiring target data corresponding to the test request; and returning the target data to the mock server for the mock server to forward the target data to the client. The invention also discloses the terminal equipment and the mock server. According to the method and the device, the target data corresponding to the test request is obtained by receiving the test request forwarded by the mock server, and the target data is returned to the mock server, so that local debugging can be performed, and the method and the device have the advantages of being high in flexibility and easy to manage.

Description

Test method, terminal equipment and mock server
Technical Field
The invention relates to the technical field of software testing, in particular to a testing method, terminal equipment and a mock server.
Background
Mock test refers to a test method by which a virtual object is created for some objects that are not easily constructed or easily obtained during the test. In the prior art, a request is sent to a remote mock server, and the remote mock server returns a preset response to a client, so that the problems of incapability of local debugging and poor flexibility exist.
The above is only for the purpose of assisting understanding of the technical aspects of the present invention, and does not represent an admission that the above is prior art.
Disclosure of Invention
The embodiment of the invention mainly aims to provide a testing method, and aims to solve the technical problems that in the prior art, by sending a request to a remote mock server, the remote mock server returns a preset response to a client, local debugging cannot be performed, and the flexibility is poor.
In order to solve the above problem, an embodiment of the present invention provides a testing method, including the following steps:
the testing end receives a testing request forwarded by the mock server, wherein the mock server sends the testing request to the testing end corresponding to the client after receiving the testing request of the client;
acquiring target data corresponding to the test request;
and returning the target data to the mock server for the mock server to forward the target data to the client.
Optionally, the step of obtaining the target data corresponding to the test request includes:
acquiring a request parameter corresponding to the test request;
and acquiring the target data according to the request parameters.
Optionally, the step of obtaining the target data corresponding to the request parameter includes:
acquiring a target generation condition matched with the request parameter in preset generation conditions;
and when the target generation condition is acquired, generating the target data according to the target generation condition.
Optionally, after the step of obtaining the target generation condition matched with the request parameter in the preset generation condition, the method further includes:
when the target generation condition is not acquired, forwarding the test request to a preset terminal;
and receiving target data returned by the preset terminal.
Optionally, the step of obtaining a target generation condition matched with the request parameter in preset generation conditions includes:
acquiring first characteristic information corresponding to the request parameter, wherein the first characteristic information comprises a hash value or a request path corresponding to the request parameter;
matching the first characteristic information with second characteristic information corresponding to the preset generation condition;
and taking a preset generation condition corresponding to the second characteristic information matched with the first characteristic information as a target generation condition.
In addition, in order to solve the above problem, an embodiment of the present invention further provides a testing method, which is applied to a mock server, where the testing method includes the following steps:
the Mock server receives a test request sent by a client;
the test request is forwarded to a test end corresponding to the client, wherein the test end obtains target data corresponding to the test request after receiving the test request forwarded by the mock server, and returns the target data to the mock server;
and after receiving the target data returned by the testing end, sending the target data to the client.
Optionally, the testing method further comprises:
receiving a registration request of the client;
and registering an instance of the testing end corresponding to the client according to the registration request so that the mock server establishes communication connection with the testing end corresponding to the client according to the instance.
Optionally, the mock server establishes a communication connection with the test terminal through an external component.
In addition, to solve the above problem, an embodiment of the present invention further provides a terminal device, where the terminal device includes a processor, a memory, and a test program stored in the memory and capable of running on the processor, and the test program implements the steps of the test method described above when executed by the processor.
The embodiment of the invention also provides a mock server, which comprises a processor, a memory and a test program which is stored on the memory and can run on the processor, wherein when the test program is executed by the processor, the content of the test method is realized.
According to the testing method provided by the embodiment of the invention, the target data corresponding to the testing request is obtained by receiving the testing request forwarded by the mock server, and the target data is returned to the mock server, so that local debugging can be performed, and the testing method has the advantages of high flexibility and easiness in management.
Drawings
Fig. 1 is a schematic terminal structure diagram of a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart of a first embodiment of the testing method of the present invention;
FIG. 3 is a detailed flowchart of step S200 in FIG. 2;
FIG. 4 is a schematic flow chart of a second embodiment of the testing method of the present invention;
FIG. 5 is a schematic flow chart of a testing method according to a third embodiment of the present invention;
FIG. 6 is a flowchart illustrating a testing method according to a fourth embodiment of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the detailed description and specific examples, while indicating the invention, are intended for purposes of illustration only and are not intended to limit the scope of the invention.
The main solution of the embodiment of the invention is as follows: the testing end receives a testing request forwarded by the mock server, wherein the mock server sends the testing request to the testing end corresponding to the client after receiving the testing request of the client; acquiring target data corresponding to the test request; and returning the target data to the mock server for the mock server to forward the target data to the client.
In the prior art, the remote mock server returns a preset response to the client by sending a request to the remote mock server, so that the technical problems of incapability of local debugging and poor flexibility exist.
The embodiment of the invention provides a solution, the target data corresponding to the test request is obtained by receiving the test request forwarded by the mock server, the target data is returned to the mock server, and the local debugging can be performed by configuring the test terminal in the client by user definition, so that the method has the advantages of high flexibility and easiness in management.
As shown in fig. 1, fig. 1 is a schematic diagram of a hardware architecture of a terminal device according to an embodiment of the present invention.
As shown in fig. 1, the terminal device may include: a processor 1001, such as a CPU, a communication bus 1002, and a memory 1003. The communication bus 1002 is used for realizing connection communication among the components. The memory 1003 may be a high-speed RAM memory or a non-volatile memory (e.g., a disk memory). The memory 1003 may alternatively be a storage device separate from the processor 1001.
Those skilled in the art will appreciate that the configuration of the terminal device shown in fig. 1 does not constitute a limitation of the terminal, and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
As shown in fig. 1, the memory 1003, which is a kind of computer storage medium, may include an operating system and a test program, and the processor 1001 may be configured to call the test program stored in the memory 1003 and perform the following steps:
the testing end receives a testing request forwarded by the mock server, wherein the mock server sends the testing request to the testing end corresponding to the client after receiving the testing request of the client;
acquiring target data corresponding to the test request;
and returning the target data to the mock server for the mock server to forward the target data to the client.
Further, the processor 1001 may be configured to call the test program stored in the memory 1003, and perform the following steps:
acquiring a request parameter corresponding to the test request;
and acquiring the target data according to the request parameters.
Further, the processor 1001 may be configured to call the test program stored in the memory 1003, and perform the following steps:
acquiring a target generation condition matched with the request parameter in preset generation conditions;
and when the target generation condition is acquired, generating the target data according to the target generation condition.
Further, the processor 1001 may be configured to call the test program stored in the memory 1003, and perform the following steps:
when the target generation condition is not acquired, forwarding the test request to a preset terminal;
and receiving target data returned by the preset terminal.
Further, the processor 1001 may be configured to call the test program stored in the memory 1003, and perform the following steps:
acquiring first characteristic information corresponding to the request parameter, wherein the first characteristic information comprises a hash value or a request path corresponding to the request parameter;
matching the first characteristic information with second characteristic information corresponding to the preset generation condition;
and taking a preset generation condition corresponding to the second characteristic information matched with the first characteristic information as a target generation condition.
Based on the structure of the terminal, a first embodiment of the present invention is provided, and referring to fig. 2, fig. 2 is a schematic flow chart of the first embodiment of the testing method of the present invention, where the testing method in this embodiment is executed at a testing end, and when the testing method is executed at the testing end, the testing method includes the following steps:
step S100, a test end receives a test request forwarded by a mock server, wherein the mock server sends the test request to a test end corresponding to a client after receiving the test request of the client;
the Mock test is a test method for creating a virtual object to simulate the behavior of a real object in a controllable manner for some objects which are not easy to construct or easily obtained in the test process. Other terminals or servers are simulated through mock testing, and testing efficiency can be effectively improved. In the prior art, simulation data usually exists in a remote server, only simple data simulation can be realized, meanwhile, the remote server cannot be debugged, the simulation data is fixed, and a conflict exists when a plurality of test ends share one set of simulation data.
In this embodiment, the execution body is a test port. The test end can be a local mock which is custom configured by a tester at the client, and can configure parameters and conditions to be tested so as to carry out local debugging. The client can be any computer or system needing to be tested. The client and the test end have corresponding relation.
Alternatively, the client may send a registration request to the mock server, where the registration request includes information of the testing end. After receiving a registration request of a client, the Mock server newly establishes a test end instance according to the information of the test end in the registration request, and further establishes communication connection between the Mock server and the test end, so that the relation between the client and the test end is known.
The Mock server can be deployed to a remote server through a download installation package provided by the Mock console to generate a test request, and is used for receiving the test request sent by the client and forwarding the test request to a test terminal corresponding to the client.
The test request may be a compression request packet, and the content to be tested may be assembled by HTTP (Hyper Text transfer Protocol) or any other available Protocol.
The test end can receive a test request of the client through the mock server, and it can be understood that the client is not directly connected with the test end.
Step S200, acquiring target data corresponding to the test request;
after receiving the test request, the test end analyzes the received test request to obtain the content to be tested contained in the test request, and obtains the corresponding target data according to the content to be tested.
Optionally, referring to fig. 3, fig. 3 is a flowchart of a detailed step of step S200, where acquiring target data corresponding to the test request includes:
step S210, obtaining request parameters corresponding to the test request;
step S220, the target data is obtained according to the request parameters.
The test end analyzes the test request to obtain the content to be tested, namely the request parameter. The request parameters include content to be tested, including one or more of character strings, test request addresses, class names, method names, functions and attributes.
And after receiving the request parameters of the test request, acquiring target data according to the request parameters. The test end can match the request parameters with the test codes of the test end, and when the matching is successful, preset data corresponding to the test codes are used as target data; and when the matching is unsuccessful, sending the test request to a real scene, namely a terminal for actually running the test request. And after receiving the test request, the terminal which actually operates returns the real data to the test terminal. And the test end sets the real data as target data after receiving the real data returned by the actual terminal.
The target data includes one of simulated data and real data. The simulation data may be a preset result generated by calling a corresponding class, method, function, or parameter in the test end according to the request parameter. The real data can obtain a corresponding real scene according to the test request, and a real result is generated according to the request parameters in the test request in the real scene.
Optionally, the test end may integrate a Mockito framework, and local debugging and matching may be performed through the Mockito framework, which is high in flexibility and easy to manage. The testing end can match the request parameters in the testing request through a Mockito.
And step S300, returning the target data to the mock server so that the mock server can forward the target data to the client.
And after the target data are obtained, returning the target data to the mock server. And after receiving the target data returned by the testing end, the Mock server forwards the target data to the client for the client to test.
In this embodiment, the test request forwarded by the mock server is received, the target data corresponding to the test request is obtained, the target data is returned to the mock server, and the test terminal is configured by the client in a user-defined manner, so that local debugging can be performed.
Referring to fig. 4, fig. 4 is a flowchart illustrating a second embodiment of the testing method of the present invention, wherein step S200 in the first embodiment includes:
step S221, obtaining a target generation condition matched with the request parameter in preset generation conditions;
the preset generation condition may be one or more of a class, a method, a function, and a parameter. Alternatively, the predetermined generating condition may be a condition corresponding to a when statement in the Mockito framework.
And matching the request parameters of the test request with preset generation conditions in a fuzzy matching mode. The fuzzy matching can be realized in a partial matching mode, without limitation on positions and the number of corresponding keywords, and the matching is considered to be successful as long as the keywords corresponding to the request parameters are obtained.
And acquiring a target generation condition matched with the request parameter according to the request parameter and a preset generation condition. The target generating condition is included in the preset generating condition and may include one or more of a class, a method, a function, and a parameter.
Optionally, the obtaining of the target generation condition matched with the request parameter in the preset generation conditions includes:
acquiring first characteristic information corresponding to the request parameter, wherein the first characteristic information comprises a hash value or a request path corresponding to the request parameter;
matching the first characteristic information with second characteristic information corresponding to the preset generation condition;
and taking a preset generation condition corresponding to the second characteristic information matched with the first characteristic information as a target generation condition.
The first feature information may be a keyword or key information in the request parameter, and may include at least one of a hash value corresponding to the request parameter and a request path. The hash value may be flag information or fingerprint information in the request parameter, and may be summary information compressed from data or information in the request parameter. The request path may be a test request path.
The second characteristic information may be one or more of a class, a method, a function, and a parameter, and may include a hash value and a request path.
And carrying out fuzzy matching on the first characteristic information corresponding to the request parameter and the second characteristic information corresponding to the preset generating condition, and taking the preset generating condition corresponding to the second characteristic information matched with the first characteristic information as a target generating condition.
Step S222, when the target generation condition is acquired, generating the target data according to the target generation condition.
And when the target generation condition is acquired, calling any one or more of corresponding classes, methods, functions or parameters according to the target generation condition to generate target data.
Alternatively, the target data may be generated by the then statement of the Mockito. And when the Mockito obtains the request parameters and the preset generation conditions in the where can be matched, obtaining target generation conditions corresponding to the preset generation conditions, and generating the target data in the where by calling the target generation conditions in the where.
In this embodiment, the request parameter is matched with the preset generation condition to obtain the target generation condition corresponding to the request parameter, and the target data is generated according to the target generation condition, so that the method has the advantages of high efficiency, flexibility, simplicity and convenience.
Referring to fig. 5, fig. 5 is a schematic flow chart of a third embodiment of the testing method of the present invention, based on the first embodiment and the second embodiment, which are parallel embodiments, the step S200 in the first implementation further includes:
step S223, when the target generation condition is not obtained, forwarding the test request to a preset terminal;
step S224, receiving the target data returned by the preset terminal.
And after the request parameters are matched with the preset generation conditions and the target generation conditions in the preset generation conditions are not obtained, the test terminal forwards the test request to the preset terminal. The preset terminal may be an actually running terminal corresponding to the test request, such as a server or a system, or a terminal corresponding to a real scene of the test request.
After receiving the test request, the preset terminal analyzes the request parameters corresponding to the test request, and tests according to the request parameters to obtain a real test result, namely real data of the target data. And after the target data are obtained, returning the target data to the testing end.
And the test terminal receives the target data returned by the preset terminal and forwards the target data to the mock server.
In this embodiment, the target data is generated according to the real scene, and when the test end cannot obtain the simulation data corresponding to the request parameter, compensation is performed to continue the test so as to satisfy the complex test request, which has the advantages of stability and reliability.
Referring to fig. 6, fig. 6 is a schematic flowchart of a fourth embodiment of the testing method according to the present invention, in this embodiment, the testing method operates in a Mock server, and when the testing method operates in the Mock server, the testing method includes the following steps:
step S400, the Mock server receives a test request sent by a client;
step S500, the test request is forwarded to a test end corresponding to the client, wherein the test end obtains target data corresponding to the test request after receiving the test request forwarded by the mock server, and returns the target data to the mock server;
and after receiving the test request sent by the client, the Mock server forwards the test request to the test terminal corresponding to the client. It should be noted that, after configuring a test end by a user, the client registers an instance of the test end with the mock server, so that the mock server obtains a corresponding relationship between the client and the test end through the instance.
Optionally, the testing method further comprises:
receiving a registration request of the client;
and registering an instance of the testing end corresponding to the client according to the registration request so that the mock server establishes communication connection with the testing end corresponding to the client according to the instance.
After receiving the registration request of the client, the Mock server registers the instance of the test end corresponding to the client according to the registration request, and establishes communication connection with the test end corresponding to the client through the instance. The registration request may include a path of the testing end and a user name of the testing end; examples include the username of the test end and authorization information. The authorization information may include one or more of password information, path verification information, and verification information.
Alternatively, one instance of the test site may be registered by the registerOspMock method or the registerHttpMock method.
The client can input the user name and the authorization information of the instance of the testing end on the mock server and log in the mock server, so that the mock server establishes communication connection with the testing end.
Optionally, the mock server establishes a communication connection with the test terminal through an external component.
The Mock server can be connected with the external component in parallel through a preset port. The preset port can be 3081 port, and the external component can be a zookeeper server. And the Mock server can establish communication connection with the test terminal through the external component.
Optionally, the client sends the instance of the test end to a mock server preset port by a register OspMock method or a register HttpMock method of a MockerServiceClient class, and the mock server registers the instance of the test end in the external component to realize networking.
Step S600, after receiving the target data returned by the testing end, sending the target data to the client.
And after receiving the target data returned by the testing end, sending the target data to the client.
In this embodiment, the mock server forwards the test request sent by the client to the test end, and sends the target data to the client after receiving the target data returned by the test end, so that the simulation test can be locally debugged, and the method has the advantages of high flexibility and easiness in management.
In addition, an embodiment of the present invention further provides a terminal device, where the terminal device includes a processor, a memory, and a test program that is stored on the memory and can be run on the processor, and when the test program is executed by the processor, the contents of the first to third embodiments of the test method described above are implemented.
The embodiment of the present invention further provides a mock server, where the mock server includes a processor, a memory, and a test program stored on the memory and capable of running on the processor, and when the test program is executed by the processor, the content of the fourth embodiment of the test method described above is implemented.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a computer-readable storage medium (such as ROM/RAM, magnetic disk, optical disk) as described above, and includes several instructions for enabling a terminal device (such as a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (10)

1. A method of testing, comprising the steps of:
the testing end receives a testing request forwarded by the mock server, wherein the mock server sends the testing request to the testing end corresponding to the client after receiving the testing request of the client;
acquiring target data corresponding to the test request;
and returning the target data to the mock server for the mock server to forward the target data to the client.
2. The testing method of claim 1, wherein the step of obtaining target data corresponding to the test request comprises:
acquiring a request parameter corresponding to the test request;
and acquiring the target data according to the request parameters.
3. The testing method of claim 2, wherein the step of obtaining the target data corresponding to the request parameter comprises:
acquiring a target generation condition matched with the request parameter in preset generation conditions;
and when the target generation condition is acquired, generating the target data according to the target generation condition.
4. The testing method according to claim 3, wherein after the step of obtaining the target generating condition matching the request parameter in the preset generating condition, the method further comprises:
when the target generation condition is not acquired, forwarding the test request to a preset terminal;
and receiving target data returned by the preset terminal.
5. The testing method of claim 3, wherein the step of obtaining a target generation condition matching the request parameter in the preset generation conditions comprises:
acquiring first characteristic information corresponding to the request parameter, wherein the first characteristic information comprises a hash value or a request path corresponding to the request parameter;
matching the first characteristic information with second characteristic information corresponding to the preset generation condition;
and taking a preset generation condition corresponding to the second characteristic information matched with the first characteristic information as a target generation condition.
6. A method of testing, comprising the steps of:
the Mock server receives a test request sent by a client;
the test request is forwarded to a test end corresponding to the client, wherein the test end obtains target data corresponding to the test request after receiving the test request forwarded by the mock server, and returns the target data to the mock server;
and after receiving the target data returned by the testing end, sending the target data to the client.
7. The testing method of claim 6, further comprising:
receiving a registration request of the client;
and registering an instance of the testing end corresponding to the client according to the registration request so that the mock server establishes communication connection with the testing end corresponding to the client according to the instance.
8. The testing method of claim 6, wherein the mock server establishes a communication connection with the testing terminal through an external component.
9. A terminal device, characterized in that it comprises a processor, a memory and a test program stored on the memory and executable on the processor, which test program, when executed by the processor, implements the steps of the test method according to any one of claims 1 to 5.
10. A mock server, characterized in that it comprises a processor, a memory and a test program stored on said memory and executable on said processor, said test program, when executed by said processor, implementing the steps of the test method according to any one of claims 6 to 8.
CN201911305579.1A 2019-12-16 2019-12-16 Test method, terminal equipment and mock server Pending CN111026672A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911305579.1A CN111026672A (en) 2019-12-16 2019-12-16 Test method, terminal equipment and mock server

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911305579.1A CN111026672A (en) 2019-12-16 2019-12-16 Test method, terminal equipment and mock server

Publications (1)

Publication Number Publication Date
CN111026672A true CN111026672A (en) 2020-04-17

Family

ID=70209438

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911305579.1A Pending CN111026672A (en) 2019-12-16 2019-12-16 Test method, terminal equipment and mock server

Country Status (1)

Country Link
CN (1) CN111026672A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111831566A (en) * 2020-07-17 2020-10-27 北京字节跳动网络技术有限公司 Test method, test device, electronic equipment and computer readable storage medium
CN112052178A (en) * 2020-09-18 2020-12-08 广州宸祺出行科技有限公司 Mock platform-based data maintenance method and mock platform-based data maintenance system
CN112559344A (en) * 2020-12-10 2021-03-26 平安养老保险股份有限公司 Remote mock testing method and system
CN112732499A (en) * 2020-12-30 2021-04-30 广州品唯软件有限公司 Test method and device based on micro-service architecture and computer system
CN113592305A (en) * 2021-07-29 2021-11-02 北京百度网讯科技有限公司 Test method, test device, electronic device, and storage medium
CN114666301A (en) * 2020-12-22 2022-06-24 深圳Tcl新技术有限公司 APP testing method and system based on mock server

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107368405A (en) * 2016-05-11 2017-11-21 腾讯科技(北京)有限公司 Test system, method of testing, mock platforms, blocker and client
CN107547312A (en) * 2017-09-21 2018-01-05 广州四三九九信息科技有限公司 Applied program testing method and system
CN108268372A (en) * 2017-07-24 2018-07-10 深圳壹账通智能科技有限公司 Mock test processing methods, device, storage medium and computer equipment
CN108345535A (en) * 2017-12-26 2018-07-31 阿里巴巴集团控股有限公司 Mock test methods, device and equipment
CN109344075A (en) * 2018-10-19 2019-02-15 网宿科技股份有限公司 Configuration method, test method, configuration server and service node device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107368405A (en) * 2016-05-11 2017-11-21 腾讯科技(北京)有限公司 Test system, method of testing, mock platforms, blocker and client
CN108268372A (en) * 2017-07-24 2018-07-10 深圳壹账通智能科技有限公司 Mock test processing methods, device, storage medium and computer equipment
CN107547312A (en) * 2017-09-21 2018-01-05 广州四三九九信息科技有限公司 Applied program testing method and system
CN108345535A (en) * 2017-12-26 2018-07-31 阿里巴巴集团控股有限公司 Mock test methods, device and equipment
CN109344075A (en) * 2018-10-19 2019-02-15 网宿科技股份有限公司 Configuration method, test method, configuration server and service node device

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111831566A (en) * 2020-07-17 2020-10-27 北京字节跳动网络技术有限公司 Test method, test device, electronic equipment and computer readable storage medium
CN112052178A (en) * 2020-09-18 2020-12-08 广州宸祺出行科技有限公司 Mock platform-based data maintenance method and mock platform-based data maintenance system
CN112052178B (en) * 2020-09-18 2024-02-20 广州宸祺出行科技有限公司 Method and system for maintaining data based on mock platform
CN112559344A (en) * 2020-12-10 2021-03-26 平安养老保险股份有限公司 Remote mock testing method and system
CN114666301A (en) * 2020-12-22 2022-06-24 深圳Tcl新技术有限公司 APP testing method and system based on mock server
CN112732499A (en) * 2020-12-30 2021-04-30 广州品唯软件有限公司 Test method and device based on micro-service architecture and computer system
CN113592305A (en) * 2021-07-29 2021-11-02 北京百度网讯科技有限公司 Test method, test device, electronic device, and storage medium

Similar Documents

Publication Publication Date Title
CN111026672A (en) Test method, terminal equipment and mock server
CN110750442B (en) Test case generation method, device, equipment and storage medium
CN107133180B (en) Dynamic page testing method, testing device and storage medium
CN105389263B (en) Application software authority monitoring method, system and equipment
CN110430205B (en) Single sign-on method, device, equipment and computer readable storage medium
CN111045756B (en) Method, apparatus, computing device and medium for generating interface service
CN112306881B (en) Analog data generation method, device, equipment and storage medium
CN113676336A (en) Microservice access proxy method, apparatus and storage medium
CN109558320B (en) System testing method, device, system, equipment and computer readable storage medium
CN112988608B (en) Data testing method and device, computer equipment and storage medium
CN110149363A (en) A kind of information push method, device and storage medium
CN113806037A (en) Service calling method and device, storage medium and electronic equipment
CN111367821B (en) Software testing method and system
CN108427639B (en) Automated testing method, application server and computer readable storage medium
CN109683997A (en) Pass through the method for sandbox access application interface, sandbox and sandbox equipment
CN110990008A (en) Method, device, storage medium and electronic equipment for updating page
CN111061637B (en) Interface testing method, interface testing device and storage medium
CN104917633A (en) Method and device simulating FOTA upgrade
CN111880791A (en) Scene instance development method and device
CN107247661B (en) Method and system for supporting automatic verification of installation package of application
CN112636981B (en) Block chain host, and proxy method, device and storage medium thereof
CN111078571B (en) Test method for analog response, terminal equipment and computer readable storage medium
CN106789225A (en) A kind of method and device of interface operation port mapping configuration
KR20070057633A (en) System for testing of telematics service and its method
CN106131151A (en) For testing the method and device of supplying system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination