CN114546863A - Automatic pressure measurement script generation method and device - Google Patents

Automatic pressure measurement script generation method and device Download PDF

Info

Publication number
CN114546863A
CN114546863A CN202210173426.1A CN202210173426A CN114546863A CN 114546863 A CN114546863 A CN 114546863A CN 202210173426 A CN202210173426 A CN 202210173426A CN 114546863 A CN114546863 A CN 114546863A
Authority
CN
China
Prior art keywords
request
pressure measurement
script
sequence
access requests
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
CN202210173426.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.)
Industrial and Commercial Bank of China Ltd ICBC
Original Assignee
Industrial and Commercial Bank of China Ltd ICBC
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 Industrial and Commercial Bank of China Ltd ICBC filed Critical Industrial and Commercial Bank of China Ltd ICBC
Priority to CN202210173426.1A priority Critical patent/CN114546863A/en
Publication of CN114546863A publication Critical patent/CN114546863A/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

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 invention provides an automatic pressure measurement script generation method and device, relates to the technical field of data processing, and can be used in the financial field or other technical fields. The method comprises the following steps: copying the flow of a target application program to obtain an access request and a request feedback message of the target application program; sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages; and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script. The device performs the above method. The automatic pressure measurement script generation method and device provided by the embodiment of the invention can be used for automatically generating various types of pressure measurement scripts and improving the pressure measurement script generation efficiency.

Description

Automatic pressure measurement script generation method and device
Technical Field
The invention relates to the technical field of data processing, in particular to an automatic pressure measurement script generation method and device.
Background
The pressure test is widely applied to a plurality of services, and the pressure test can be conveniently carried out by compiling a pressure test script, namely the pressure test script.
The existing pressure measurement scripts are usually written manually according to business requirements, and the mode is more suitable for a scene with simple pressure measurement logics. However, for some complicated processes, for example, a pressure measurement script that requires a feedback result of a previous request for initiating a next request may be complicated to write manually, and if the feedback result of the previous request cannot be obtained explicitly, this type of pressure measurement script cannot be written manually.
Disclosure of Invention
In view of the problems in the prior art, embodiments of the present invention provide an automatic pressure measurement script generating method and apparatus, which can at least partially solve the problems in the prior art.
In one aspect, the present invention provides an automated pressure-measuring script generating method, including:
copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages;
and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
Wherein, determining the type of the pressure measuring tool; correspondingly, the converting the pressure measurement request sequence into a pressure measurement script includes:
and selecting a conversion model corresponding to the type of the pressure measurement tool, and converting the pressure measurement request sequence into a pressure measurement script through the conversion model.
Wherein the converting the sequence of pressure measurement requests into a pressure measurement script via the conversion model comprises:
splitting the pressure measurement request sequence to obtain each independent request;
converting each independent request into a corresponding pressure measurement script through the conversion model;
and connecting the pressure measurement scripts corresponding to the independent requests to obtain the pressure measurement scripts corresponding to the pressure measurement request sequences.
The method for sequencing the access requests according to the sequence of the occurrence time of the access requests and displaying the sequenced access requests and request feedback messages comprises the following steps:
writing the sequenced access requests and request feedback messages into a data form; and reading the data in the data form, and displaying the sequenced access request and request feedback message.
Wherein, the obtaining of the pressure measurement request sequence finished with arrangement in response to the request arrangement processing action of the user for the sequenced access request and request feedback message comprises:
and responding to the request arrangement processing action executed in the data form by the user to obtain a pressure measurement request sequence which is completely arranged.
After the step of converting the pressure measurement request sequence into a pressure measurement script, the method for generating the automatic pressure measurement script further comprises:
and checking the pressure measurement script, and if the checking result is not passed, generating a prompt message for prompting the user to perform request arrangement processing on the sequenced access request and request feedback message again.
The automatic pressure measurement script generation method further comprises the following steps:
and if the verification result passes, sending the pressure measurement script passing the verification to a pressure measurement script calling party.
In one aspect, the present invention provides an automatic pressure-measuring script generating device, including:
the system comprises a copying unit, a processing unit and a feedback unit, wherein the copying unit is used for copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
the sequencing unit is used for sequencing the access requests according to the sequence of the occurrence time of the access requests and displaying the sequenced access requests and request feedback messages;
and the conversion unit is used for responding to the request arrangement processing action of the user aiming at the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
In another aspect, an embodiment of the present invention provides an electronic device, including: a processor, a memory, and a bus, wherein,
the processor and the memory are communicated with each other through the bus;
the memory stores program instructions executable by the processor, the processor invoking the program instructions to perform a method comprising:
copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages;
and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
An embodiment of the present invention provides a non-transitory computer-readable storage medium, including:
the non-transitory computer readable storage medium stores computer instructions that cause the computer to perform a method comprising:
copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages;
and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
According to the method and the device for generating the automatic pressure measurement script, provided by the embodiment of the invention, the flow of a target application program is copied to obtain an access request and a request feedback message of the target application program; sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages; the method comprises the steps of responding to a request arrangement processing action of a user for ordered access requests and request feedback messages to obtain an arranged pressure measurement request sequence, converting the pressure measurement request sequence into a pressure measurement script, solving the problem of complex pressure measurement logic through the request arrangement processing, further converting the arranged pressure measurement request sequence into the pressure measurement script, realizing automatic generation of various types of pressure measurement scripts, and improving the generation efficiency of the pressure measurement script.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts. In the drawings:
fig. 1 is a schematic flow chart of an automated pressure measurement script generation method according to an embodiment of the present invention.
Fig. 2 is a flowchart illustrating an automated pressure measurement script generation method according to another embodiment of the present invention.
Fig. 3 is a schematic view of an internal structure of the mounting device according to the embodiment of the present invention.
Fig. 4 is a schematic diagram of an internal structure of a traffic replication device according to an embodiment of the present invention.
Fig. 5 is a schematic diagram of an internal structure of a request orchestration device according to an embodiment of the present invention.
Fig. 6 is a schematic view of an internal structure of a pressure measurement tool detection device according to an embodiment of the present invention.
Fig. 7 is a schematic view of an internal structure of a pressure-measuring script generating device according to an embodiment of the present invention.
Fig. 8 is a schematic structural diagram of an automated pressure-measuring script generating apparatus according to an embodiment of the present invention.
Fig. 9 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the embodiments of the present invention are further described in detail below with reference to the accompanying drawings. The exemplary embodiments and descriptions of the present invention are provided to explain the present invention, but not to limit the present invention. It should be noted that the embodiments and features of the embodiments in the present application may be arbitrarily combined with each other without conflict.
Fig. 1 is a schematic flow diagram of an automatic pressure measurement script generation method according to an embodiment of the present invention, and as shown in fig. 1, the automatic pressure measurement script generation method according to the embodiment of the present invention includes:
step S1: and copying the flow of the target application program to obtain an access request and a request feedback message of the target application program.
Step S2: and sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages.
Step S3: and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
In the step S1, the device copies the traffic of the target application to obtain the access request and the request feedback message of the target application. The apparatus may be a computer device for executing the method, and may include a client, specifically, a PC, a mobile phone, or a tablet computer. The target application may be an application that the user determines needs for traffic replication. Each access request has a request feedback message corresponding to the access request, and marks of the access request and the request feedback message can be generated so as to determine the corresponding relation between the access request and the request feedback message.
For example, the access request a, the access request B, and the access request C, and the request feedback messages corresponding to them are a request feedback message a, a request feedback message B, and a request feedback message C, respectively.
Copying the traffic of the target application program, comprising:
and mounting a flow copying module into the target application program, and copying the flow of the target application program in real time. The traffic replication module mounted in the target application program keeps real-time communication with the target application program, so that the traffic of the target application program is replicated in real time.
In the step S2, the apparatus sorts the access requests according to the sequence of the occurrence time of the access requests, and displays the sorted access requests and request feedback messages. Referring to the above example, the result of the ordering of the access requests according to the sequence of the occurrence time of the access requests is a-B-C; the embodiment of the present invention does not specifically limit the ordering of the request feedback messages. For example, the ordering may be performed according to the actual feedback time, and a-B-C or a-C-B, i.e. the request feedback message C corresponding to the access request C may be sent before the request feedback message B corresponding to the access request B.
And the sequenced access requests and request feedback messages are displayed, so that the subsequent request arrangement processing operation of the user is facilitated.
In the above step S3, the device obtains a pressure measurement request sequence that is completely organized in response to the request organizing processing action of the user for the sequenced access request and request feedback message, and converts the pressure measurement request sequence into a pressure measurement script. The request orchestration processing action may include: request sequence adjustment, access request content and request feedback message content adjustment, service branch logic adjustment and the like. The sequence of pressure measurement requests may be converted to a pressure measurement script by a conversion model.
In order to facilitate pressure measurement, a pressure measurement tool type of a pressure measurement tool used for pressure measurement may be determined, and correspondingly, converting the pressure measurement request sequence into a pressure measurement script includes:
and selecting a conversion model corresponding to the type of the pressure measurement tool, and converting the pressure measurement request sequence into a pressure measurement script through the conversion model. If the pressure measurement tool type is loadrunner, then the loadrunner conversion model is selected to convert the pressure measurement request sequence to a loadrunner pressure measurement script.
Among them, loadrunner is a load testing tool that predicts system behavior and performance. Problems are confirmed and searched by simulating the way that tens of millions of users implement concurrent load and real-time performance monitoring, and the loadrunner can test the whole enterprise architecture. The enterprise can furthest shorten the testing time, optimize the performance and accelerate the release period of the application system by using the loadrunner. The loadrunner can be applied to automatic load testing of various system architectures, and can predict system behaviors and evaluate system performance.
If the pressure measurement tool type is jmeter, a jmeter conversion model is selected to convert the pressure measurement request sequence into a jmeter pressure measurement script.
Apache meter is a pressure testing tool developed by Apache organization based on Java and used for pressure testing software.
Among them, the jmeter was originally designed for Web application testing, but later extended to other areas of testing, available for testing static and dynamic resources, such as static files, Java servlets, CGI scripts, Java objects, databases, FTP servers, and so on. The meter can simulate huge loads on servers, networks or objects, test their strengths and analyze the overall performance under different stress categories. Additionally, the meter can perform a function/regression test on the application to verify whether the program returned the desired result by creating a script with an assertion. For maximum flexibility, the meter allows assertions to be created using regular expressions.
The loadrunner conversion model can be selected as VUGEN; the jmeter conversion model is inherited by the jmeter tool itself, is a small function of the jmeter tool, and has no independent name.
The difference between these two transformation models is: scripts generated with VUGen can only run on loadrunner. The pressure script generated by the conversion model built in the jmeter can only run on the jmeter.
Converting the pressure measurement request sequence into a pressure measurement script through the conversion model, including:
splitting the pressure measurement request sequence to obtain each independent request; if the sequence of the pressure measurement request is B-C-A, the independent requests obtained after the splitting process are B, C and A.
Converting each independent request into a corresponding pressure measurement script through the conversion model; the pressure measurement scripts respectively corresponding to the independent requests are JB, JC and JA.
And connecting the pressure measurement scripts corresponding to the independent requests to obtain the pressure measurement scripts corresponding to the pressure measurement request sequences. And the pressure measurement script corresponding to the pressure measurement request sequence is JB-JC-JA.
According to the automatic pressure measurement script generation method provided by the embodiment of the invention, the flow of a target application program is copied to obtain an access request and a request feedback message of the target application program; sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages; the method comprises the steps of responding to a request arrangement processing action of a user for ordered access requests and request feedback messages to obtain an arranged pressure measurement request sequence, converting the pressure measurement request sequence into a pressure measurement script, solving the problem of complex pressure measurement logic through the request arrangement processing, further converting the arranged pressure measurement request sequence into the pressure measurement script, realizing automatic generation of various types of pressure measurement scripts, and improving the generation efficiency of the pressure measurement script.
Further, determining the type of a pressure measuring tool; correspondingly, the converting the pressure measurement request sequence into a pressure measurement script includes:
and selecting a conversion model corresponding to the type of the pressure measurement tool, and converting the pressure measurement request sequence into a pressure measurement script through the conversion model. Reference is made to the above description and no further description is given.
The automatic pressure measurement script generation method provided by the embodiment of the invention has good compatibility for different pressure measurement tool types, and improves the universality of the method.
Further, the converting, by the conversion model, the pressure measurement request sequence into a pressure measurement script includes:
splitting the pressure measurement request sequence to obtain each independent request; reference is made to the above description and no further description is made.
Converting each independent request into a corresponding pressure measurement script through the conversion model; reference is made to the above description and no further description is made.
And connecting the pressure measurement scripts corresponding to the independent requests to obtain the pressure measurement scripts corresponding to the pressure measurement request sequences. Reference is made to the above description and no further description is made.
The automatic pressure measurement script generation method provided by the embodiment of the invention can effectively realize the acquisition of the pressure measurement script corresponding to the pressure measurement request sequence.
Further, the sorting the access requests according to the sequence of the occurrence time of the access requests and displaying the sorted access requests and the request feedback messages includes:
writing the sequenced access requests and request feedback messages into a data form; and reading the data in the data form, and displaying the ordered access request and request feedback message. The sorted access requests and request feedback messages may be displayed at the user terminal by sending a data form to the user terminal.
Or the data in the data form can be read locally, and the ordered access request and the request feedback message can be displayed locally.
The automatic pressure test script generation method provided by the embodiment of the invention is convenient to read and write through the data form, and displays the sequenced access request and request feedback message.
Further, the obtaining a pressure measurement request sequence which is completely arranged in response to the request arranging processing action of the user for the sequenced access request and request feedback message includes:
and responding to the request arrangement processing action executed in the data form by the user to obtain a pressure measurement request sequence which is completely arranged. The user arranges the processing action through the request executed in the data form, so that the user operation is more convenient.
The automatic pressure test script generation method provided by the embodiment of the invention is more convenient for a user to execute the request arranging and processing action.
Further, after the step of converting the pressure measurement request sequence into a pressure measurement script, the method for generating an automatic pressure measurement script further includes:
and checking the pressure measurement script, and if the checking result is not passed, generating a prompt message for prompting the user to perform request arrangement processing on the sequenced access request and request feedback message again. The result output by the pressure measurement script can be compared with a normal result obtained in advance, and if the comparison result is consistent, the verification result is passed; if the comparison result is not consistent, the verification result is not passed.
And the user carries out request arrangement processing on the sequenced access requests and request feedback messages again, then continues to execute the request arrangement processing action of responding to the sequenced access requests and request feedback messages of the user to obtain the pressure measurement request sequence which is arranged, and converts the pressure measurement request sequence into a pressure measurement script, and the subsequent steps are carried out.
According to the automatic pressure measurement script generation method provided by the embodiment of the invention, the pressure measurement script is verified, so that the effectiveness of the generated pressure measurement script is ensured, and a user can be timely prompted to adopt a coping method when the verification result fails.
Further, the automatic pressure test script generation method further includes:
and if the verification result passes, sending the pressure measurement script passing the verification to a pressure measurement script calling party. The pressure measurement script calling party can obtain the data to be measured and processed, and the pressure measurement script is called to process the data to be measured and processed to obtain a pressure measurement result.
The automatic pressure measurement script generation method provided by the embodiment of the invention is convenient for a pressure measurement script caller to use an effective pressure measurement script.
The method of the embodiment of the present invention can be implemented in a modular manner, as shown in fig. 2, including: the automatic pressure measurement script generation tool comprises an automatic pressure measurement script generation tool starting device 1, a mounting device 2, a flow copying device 3, a request arranging device 4, a pressure measurement tool detection device 5, a pressure measurement script generation device 6, a pressure measurement script checking device 7 and a result returning device 8; wherein:
automatic change and press survey script generation instrument starting drive 1: the automatic pressure measurement script generation tool is used for starting and running.
Mounting device 2: the system is used for mounting the flow replication module into the target application program and keeping real-time communication with the target application program.
The traffic replication device 3: the method is used for copying all the flow of the target application program, automatically acquiring input data (corresponding to the access request) and output data (corresponding to the request feedback message) of all the requests of the application, and sequencing according to the occurrence time of each request.
The request orchestration device 4: and arranging input data and output data returned by the flow multiplexing device 3 according to the actual pressure measurement service logic, wherein the arrangement comprises request sequence adjustment, input and output parameter adjustment, service branch logic adjustment and the like.
Pressure measurement tool detection device 5: and selecting a corresponding conversion model for automatically generating the pressure measurement script according to the type of the pressure measurement tool. If the pressure measurement tool is loadrunner, selecting a loadrunner conversion model; if the pressure measurement tool is a meter, a meter conversion model is selected.
Pressure measurement script generation device 6: and converting the arranged pressure measurement request sequence into a pressure measurement script according to the conversion model obtained by the pressure measurement tool detection device 5.
Pressure measurement script checking device 7: for verifying whether the pressure measurement script generated by the pressure measurement script generating means 6 is valid.
Result returning means 8: and returning the automatically generated pressure measurement script to the calling party.
As shown in fig. 3, the mounting device 2 includes a mounting unit 21 and a communication unit 22; wherein:
mounting unit 21: the method is used for mounting the flow replication module into the target application program.
The communication unit 22: the method is used for realizing communication between the traffic replication module and the target application program.
As shown in fig. 4, the traffic replication device 3 includes a request replication unit 31, a request sorting unit 32, and a request sequence transmitting unit 33; wherein:
the request copy unit 31: all requested input data and output data passing through the target application are acquired.
The request ordering unit 32: all requests to be replicated by the request replicating unit 31 are ordered according to the time at which the respective requests occur.
Request sequence transmitting unit 33: for sending the sorted list of requests to the request orchestration device 4.
As shown in fig. 5, the request arranging apparatus 4 includes a request sequence editing unit 41 and a request body editing unit 42; wherein:
request sequence editing unit 41: the request list sent by the request sequence sending unit 33 is received, and the ordered access requests and request feedback messages are arranged according to the actual pressure measurement service logic, including request sequence adjustment, addition or deletion of specific requests, and the like.
Requester editing unit 42: specific requests can be internally edited, such as adjusting the access parameters, the request access url, the request type and the like.
As shown in fig. 6, the pressure measurement tool detection device 5 includes a pressure measurement tool detection unit 51 and a pressure measurement script model selection unit 52; wherein:
pressure measurement tool detection unit 51: for detecting a user-predefined pressure measurement tool type.
Pressure measurement script model selection unit 52: and is configured to select a corresponding pressure measurement script conversion model according to the type of the pressure measurement tool detected by the pressure measurement tool detection unit 51.
As shown in fig. 7, the pressure measurement script generating device 6 includes a request splitting unit 61, a request and script converting unit 62, and a script connecting unit 63; wherein:
the request splitting unit 61: the request sequence obtained by the arrangement of the request arranging device 4 is split into independent request bodies.
Request and script conversion unit 62: according to the conversion model selected by the pressure measurement script model selecting unit 52, the single requests split by the request splitting unit 61 are sequentially converted into corresponding pressure measurement scripts.
Script connection unit 63: and performing pressure measurement script connection on the request and the individual pressure measurement scripts obtained by conversion of the script conversion unit 62 to generate a pressure measurement script which can be directly run by the pressure measurement tool finally.
It should be noted that the method for generating the automatic pressure measurement script provided by the embodiment of the present invention may be used in the financial field, and may also be used in any technical field other than the financial field.
Fig. 8 is a schematic structural diagram of an automatic pressure-measuring script generating apparatus according to an embodiment of the present invention, and as shown in fig. 8, the automatic pressure-measuring script generating apparatus according to the embodiment of the present invention includes a copying unit 801, a sorting unit 802, and a converting unit 803, where:
the copying unit 801 is configured to copy traffic of a target application program, so as to obtain an access request and a request feedback message of the target application program; the sequencing unit 802 is configured to sequence the access requests according to a sequence of occurrence times of the access requests, and display the sequenced access requests and request feedback messages; the conversion unit 803 is configured to obtain a pressure measurement request sequence that is completed in order to respond to a request arrangement processing action of the user for the ordered access request and the request feedback message, and convert the pressure measurement request sequence into a pressure measurement script.
Specifically, a copy unit 801 in the device is configured to copy traffic of a target application program, so as to obtain an access request and a request feedback message of the target application program; the sequencing unit 802 is configured to sequence the access requests according to a sequence of occurrence times of the access requests, and display the sequenced access requests and request feedback messages; the conversion unit 803 is configured to obtain a pressure measurement request sequence that is completed in order to respond to a request arrangement processing action of the user for the ordered access request and the request feedback message, and convert the pressure measurement request sequence into a pressure measurement script.
The automatic pressure measurement script generation device provided by the embodiment of the invention copies the flow of a target application program to obtain an access request and a request feedback message of the target application program; sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages; the method comprises the steps of responding to a request arrangement processing action of a user for ordered access requests and request feedback messages to obtain an arranged pressure measurement request sequence, converting the pressure measurement request sequence into a pressure measurement script, solving the problem of complex pressure measurement logic through the request arrangement processing, further converting the arranged pressure measurement request sequence into the pressure measurement script, realizing automatic generation of various types of pressure measurement scripts, and improving the generation efficiency of the pressure measurement script.
The embodiment of the automatic pressure measurement script generating device provided in the embodiment of the present invention may be specifically used to execute the processing flows of the above method embodiments, and the functions of the embodiment are not described herein again, and refer to the detailed description of the above method embodiments.
Fig. 9 is a schematic structural diagram of an entity of an electronic device according to an embodiment of the present invention, where as shown in fig. 9, the electronic device includes: a processor (processor)901, a memory (memory)902, and a bus 903;
the processor 901 and the memory 902 complete mutual communication through a bus 903;
the processor 901 is configured to call program instructions in the memory 902 to perform the methods provided by the above-mentioned method embodiments, for example, including:
copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages;
and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
The present embodiment discloses a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, enable the computer to perform the method provided by the above-mentioned method embodiments, for example, comprising:
copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages;
and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
The present embodiment provides a computer-readable storage medium, which stores a computer program, where the computer program causes the computer to execute the method provided by the above method embodiments, for example, the method includes:
copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages;
and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In the description herein, reference to the description of the terms "one embodiment," "a particular embodiment," "some embodiments," "for example," "an example," "a particular example," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, the schematic representations of the terms used above do not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
The above-mentioned embodiments are intended to illustrate the objects, technical solutions and advantages of the present invention in further detail, and it should be understood that the above-mentioned embodiments are only exemplary embodiments of the present invention, and are not intended to limit the scope of the present invention, and any modifications, equivalent substitutions, improvements and the like made within the spirit and principle of the present invention should be included in the scope of the present invention.

Claims (10)

1. An automatic pressure test script generation method is characterized by comprising the following steps:
copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
sequencing the access requests according to the sequence of the occurrence time of the access requests, and displaying the sequenced access requests and request feedback messages;
and responding to the request arrangement processing action of the user for the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
2. The automated pressure script generation method of claim 1, wherein a pressure tool type is determined; correspondingly, the converting the pressure measurement request sequence into a pressure measurement script includes:
and selecting a conversion model corresponding to the type of the pressure measurement tool, and converting the pressure measurement request sequence into a pressure measurement script through the conversion model.
3. The automated pressure script generation method of claim 2, wherein the converting the pressure request sequence into a pressure script via the conversion model comprises:
splitting the pressure measurement request sequence to obtain each independent request;
converting each independent request into a corresponding pressure measurement script through the conversion model;
and connecting the pressure measurement scripts corresponding to the independent requests to obtain the pressure measurement scripts corresponding to the pressure measurement request sequences.
4. The method for generating the automatic pressure test script according to any one of claims 1 to 3, wherein the step of sequencing the access requests according to the sequence of the occurrence time of the access requests and displaying the sequenced access requests and request feedback messages comprises the steps of:
writing the sequenced access requests and request feedback messages into a data form; and reading the data in the data form, and displaying the ordered access request and request feedback message.
5. The automated pressure script generation method of claim 4, wherein the obtaining a completely arranged pressure request sequence in response to a request arrangement processing action of a user for the ordered access request and the request feedback message comprises:
and responding to the request arrangement processing action executed in the data form by the user to obtain a pressure measurement request sequence which is completely arranged.
6. The automated pressure measurement script generation method of any of claims 1 to 3, wherein after the step of converting the pressure measurement request sequence into a pressure measurement script, the automated pressure measurement script generation method further comprises:
and checking the pressure measurement script, and if the checking result is not passed, generating a prompt message for prompting the user to perform request arrangement processing on the sequenced access request and request feedback message again.
7. The automated pressure script generation method of any of claims 1 to 3, further comprising:
and if the verification result passes, sending the pressure measurement script passing the verification to a pressure measurement script calling party.
8. An automated pressure measurement script generation device, comprising:
the system comprises a copying unit, a processing unit and a feedback unit, wherein the copying unit is used for copying the flow of a target application program to obtain an access request and a request feedback message of the target application program;
the sequencing unit is used for sequencing the access requests according to the sequence of the occurrence time of the access requests and displaying the sequenced access requests and request feedback messages;
and the conversion unit is used for responding to the request arrangement processing action of the user aiming at the sequenced access request and request feedback message to obtain a pressure measurement request sequence which is arranged, and converting the pressure measurement request sequence into a pressure measurement script.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the steps of the method of any of claims 1 to 7 are implemented when the computer program is executed by the processor.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
CN202210173426.1A 2022-02-24 2022-02-24 Automatic pressure measurement script generation method and device Pending CN114546863A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210173426.1A CN114546863A (en) 2022-02-24 2022-02-24 Automatic pressure measurement script generation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210173426.1A CN114546863A (en) 2022-02-24 2022-02-24 Automatic pressure measurement script generation method and device

Publications (1)

Publication Number Publication Date
CN114546863A true CN114546863A (en) 2022-05-27

Family

ID=81677702

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210173426.1A Pending CN114546863A (en) 2022-02-24 2022-02-24 Automatic pressure measurement script generation method and device

Country Status (1)

Country Link
CN (1) CN114546863A (en)

Similar Documents

Publication Publication Date Title
CN108415832B (en) Interface automation test method, device, equipment and storage medium
CN111010316B (en) Flow playback method, device and system
CN106933729A (en) A kind of method of testing and system based on cloud platform
JP6045134B2 (en) Parallel workload simulation for application performance testing
CN109815119B (en) APP link channel testing method and device
CN111522728A (en) Method for generating automatic test case, electronic device and readable storage medium
CN108459850B (en) Method, device and system for generating test script
Zhang et al. Environmental modeling for automated cloud application testing
CN115860143A (en) Operator model generation method, device and equipment
CN111221721B (en) Automatic recording and executing method and device for unit test cases
CN114691506A (en) Pressure testing method, apparatus, device, medium, and program product
CN111651342A (en) HTTP interface automation testing framework based on Charles recording session
CN111897725B (en) Automatic test method, medium, equipment and system for middle platform service
CN117234916A (en) Workflow application testing method and device, electronic equipment and storage medium
CN116016270A (en) Switch test management method and device, electronic equipment and storage medium
CN114546863A (en) Automatic pressure measurement script generation method and device
Asthana et al. Maareech: Usability testing tool for voice response system using xml based user models
CN113485919A (en) Test method, test device and computer readable storage medium
CN113282504A (en) Incremental code coverage rate detection method and service development method and device
CN111160403A (en) Method and device for multiplexing and discovering API (application program interface)
CN114661609B (en) Artificial intelligence medical automation test integrated system
CN108628750B (en) Test code processing method and device
CN115829745A (en) Financial product transaction item performance analysis processing method and device
CN116795723A (en) Chain unit test processing method and device and computer equipment
CN114064432A (en) Performance pressure measurement flow simulation method and device of IT 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