CN112631921A - Method, system and storage medium for improving flow playback coverage - Google Patents
Method, system and storage medium for improving flow playback coverage Download PDFInfo
- Publication number
- CN112631921A CN112631921A CN202011584630.XA CN202011584630A CN112631921A CN 112631921 A CN112631921 A CN 112631921A CN 202011584630 A CN202011584630 A CN 202011584630A CN 112631921 A CN112631921 A CN 112631921A
- Authority
- CN
- China
- Prior art keywords
- screening
- playback
- interface request
- coverage
- request data
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 30
- 238000012216 screening Methods 0.000 claims abstract description 109
- 238000004590 computer program Methods 0.000 claims description 3
- 230000002708 enhancing effect Effects 0.000 claims 2
- 238000012360 testing method Methods 0.000 description 4
- 241000251468 Actinopterygii Species 0.000 description 3
- 238000010586 diagram Methods 0.000 description 2
- 238000004519 manufacturing process Methods 0.000 description 2
- 238000010276 construction Methods 0.000 description 1
- 238000013481 data capture Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- 230000001737 promoting effect Effects 0.000 description 1
- 238000013522 software testing Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3676—Test management for coverage analysis
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3692—Test management for test results analysis
Abstract
The invention discloses a method, a system and a storage medium for improving flow playback coverage, wherein the method comprises the following steps: establishing a fishing number strategy model; inputting at least one screening parameter value, generating at least one screening condition by the fishing strategy model according to all the screening parameter values to screen a plurality of target interface request data from an interface request database, wherein all the target interface request data form a playback data set together; performing traffic playback on the playback data set; the invention can flexibly and self-definitively screen a plurality of target interface request data from the interface request database by inputting different screening parameter values through the number fishing strategy model, so that interface request data with richer scenes can be fished during flow playback, the coverage of flow playback is increased, and the probability of finding problems is improved.
Description
Technical Field
The invention relates to the field of software testing, in particular to a method, a system and a storage medium for improving flow playback coverage.
Background
The flow playback is a vital method for monitoring the quality of the pre-release code before the software pre-release code version is online. Existing traffic playback mainly uses the first N pieces of data created in the database with the latest time for playback, and only this is used to cover the regression test of the production environment.
However, since the collected data is captured randomly in real time in the production environment, the latest first N pieces of data are played back during playback, some boundary test scenarios cannot be covered, and due to lack of coverage of some test scenarios, the code coverage rate is not high, the possibility of finding a problem is not high, the reliability of playback is not high, and the risk that the online process may have is not controllable.
Disclosure of Invention
The invention aims to provide a method for improving flow playback coverage, which can flexibly and self-definitively screen a plurality of target interface request data from an interface request database by inputting different screening parameter values through a number fishing strategy model so as to fish interface request data with richer scenes during flow playback, increase the coverage of flow playback and improve the probability of finding problems.
The invention further aims to provide a system for improving the flow playback coverage, which can flexibly and self-definitively screen a plurality of target interface request data from an interface request database by inputting different screening parameter values through a number fishing strategy model, so as to fish interface request data with richer scenes during flow playback, increase the coverage of flow playback and improve the probability of finding problems.
Still another object of the present invention is to provide a storage medium, which can flexibly and self-definitively screen a plurality of target interface request data from an interface request database by inputting different screening parameter values through a number-dragging policy model, so as to drag for interface request data with richer scenes during traffic playback, increase coverage of traffic playback, and improve probability of finding problems.
In order to realize the purpose, the invention discloses a method for improving flow playback coverage, which comprises the following steps:
s1, establishing a fishing number strategy model;
s2, inputting at least one screening parameter value, wherein the number fishing strategy model generates at least one screening condition according to all the screening parameter values to screen a plurality of target interface request data from an interface request database, and all the target interface request data jointly form a playback data set;
and S3, performing flow playback on the playback data set.
Compared with the prior art, the method for improving the flow playback coverage can screen a plurality of target interface request data from the interface request database by inputting different screening parameter values flexibly through the number fishing strategy model and in a self-defined manner, so that the interface request data with richer scenes can be fished during flow playback, the coverage of the flow playback is increased, and the probability of finding problems is improved.
Preferably, the step (1) specifically includes:
and S11, providing at least one screening formula, wherein each screening formula corresponds to one type of screening parameter value, the screening formula can screen target interface request data meeting the current screening formula according to the input corresponding screening parameter value, and all the screening formulas form the fishing number strategy model together.
Preferably, the fishing number strategy model comprises a model interface, the model interface comprises at least one parameter window for inputting screening parameter values, each parameter window is used for inputting one type of screening parameter values, and the screening formula generates corresponding screening conditions according to the input corresponding screening parameter values.
Preferably, the model interface further comprises at least one logic window, the selectable types of the logic window comprise sum logic, or logic and not logic, and the logic window is used for adjusting the logic relationship between the screening conditions.
Preferably, the type of the screening parameter value includes an interface type, a platform type, a version type, an argument value type or an argument return value type.
Preferably, the flow playback data selecting method is respectively executed in a pre-release code and a comparison code, and after the step (3), the method further includes:
and S4, generating a flow playback report according to the flow playback result.
Preferably, the flow playback report includes a combination of one or more of an interface value, a platform value, a version value, an entry value, an exit return value, a screening condition, a screening duration, an executive or a screening time, and a differential analysis of corresponding parameters in the pre-release code and the comparison code, respectively.
Preferably, step (1) is preceded by:
s101, interface request data are captured, and all the interface request data are marked as the interface request database.
Correspondingly, the invention also discloses a system for improving the flow playback coverage based on data screening, which comprises:
the first execution module is used for establishing a fishing strategy model;
the second execution module is used for inputting screening parameters into the number fishing strategy model, the number fishing side rate model screens a plurality of target interface request data from an interface request database according to the screening parameters, and all the target interface request data form a playback data set together;
and the third execution module is used for carrying out flow playback on the playback data set.
Correspondingly, the invention also discloses a storage medium for storing a computer program, and the program is executed by a processor to realize the method for improving the flow playback coverage.
Drawings
FIG. 1 is a block flow diagram of a method of promoting traffic playback coverage of the present invention;
fig. 2 is a block diagram of the construction of the boost flow playback overlay system of the present invention.
Detailed Description
In order to explain technical contents, structural features, and objects and effects of the present invention in detail, the following detailed description is given with reference to the accompanying drawings in conjunction with the embodiments.
Referring to fig. 1, the method for improving traffic playback coverage of the present embodiment is suitable for performing independent screening playback on interface request data that is difficult to be covered or not fully covered during normal traffic playback execution in a data screening manner, so as to improve traffic coverage. The method comprises the following steps:
and S1, establishing a fishing number strategy model.
The number fishing strategy model is used for screening the existing interface request data according to the input screening parameter values.
S2, inputting at least one screening parameter value, generating at least one screening condition by the number fishing strategy model according to all the screening parameter values to screen a plurality of target interface request data from the interface request database, wherein all the target interface request data jointly form a playback data set.
Preferably, the type of the filtered parameter value in this embodiment includes an interface type, a platform type, a version type, an in-parameter value type, or an out-parameter-return value type. Specifically, when the type of the screening parameter value is the interface type, the corresponding interface parameter value may be input according to a preset interface name, and if the preset interface name includes an a interface, a B interface, and a C interface, the data dragging policy model screens out the target interface request data related to the a interface when the a interface is input as the screening condition.
When the type of the screening parameter value is a platform type, the corresponding platform parameter value can be input according to a preset platform name, if the preset platform name comprises a platform A, a platform B and a platform C, when the platform A is input as a screening condition, the number dragging strategy model screens out target interface request data related to the platform A.
When the type of the screening parameter value is the version type, the corresponding version parameter value can be input according to the preset version name, if the preset version name comprises the version A, the version B and the version C, the data fetching strategy model screens out the target interface request data related to the version A when the version A is input as the screening condition.
When the type of the screening parameter value is the input parameter value type, the corresponding input parameter value can be input in the data range of the input parameter value, for example, one or more input parameter values can be input, so that the relevant interface request data which accord with the input parameter value can be screened out through the bailing number strategy model, or one or more interval values of the input parameter value can be input, so that the relevant target interface request data which accord with the input parameter value can be screened out through the bailing number strategy model.
When the type of the screening parameter value is the parameter-output return value type, the corresponding parameter-output return value can be input in the data range of the parameter-output return value, for example, one or more parameter-output return values can be input to screen out the related target interface request data which accord with the input parameter-output return value through the parameter-output strategy model, or one or more interval values of the parameter-output return value can be input to screen out the related target interface request data which accord with the input parameter-output return value through the parameter-output strategy model.
It should be noted that the type of the screening parameter value may also be other types related to the interface request data, and the specific type of the screening parameter value is not limited in this embodiment.
And S3, performing flow playback on the playback data set.
In the step, the flow playback is carried out on the screened destination interface request data so as to check whether the code has defects.
Preferably, the step (1) specifically includes:
and S11, providing at least one screening formula, wherein each screening formula corresponds to one type of screening parameter value, the screening formula can screen target interface request data meeting the current screening formula according to the input corresponding screening parameter value, and all the screening formulas form the fishing number strategy model together.
It can be understood that the number fishing strategy model is composed of at least one screening formula, the input screening parameter value can activate the screening formula corresponding to the type of the screening parameter value, and the screening formula forms a screening condition under the specific screening parameter value to screen out the target interface request data meeting the current screening formula.
Preferably, to facilitate the screening operation, the fishing number strategy model includes a model interface, the model interface includes at least one parameter window for inputting screening parameter values, each parameter window is used for inputting one type of screening parameter values, and the screening formula generates corresponding screening conditions according to the input corresponding screening parameter values.
Further, the model interface further comprises at least one logic window, the selectable types of the logic window comprise sum logic, or logic and not logic, and the logic window is used for adjusting the logic relationship between the screening conditions.
It can be understood that the model interface of this embodiment includes an interface type parameter window, a platform type parameter window, a version type parameter window, an entry parameter type parameter window, and an exit parameter return value type parameter window, where each parameter window is used to input a corresponding type of screening parameter value. Each parameter window is provided with a logic window, and the logic window is used for adjusting the screening logic of the screening conditions corresponding to any parameter window and corresponding to the rest parameter windows. For example, the number fishing strategy model generates 3 screening conditions, and the inputs of the logic windows corresponding to the three screening conditions are all sum logic, so that the screened target interface request data simultaneously meets the three screening conditions; for another example, the number-fishing strategy model generates 1 screening condition, and the input of the logic window of the screening condition is a non-logic, and the screening result takes the rest interface request data in the interface request database except the interface request data meeting the screening condition as the target interface request data. The specific use of the model interface can refer to, but is not limited to, the use mode of common table retrieval.
Preferably, the method for selecting the flow playback data is executed in a pre-release code and a comparison code respectively, where the pre-release code refers to a code to be tested, and the comparison code refers to a code that can normally run after a previous test, and corresponding playback data can be obtained by executing the method in both the pre-release code and the comparison code.
The step (3) is followed by:
and S4, generating a flow playback report according to the flow playback result. The purpose of the flow playback report is to generate flow playback statistical data of the pre-release codes and the comparison codes and form differential analysis so that an operator can judge whether the pre-release codes have problems.
Preferably, the flow playback report includes a combination of one or more of an interface value, a platform value, a version value, an entry value, an exit return value, a screening condition, a screening duration, an executive or a screening time, and a differential analysis of corresponding parameters in the pre-release code and the comparison code, respectively.
It is understood that the differential analysis refers to comparing the corresponding signature values of the pre-release code and each interface in the comparison code, such as comparing the difference between the corresponding signatures of the pre-release code and each interface in the comparison code, manually or automatically. And when the difference value is larger than the preset threshold value, the problem of the pre-issued code can be judged, and a programmer is reminded of needing to modify the pre-issued code.
It should be noted that the content included in the traffic playback report may also be other content that can help an operator to grasp the result of the traffic playback, and the specific content of the traffic playback report is not limited herein.
Preferably, step (1) is preceded by:
s101, interface request data are captured, and all the interface request data are marked as the interface request database.
The capture mode can capture data in a full-scale mode, and can capture interface request data according to a preset time interval. When the interface request data are captured according to the preset time interval, the interface request data captured each time are all interface request data generated by two adjacent time intervals, and a plurality of numbers of interface request data are obtained after data capture for many times. For example, the preset time interval is 100ms, and 100 times of capturing are performed, and assuming that the number of interface request data captured each time is one hundred thousand, ten million interface request data need to be processed this time. It should be noted that the interface request data is dynamically generated, and the number of request data captured each time is not necessarily fixed, such as capturing one hundred thousand pieces for the first time, capturing fifty thousand pieces for the second time, capturing twelve thousand pieces for the third time, and the like.
Correspondingly, the invention also discloses a system for improving the flow playback coverage based on data screening, which comprises:
the first execution module 10 is used for establishing a fishing strategy model;
the second execution module 20 is configured to input the screening parameters into the number fishing strategy model, the number fishing side rate model screens a plurality of target interface request data from the interface request database according to the screening parameters, and all the target interface request data together form a playback data set;
a third executing module 30, configured to perform traffic playback on the playback data set.
Correspondingly, the invention also discloses a storage medium for storing a computer program, and the program is executed by a processor to realize the method for improving the flow playback coverage.
With reference to fig. 1 and fig. 2, the method for improving the flow playback coverage of the present invention can flexibly and self-definitively screen a plurality of target interface request data from the interface request database by inputting different screening parameter values through the number fishing policy model, so as to fish interface request data with richer scenes during flow playback, increase the coverage of flow playback, and improve the probability of finding problems.
The above disclosure is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the scope of the present invention, therefore, the present invention is not limited by the appended claims.
Claims (10)
1. A method for improving flow playback coverage, which is characterized by comprising the following steps:
establishing a fishing number strategy model;
inputting at least one screening parameter value, generating at least one screening condition by the fishing strategy model according to all the screening parameter values to screen a plurality of target interface request data from an interface request database, wherein all the target interface request data form a playback data set together;
and performing flow playback on the playback data set.
2. The method for improving the flow playback coverage of claim 1, wherein the establishing of the number fishing strategy model specifically comprises:
providing at least one screening formula, wherein each screening formula corresponds to one type of screening parameter value, the screening formula can screen target interface request data meeting the current screening formula according to the input corresponding screening parameter value, and all the screening formulas form the fishing number strategy model together.
3. The method for improving flow playback coverage as recited in claim 1, wherein the fishing strategy model comprises a model interface, the model interface comprises at least one parameter window for inputting screening parameter values, each of the parameter windows is used for inputting one type of screening parameter values, and the screening formula generates corresponding screening conditions according to the input corresponding screening parameter values.
4. The method of enhancing flow playback coverage of claim 3, wherein the model interface further comprises at least one logical window, the selectable types of the logical window comprising AND logic, OR logic and NOT logic, the logical window for adjusting the logical relationship between the filter conditions.
5. The method of improving traffic playback coverage of claim 1, wherein the type of the screening parameter value comprises an interface type, a platform type, a version type, an ingress parameter type, or an egress return value type.
6. The method for improving flow playback coverage as claimed in claim 1, wherein the flow playback data selecting method is executed in a pre-release code and a comparison code respectively, and the flow playback is performed on the playback data set, and then further comprising:
and generating a flow playback report according to the flow playback result.
7. The method of improving traffic playback coverage of claim 6, wherein the traffic playback reports comprise a combination of one or more of interface values, platform values, version values, entry values, exit return values, screening conditions, screening durations, executives, or screening times, and differential analysis of corresponding parameters in pre-release codes and comparison codes, respectively.
8. The method for improving flow playback coverage as recited in claim 1, wherein the establishing a drag strategy model further comprises:
and capturing interface request data, and marking all the interface request data as the interface request database.
9. A data screening-based system for enhancing traffic playback coverage, comprising:
the first execution module is used for establishing a fishing strategy model;
the second execution module is used for inputting screening parameters into the number fishing strategy model, the number fishing side rate model screens a plurality of target interface request data from an interface request database according to the screening parameters, and all the target interface request data form a playback data set together;
and the third execution module is used for carrying out flow playback on the playback data set.
10. A storage medium for storing a computer program, characterized in that: the program when executed by a processor implements a method of lifting traffic playback coverage as claimed in any one of claims 1 to 8.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011584630.XA CN112631921A (en) | 2020-12-28 | 2020-12-28 | Method, system and storage medium for improving flow playback coverage |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011584630.XA CN112631921A (en) | 2020-12-28 | 2020-12-28 | Method, system and storage medium for improving flow playback coverage |
Publications (1)
Publication Number | Publication Date |
---|---|
CN112631921A true CN112631921A (en) | 2021-04-09 |
Family
ID=75285738
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011584630.XA Pending CN112631921A (en) | 2020-12-28 | 2020-12-28 | Method, system and storage medium for improving flow playback coverage |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112631921A (en) |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108984623A (en) * | 2018-06-14 | 2018-12-11 | 东软集团股份有限公司 | Data query conditions generation method, device, storage medium and electronic equipment |
CN111010316A (en) * | 2019-12-17 | 2020-04-14 | 广州唯品会信息科技有限公司 | Flow playback method, device and system |
CN111045952A (en) * | 2019-12-16 | 2020-04-21 | 广州品唯软件有限公司 | Software testing method, flow playback device, terminal equipment and readable storage medium |
CN111061637A (en) * | 2019-12-13 | 2020-04-24 | 广州品唯软件有限公司 | Interface test method, interface test device and storage medium |
CN111083013A (en) * | 2019-12-18 | 2020-04-28 | 北京嘀嘀无限科技发展有限公司 | Test method and device based on flow playback, electronic equipment and storage medium |
CN111708712A (en) * | 2020-06-24 | 2020-09-25 | 北京自如信息科技有限公司 | User behavior test case generation method, flow playback method and electronic equipment |
CN111767227A (en) * | 2020-06-30 | 2020-10-13 | 深圳前海微众银行股份有限公司 | Recording playback test method and device |
CN111949549A (en) * | 2020-08-31 | 2020-11-17 | 携程计算机技术(上海)有限公司 | Test request screening method, system, electronic device and storage medium |
-
2020
- 2020-12-28 CN CN202011584630.XA patent/CN112631921A/en active Pending
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108984623A (en) * | 2018-06-14 | 2018-12-11 | 东软集团股份有限公司 | Data query conditions generation method, device, storage medium and electronic equipment |
CN111061637A (en) * | 2019-12-13 | 2020-04-24 | 广州品唯软件有限公司 | Interface test method, interface test device and storage medium |
CN111045952A (en) * | 2019-12-16 | 2020-04-21 | 广州品唯软件有限公司 | Software testing method, flow playback device, terminal equipment and readable storage medium |
CN111010316A (en) * | 2019-12-17 | 2020-04-14 | 广州唯品会信息科技有限公司 | Flow playback method, device and system |
CN111083013A (en) * | 2019-12-18 | 2020-04-28 | 北京嘀嘀无限科技发展有限公司 | Test method and device based on flow playback, electronic equipment and storage medium |
CN111708712A (en) * | 2020-06-24 | 2020-09-25 | 北京自如信息科技有限公司 | User behavior test case generation method, flow playback method and electronic equipment |
CN111767227A (en) * | 2020-06-30 | 2020-10-13 | 深圳前海微众银行股份有限公司 | Recording playback test method and device |
CN111949549A (en) * | 2020-08-31 | 2020-11-17 | 携程计算机技术(上海)有限公司 | Test request screening method, system, electronic device and storage medium |
Non-Patent Citations (1)
Title |
---|
褚伟波;管晓宏;蔡忠闽;陶敬;: "面向互动式网络场景再现的流速控制系统与方法", 计算机学报, no. 07 * |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107291911B (en) | Anomaly detection method and device | |
US8434058B1 (en) | Integrated system and method for validating the functionality and performance of software applications | |
CN107145445B (en) | Automatic analysis method and system for error log of software automation test | |
CN110428127B (en) | Automatic analysis method, user equipment, storage medium and device | |
CN111143188B (en) | Method and equipment for automatically testing application | |
US20130061209A1 (en) | Systems and methods for processing software application metadata associated with a software application | |
CN110471945B (en) | Active data processing method, system, computer equipment and storage medium | |
CN109344053B (en) | Interface coverage test method, system, computer device and storage medium | |
US9594617B2 (en) | Method and apparatus for positioning crash | |
CN109918437A (en) | Distributed data processing method, apparatus and data assets management system | |
CN113792341B (en) | Automatic detection method, device, equipment and medium for privacy compliance of application program | |
CN111859047A (en) | Fault solving method and device | |
CN109743286A (en) | A kind of IP type mark method and apparatus based on figure convolutional neural networks | |
US20230048386A1 (en) | Method for detecting defect and method for training model | |
US11777982B1 (en) | Multidimensional security situation real-time representation method and system and applicable to network security | |
CN111258881A (en) | Intelligent test system for workflow test | |
CN111258876A (en) | Accurate regression testing method and device under micro-service architecture | |
CN112631921A (en) | Method, system and storage medium for improving flow playback coverage | |
CN113612645A (en) | Internet of things data processing method and system | |
CN111651760A (en) | Method for comprehensively analyzing equipment safety state and computer readable storage medium | |
KR102346885B1 (en) | Method and system to visualize abnormal behavior detection result for enterprise resource planning system in shape of flowering stem | |
CN116248381A (en) | Alarm aggregation method and device, electronic equipment and storage medium | |
CN115576834A (en) | Software test multiplexing method, system, terminal and medium for supporting fault recovery | |
US20180052995A1 (en) | Automated blackbox inference of external origin user behavior | |
CN110210048B (en) | Method and device for establishing patrol analysis model |
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 |