CN111831552A - Automatic testing method for real-time user behavior system - Google Patents
Automatic testing method for real-time user behavior system Download PDFInfo
- Publication number
- CN111831552A CN111831552A CN202010512491.3A CN202010512491A CN111831552A CN 111831552 A CN111831552 A CN 111831552A CN 202010512491 A CN202010512491 A CN 202010512491A CN 111831552 A CN111831552 A CN 111831552A
- Authority
- CN
- China
- Prior art keywords
- real
- data processing
- processing node
- time
- time 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
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/362—Software debugging
- G06F11/3644—Software debugging by instrumenting at runtime
-
- 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
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 testing method for a real-time user behavior system, which comprises the following steps: step 1: recording production flow and adding the production flow into a test data set; step 2: adding mock abnormal data into a test data set aiming at the real-time data processing node; and step 3: importing the test data set into a real-time user behavior system to serve as an input parameter of a real-time data processing node, and exporting an output parameter of the real-time data processing node; and 4, step 4: checking the data format of the real-time data processing node, and carrying out accuracy check on the data format and the imported data; and 5: adding the abnormal data of the next-stage real-time data processing node into the output parameter of the real-time data processing node as the input parameter of the next-stage real-time data processing node; step 6: and repeating the steps 4-5 until the test data set is processed by all the real-time data processing nodes. After the system is divided into a plurality of subsystems, the intermediate flow can be covered, and the overall test coverage rate is improved greatly.
Description
Technical Field
The invention relates to the field of automatic testing, in particular to an automatic testing method for a real-time user behavior system.
Background
For an internet application, services are various and relatively independent, each service has a behavior dotting reporting and analyzing system, a real-time portrait of a user needs to be constructed for a fine operation scene and sensing the behavior of the user in real time, a uniform real-time user behavior system is derived, layer-by-layer processing is carried out in a data flow mode, and finally, uniform standard data is formed and a real-time user behavior portrait is formed. As shown in fig. 2.
For such internally closed systems, the usual funnel-shaped (see-and-go) test protocols are not applicable:
the first reason is as follows: the process is long, and once a certain node has a problem, abnormal positioning is not easy to occur;
the second reason is that: each node may have abnormal data, and the processing of the abnormal data by the next node cannot be covered.
Disclosure of Invention
Aiming at the defects of the prior art, the invention provides an automatic testing method for a real-time user behavior system, which can improve the overall testing coverage rate.
In order to achieve the purpose, the invention adopts the following technical scheme:
an automated testing method for a real-time user behavior system, comprising the steps of:
step 1: recording production flow and adding the production flow into a test data set;
step 2: adding mock abnormal data into a test data set aiming at the real-time data processing node;
and step 3: importing the test data set into a real-time user behavior system to serve as an input parameter of a real-time data processing node, and exporting an output parameter of the real-time data processing node;
and 4, step 4: checking the data format of the real-time data processing node, and carrying out accuracy check on the data format and the imported data;
and 5: adding the abnormal data of the next-stage real-time data processing node into the output parameter of the real-time data processing node as the input parameter of the next-stage real-time data processing node;
step 6: and repeating the steps 4-5 until the test data set is processed by all the real-time data processing nodes.
Has the advantages that:
1. compared with the conventional automatic testing method, only the inlet and the outlet of the system are concerned, the intermediate flow is difficult to cover, and the intermediate flow can be covered after the system is divided into a plurality of subsystems, so that the overall testing coverage rate is improved greatly.
2. The problem positioning is facilitated, once a problem occurs in a system with a long flow, the problem cannot be quickly positioned, and through the segmentation system, each node is independently checked, so that the problem is positioned more easily.
3. The robustness of each node is guaranteed, the system is a continuous iteration process, each node can correctly process abnormal data of the node under normal conditions, but if the abnormal data flows into the next node in the continuous iteration process or under other abnormal conditions, the data processing flow of the whole system is likely to be broken if the next node is not robust enough. Therefore, by slicing, adding anomaly data to each child node, the robustness of each child node can be verified.
Drawings
FIG. 1 is a flow chart of a method for automated testing of a real-time user behavior system of the present invention;
FIG. 2 is a schematic diagram of a conventional real-time user behavior system;
fig. 3 is a schematic structural diagram of a real-time user behavior system according to the present invention.
Detailed Description
The following further describes the testing method and data processing with reference to examples, but the embodiments of the present invention are not limited thereto.
As shown in fig. 1, the present invention employs the following test protocol:
firstly, by using the concept of software slicing, slicing a real-time user behavior system through a middleware, and slicing the system to form a plurality of sub-nodes, wherein each sub-node has independent input and output parameters;
recording the inlet flow (original data) of the production environment through a tool, mainly reporting data of the behavior of each service, and adding the data into a test data set;
analyzing each node, and according to the entry format of each node and in combination with the test boundary, mock outputs an abnormal test data set of each node in a common mode as follows: the method comprises the steps of setting a field to be null, setting a field format to be abnormal, lacking the field, increasing the field, exceeding a threshold value and the like, and meanwhile, adding some specific abnormal data according to the implementation logic inside the node and adding the abnormal data into an abnormal test data set;
fourthly, the flow recorded in the production environment and the abnormal data set of the node 1 are led into a system inlet (middleware A), and in the process of processing the flow data, the interruption is not carried out, but the output parameter (middleware B) of the node 1 is led out and processed subsequently by adding consumers, so that the flow direction of the real-time system data is ensured;
and fifthly, checking the data format of the node 1 (middleware B), carrying out 1-to-1 accuracy check on the data and the imported data, checking whether the abnormal data is correctly processed or not, avoiding the situation that the abnormal data is continuously lost to the next node, checking a system log, and judging whether the abnormality is thrown or not.
Adding the abnormal data of the node 2 into the output parameter of the node 1 (middleware B) as the input parameter of the node 2 (middleware C), wherein in the process, the output parameter of the node 1 is consumed by the node 2 naturally as a real-time data stream of the whole system, and in the actual operation process, only the abnormal data of the node 2 needs to be led into the middleware B, and in the stream data processing process, the interruption is not carried out, but the output parameter of the node 2 (middleware C) is led out and subsequently processed by adding consumers, so that the data flow direction of the real-time system is ensured;
and seventhly, checking the data format of the node 2, performing 1-to-1 accuracy check on the data and the imported data, checking whether abnormal data is correctly processed or not, avoiding the situation that the abnormal data is continuously lost to the next node, checking a system log, and judging whether the abnormal data is thrown or not.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims (1)
1. An automated testing method for a real-time user behavior system is characterized by comprising the following steps:
step 1: recording production flow and adding the production flow into a test data set;
step 2: adding mock abnormal data into a test data set aiming at the real-time data processing node;
and step 3: importing the test data set into a real-time user behavior system to serve as an input parameter of a real-time data processing node, and exporting an output parameter of the real-time data processing node;
and 4, step 4: checking the data format of the real-time data processing node, and carrying out accuracy check on the data format and the imported data;
and 5: adding the abnormal data of the next-stage real-time data processing node into the output parameter of the real-time data processing node as the input parameter of the next-stage real-time data processing node;
step 6: and repeating the steps 4-5 until the test data set is processed by all the real-time data processing nodes.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010512491.3A CN111831552A (en) | 2020-06-08 | 2020-06-08 | Automatic testing method for real-time user behavior system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010512491.3A CN111831552A (en) | 2020-06-08 | 2020-06-08 | Automatic testing method for real-time user behavior system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN111831552A true CN111831552A (en) | 2020-10-27 |
Family
ID=72898461
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010512491.3A Pending CN111831552A (en) | 2020-06-08 | 2020-06-08 | Automatic testing method for real-time user behavior system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111831552A (en) |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20140181590A1 (en) * | 2012-12-20 | 2014-06-26 | Sap Ag | Automated end-to-end testing via multiple test tools |
US20140365827A1 (en) * | 2011-06-15 | 2014-12-11 | Amazon Technologies, Inc. | Architecture for end-to-end testing of long-running, multi-stage asynchronous data processing services |
CN106708719A (en) * | 2015-08-04 | 2017-05-24 | 阿里巴巴集团控股有限公司 | Business function testing method and apparatus |
CN107329890A (en) * | 2017-06-06 | 2017-11-07 | 北京金山安全软件有限公司 | Test method and device based on Mock and server |
CN109582559A (en) * | 2018-09-28 | 2019-04-05 | 阿里巴巴集团控股有限公司 | Verification method, device, electronic equipment and the storage medium of system |
CN109815138A (en) * | 2019-01-03 | 2019-05-28 | 深圳壹账通智能科技有限公司 | Business information test method, device, computer equipment and storage medium |
CN110502426A (en) * | 2019-07-08 | 2019-11-26 | 中国工商银行股份有限公司 | The test method and device of distributed data processing system |
-
2020
- 2020-06-08 CN CN202010512491.3A patent/CN111831552A/en active Pending
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20140365827A1 (en) * | 2011-06-15 | 2014-12-11 | Amazon Technologies, Inc. | Architecture for end-to-end testing of long-running, multi-stage asynchronous data processing services |
US20140181590A1 (en) * | 2012-12-20 | 2014-06-26 | Sap Ag | Automated end-to-end testing via multiple test tools |
CN106708719A (en) * | 2015-08-04 | 2017-05-24 | 阿里巴巴集团控股有限公司 | Business function testing method and apparatus |
CN107329890A (en) * | 2017-06-06 | 2017-11-07 | 北京金山安全软件有限公司 | Test method and device based on Mock and server |
CN109582559A (en) * | 2018-09-28 | 2019-04-05 | 阿里巴巴集团控股有限公司 | Verification method, device, electronic equipment and the storage medium of system |
CN109815138A (en) * | 2019-01-03 | 2019-05-28 | 深圳壹账通智能科技有限公司 | Business information test method, device, computer equipment and storage medium |
CN110502426A (en) * | 2019-07-08 | 2019-11-26 | 中国工商银行股份有限公司 | The test method and device of distributed data processing system |
Non-Patent Citations (2)
Title |
---|
MU: "app对于接口返回数据的容错测试(健壮性测试)", Retrieved from the Internet <URL:https://blog.csdn.net/weixin_44688232/article/details/106290560?> * |
潘诗瑶: "基于NodeJS进行自动化单元测试中mock平台的设计与研究", 《中国优秀硕士学位论文全文数据库 (信息科技辑)》, no. 3 * |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109005162B (en) | Industrial control system security audit method and device | |
CN110602105B (en) | Large-scale parallelization network intrusion detection method based on k-means | |
CN113485863B (en) | Method for generating heterogeneous imbalance fault samples based on improved generation of countermeasure network | |
CN110807518A (en) | Outlier detection method for power grid data | |
CN111191720B (en) | Service scene identification method and device and electronic equipment | |
CN110287827B (en) | Bridge strain data outlier identification method based on data correlation | |
CN108683658B (en) | Industrial control network flow abnormity identification method based on multi-RBM network construction reference model | |
CN110245077A (en) | A kind of response method and equipment of program exception | |
CN113572726A (en) | Multi-mode network control-data plane consistency verification method and device | |
CN108197254B (en) | A kind of data recovery method based on neighbour | |
CN111831552A (en) | Automatic testing method for real-time user behavior system | |
CN111290371B (en) | Method and device for remote diagnosis of Internet of things equipment and electronic equipment | |
CN110990223A (en) | Monitoring alarm method and device based on system log | |
CN110597889A (en) | Machine tool fault prediction method based on improved Apriori algorithm | |
CN107908557B (en) | Embedded software credible attribute modeling and verifying method | |
CN115756395A (en) | Multi-dimensional object data statistical method based on annotation configuration | |
CN114564758A (en) | Management method and system of operation and maintenance data | |
CN114429240A (en) | Method and device for monitoring running state of highway equipment | |
CN113703401A (en) | Configuration method and device of anomaly detection algorithm, electronic equipment and storage medium | |
CN112069037A (en) | Method and device for detecting no threshold value of cloud platform | |
CN111208993B (en) | Flow data analysis processing system | |
CN112463578B (en) | System test case generation method based on step-by-step solution of component contract | |
EP4131881A1 (en) | Industrial network behavior analysis method, apparatus and system, and computer-readable medium | |
CN111010393B (en) | Anomaly detection and elimination method for big data cleaning | |
CN115694937B (en) | Method for training malicious flow detection system by constructing virtual abnormal flow |
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 |