Unlock instant, AI-driven research and patent intelligence for your innovation.

Mock data updating method and device and computer equipment

A data update and data update technology, which is applied in the field of computer equipment and mock data update, can solve the problems of wasting test server memory, inconvenient maintenance, and spending a lot of time and energy, and achieve the effect of easy-to-use automatic update time stamp function

Pending Publication Date: 2021-04-20
GUANGZHOU PINWEI SOFTWARE
View PDF0 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] Mock data is usually pre-configured in the code or written in the configuration file, and stored in the memory of the test server. When the amount of data is large, the memory of the test server is wasted and it is inconvenient to maintain
[0004] At present, the mock data is stored in a separate database, and the mock data can be modified and updated without modifying the code and redeploying the service. However, many timestamp-related fields in the mock data used for automation need to be updated frequently. To ensure that the automation use cases can be executed normally, it often takes a lot of time and effort to update a large amount of mock data in the database to keep the mock data never expired

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Mock data updating method and device and computer equipment
  • Mock data updating method and device and computer equipment
  • Mock data updating method and device and computer equipment

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0047] Embodiment 1: This embodiment provides a mock data update method, refer to figure 1 As shown, the method includes:

[0048] S1-1. Receive mock data.

[0049] S1-2. Filter out the mock data containing the preset identification field and record it as the first mock data to be updated.

[0050] S1-3. Identify the number type field in the first mock data to be updated and determine whether the number of digits in the number type field conforms to the first preset rule. If so, record the number type field as the first target timestamp field.

[0051] S1-4. Update the first target timestamp field according to a preset update rule.

[0052]The method for updating mock data provided by this embodiment screens out the first mock data to be updated that needs to be updated and whose timestamp field content is unknown through the preset identification field, and identifies the first mock data to be updated by identifying the digital type field and making a judgment. Update the ...

Embodiment 2

[0053] Embodiment 2: This embodiment provides a mock data update method, refer to figure 2 As shown, the methods include:

[0054] S2-1. Receive mock data.

[0055] In a preferred embodiment, this step specifically includes:

[0056] Regularly receive the mock data transmitted by the database. A timestamp field is a sequence of characters that uniquely identifies a moment in time. Periodically traverse the mock data in the database so that the mock data can be updated in time.

[0057] S2-2. Filter out the mock data containing the preset identification field and record it as the first mock data to be updated.

[0058] In a preferred embodiment, this step specifically includes:

[0059] The mock data containing the preset identification field is screened out as the first data to be updated and the remaining mock data is recorded as the second mock data to be updated.

[0060] The mock data is grouped by identifying whether the mock data contains a preset identification f...

Embodiment 3

[0081] Embodiment 3: This embodiment provides a mock data updating device, refer to image 3 As shown, the device includes:

[0082] The receiving module 31 is configured to receive mock data.

[0083] The screening module 32 is used to filter out the mock data containing the preset identification field and mark it as the first mock data to be updated.

[0084] The processing module 33 is used to identify the number type field in the first mock data to be updated and determine whether the number of digits in the number type field complies with the first preset rule, and when the number of digits in the number type field meets the first preset rule, The numeric type field is denoted as the first target timestamp field.

[0085] An update module 34, configured to update the first target timestamp field according to preset update rules;

[0086] The device also includes: a conversion module 35, configured to convert the first target timestamp field to obtain the first time;

...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a mock data updating method and device and computer equipment. The method comprises the steps of receiving mock data; screening out mock data containing a preset identification field, and recording the mock data as first to-be-updated mock data; identifying a digital type field in the first to-be-updated mock data and judging whether the digit of the digital type field conforms to a first preset rule or not, and if yes, marking the digital type field as a first target timestamp field; updating the first target timestamp field according to a preset updating rule. First to-be-updated mock data which needs to be updated and has unknown timestamp field content is screened out through a preset identification field, a digital type field is identified, a timestamp field is judged and identified, namely a first target timestamp field, in the first to-be-updated mock data, then a first target timestamp is updated according to the preset updating rule, a simple and easy-to-use automatic timestamp updating function is provided, and mock data timestamp field updating of unknown timestamp field content can be realized without excessive intervention of a user.

Description

technical field [0001] The invention relates to the field of computer automatic testing, in particular to a mock data updating method, device and computer equipment. Background technique [0002] Mock test is a simulation test method in the current automated test, that is, during the test process, for some objects that are not easy to construct or obtain, a virtual object is used to create a test method for testing, and the mock data is simulated . [0003] Mock data is usually pre-configured in the code or written in the configuration file, and stored in the memory of the test server. When the amount of data is large, the memory of the test server is wasted and it is inconvenient to maintain. [0004] At present, the mock data is stored in a separate database, and the mock data can be modified and updated without modifying the code and redeploying the service. However, many timestamp-related fields in the mock data used for automation need to be updated frequently. To ens...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F11/36G06F16/23G06F16/2458
Inventor 欧志聪
Owner GUANGZHOU PINWEI SOFTWARE