Test data construction method and device, equipment and medium

By obtaining target information data and counting scripts, and constructing and verifying test data, the problems of low efficiency and safety risks in the existing technology are solved, and efficient and accurate test data generation and recycling are achieved.

CN119226148APending Publication Date: 2024-12-31SHENZHEN LEXIN SOFTWARE TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411177277.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-26
Publication Date
2024-12-31

AI Technical Summary

Technical Problem

In the prior art, the test data links are long and there are many interception rules, resulting in low efficiency in generating test data, low reuse rate, and difficulty in ensuring data consistency, and security risks.

Method used

By obtaining target information data, determine the current process stage, obtain the corresponding first data pool and counting script, use counting script to construct the initial data and target information data, recycle historical data, perform process verification and verification, and ensure testing Data accuracy and security.

Benefits of technology

It reduces the time for generating test data, improves efficiency and success rate, realizes the recycled use and secure storage of test data, and meets business rules and security requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119226148A_ABST
    Figure CN119226148A_ABST
Patent Text Reader

Abstract

The invention discloses a test data construction method and device, equipment and a medium, and the method comprises the steps: obtaining target information data to determine a current process stage, and determining a first data pool; when it is determined that the historical test data corresponding to the target information data is not included in the first data pool, obtaining a data creation script, and obtaining initial data from a second data pool corresponding to the previous process stage; performing data construction on the initial data and the target information data through a data construction script so as to cyclically utilize historical data to obtain test data; performing process verification on the test data through the target process to obtain a process verification result; and when the process verification result passes the verification through the target information data, determining that the test data construction is completed, and feeding back the test data to the current test account and storing the test data in the first data pool. According to the method, the original process is divided into different stages, so that the number making time is shortened, and the number making efficiency is improved. And by verifying the test data, the number creation success rate is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of software testing, and in particular to a test data construction method, device, equipment and medium. Background Art

[0002] Currently, the test data construction of Internet finance credit matching business faces three major challenges. First, the long link structure is cumbersome, and order generation involves multiple departments and interface calls, with a high degree of coupling. Second, there are many interception rules, and each system has its own independently maintained rules. Configuration modifications and upstream and downstream asynchrony may lead to process blockages.

[0003] However, the commonly used methods of constructing test data in the prior art have the following problems. For example, manually generating test data based on business processes is purely manual processing, which is complex and inefficient; generating test data by executing SQL statements is difficult to ensure that business rules and data consistency requirements are met, and the reuse rate is low; generating test data by backing up and restoring production data often involves customer sensitive information and does not meet security control requirements; generating test data by calling interfaces has a complex operation process and high development costs. In this context, there is an urgent need for efficient and stable construction methods to generate various detailed and accurate data. Summary of the invention

[0004] The embodiments of the present invention provide a test data construction method, device, equipment and medium to solve the problem that the test data construction link is long and has many interception rules that cannot be solved in the prior art.

[0005] A test data construction method, comprising:

[0006] Obtain target information data corresponding to the current test account to determine the current process stage, and determine a first data pool corresponding to the current process stage; the first data pool includes historical test data that conforms to the current process stage;

[0007] When it is determined that the first data pool does not include historical test data corresponding to the target information data, obtaining a number-making script corresponding to the current process stage, and obtaining initial data from a second data pool corresponding to a process stage previous to the current process stage;

[0008] The initial data and the target information data are constructed by the number-generating script to recycle the historical data corresponding to each test account to obtain the test data corresponding to the current process stage; the historical data includes the historical test data in the first data pool and the initial data in the second data pool;

[0009] Performing process verification on the test data through a target process corresponding to the current process stage to obtain a process verification result;

[0010] When the test data corresponding to the process verification result is verified according to the target information data, it is confirmed that the test data construction is completed, and the test data is fed back to the current test account and stored in the first data pool.

[0011] A test data construction device, comprising:

[0012] The stage data module is used to obtain target information data corresponding to the current test account to determine the current process stage, and determine a first data pool corresponding to the current process stage; the first data pool includes historical test data that conforms to the current process stage;

[0013] a number-generating script module, configured to obtain a number-generating script corresponding to the current process stage when it is determined that the first data pool does not include historical test data corresponding to the target information data, and to obtain initial data from a second data pool corresponding to a process stage previous to the current process stage;

[0014] A data construction module is used to construct data on the initial data and the target information data through the number creation script, so as to recycle the historical data corresponding to each test account to obtain the test data corresponding to the current process stage; the historical data includes the historical test data in the first data pool and the initial data in the second data pool;

[0015] A data verification module, used to perform process verification on the test data through a target process corresponding to the current process stage to obtain a process verification result;

[0016] The construction completion module is used to confirm that the construction of the test data is completed when the test data corresponding to the process verification result is verified according to the target information data, and feed back the test data to the current test account and store it in the first data pool.

[0017] A computer device comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor is used to execute the test data construction method.

[0018] A computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the test data construction method is implemented.

[0019] The above-mentioned test data construction method, device, equipment and medium, the present invention reduces the number-making time and improves the number-making efficiency by splitting the original process into different stages. Through the target information data input by the account, the process stage of the order is determined, and then the first data pool of the current process stage is obtained. When the target information data is not included in the first data pool, the number-making script for the current process stage is implemented, and then the initial data in the second data pool of the previous process stage is obtained. The number-making script constructs the initial data and the target information data, and the construction of the test data is realized, thereby realizing the verification of the test data and the acquisition of the process verification results, improving the success rate of number-making, and then realizing the feedback of the test data to the current test account and storing it in the first data pool, which facilitates the recycling of the test data. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.

[0021] Figure 1 is a flow chart of a test data construction method in one embodiment of the present invention;

[0022] Figure 2 is a flow chart of step S30 of the test data construction method in one embodiment of the present invention;

[0023] Figure 3 is a flow chart of step S40 of the test data construction method in one embodiment of the present invention;

[0024] Figure 4 is a flow chart of step S10 of a test data construction method in one embodiment of the present invention;

[0025] Figure 5 is a flow chart of a test data construction method in another embodiment of the present invention;

[0026] Figure 6 is a flow chart of a test data construction method in yet another embodiment of the present invention;

[0027] Figure 7 is a principle block diagram of a test data construction device in one embodiment of the present invention;

[0028] Figure 8 is a schematic diagram of a computer device in one embodiment of the present invention. DETAILED DESCRIPTION

[0029] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0030] In one embodiment, if Figure 1 As shown, a test data construction method is provided, comprising the following steps:

[0031] S10: Acquire target information data corresponding to the current test account to determine the current process stage, and determine a first data pool corresponding to the current process stage; the first data pool includes historical test data that conforms to the current process stage.

[0032] Understandably, the first data pool includes historical test data that conforms to the current process stage. The current process stage refers to the process stage corresponding to the target information data, such as the financing matching stage, the guarantor review stage, etc. The current test account refers to the currently logged in test account. The target information data refers to the demand information input by the user, such as the repayment demand, etc.

[0033] Specifically, the target information data input by the current test account on the display interface is obtained, and then the target information data is parsed to determine the data content, and the current process stage corresponding to the target information data is identified according to the data content. Then, the first data pool corresponding to the current process stage is matched from all data pools.

[0034] S20: When it is determined that the first data pool does not include historical test data corresponding to the target information data, obtain a number-generating script corresponding to the current process stage, and obtain initial data from a second data pool corresponding to a previous process stage of the current process stage.

[0035] Understandably, a data generation script refers to a script used to generate or simulate a large amount of data, and is used to generate simulated data that conforms to specific rules. Initial data refers to historical test data from the previous process stage.

[0036] Specifically, after obtaining the first data pool, data matching is performed on the target information data and the historical test data in the first data pool to determine whether there is historical test data corresponding to the target information data in the first data pool. Then, when it is determined that the first data pool includes historical test data corresponding to the target information data, the historical test data is extracted and fed back to the display interface of the current test account. When it is determined that the first data pool does not include historical test data corresponding to the target information data, the number-generating script corresponding to the current process stage is found from all number-generating scripts, and then the second data pool corresponding to the previous process stage of the current process stage is obtained, and a historical test data of the previous process stage is selected from the second data pool and determined as the initial data.

[0037] S30: constructing the initial data and the target information data through the number-generating script to recycle the historical data corresponding to each test account to obtain the test data corresponding to the current process stage; the historical data includes the historical test data in the first data pool and the initial data in the second data pool.

[0038] It can be understood that the test data refers to simulated data that is constructed to meet the user's target information data.

[0039] Specifically, after obtaining the number-generating script and the initial data, the initial data and the target information data are constructed through the number-generating script. That is, through the construction capability of the number-generating script, on the basis of the initial data of the previous process stage, simulation data that meets the requirements of the current process stage is constructed according to the target information data, and the constructed simulation data is determined as the test data corresponding to the current process stage, so that the test data corresponding to the target information data can be obtained.

[0040] S40: Performing process verification on the test data through a target process corresponding to the current process stage to obtain a process verification result.

[0041] Understandably, the process verification result refers to the result of whether the test data has been verified by the target process.

[0042] Specifically, the target process corresponding to the current process stage is found from all decoupled processes, and the process verification is performed on the test data through the target process corresponding to the current process stage, that is, the constructed test data is input into the target process to verify whether the test data can pass all the audit nodes of the target process. When the test data passes all the audit nodes, a process verification result is obtained, which indicates that the test data has passed the target process verification. When the audit node of one of the target processes fails, the preset processing method is used, that is, the test data is re-audited a preset number of times after a preset time interval, and the exception information is sent to the preset management party, so as to obtain a process verification result indicating that the test data has not passed the target process verification.

[0043] S50: When the test data corresponding to the process verification result is verified according to the target information data, it is confirmed that the test data construction is completed, and the test data is fed back to the current test account and stored in the first data pool.

[0044] Specifically, the process verification result is tested and confirmed. If the process verification result indicates that the test data has passed the target process verification, the test data corresponding to the process verification result is verified through the target information data, that is, whether the test data meets the requirements of the target information data. When the test data corresponding to the process verification result is verified according to the target information data, it is confirmed that the test data construction is completed, and the test data is fed back to the display interface of the current test account for the user to view, and the test data is stored in the first data pool corresponding to the current process stage. When the test data corresponding to the process verification result is not verified according to the target information data, the verification failure information is sent to the preset management party.

[0045] In the test data construction method of the present invention, by splitting the original process into different stages, the time for number generation is reduced and the efficiency of number generation is improved. The target information data input by the account number is used to determine the process stage of the order, thereby realizing the acquisition of the first data pool of the current process stage. When the target information data is not included in the first data pool, the number generation script for the current process stage is realized, thereby realizing the acquisition of the initial data in the second data pool of the previous process stage. The number generation script is used to perform data construction on the initial data and the target information data, thereby realizing the construction of the test data, thereby realizing the verification of the test data and the acquisition of the process verification results, improving the success rate of number generation, thereby realizing the feedback of the test data to the current test account and storing it in the first data pool, and facilitating the recycling of the test data.

[0046] In one embodiment, if Figure 4 As shown, after step S10, that is, after determining the first data pool corresponding to the current process stage, the following steps are included:

[0047] S101, performing information matching on the requirement information in the target information data and the field information in each historical test data in the first data pool to obtain information matching results corresponding to each historical test data.

[0048] S102: When at least one of the information matching results indicates that the requirement information and the field information are matched successfully, confirm that the first data pool includes historical test data corresponding to the target information data.

[0049] S103: When all the information matching results indicate that the requirement information and the field information fail to match, confirm that the first data pool does not include historical test data corresponding to the target information data.

[0050] Understandably, the demand information refers to the information entered by the user according to the prompt, such as age, job, address, repayment plan, loan amount, etc. The information matching result is used to indicate whether the demand information and field information are matched successfully. Historical test data refers to the simulated data previously constructed and / or pre-set for all test accounts.

[0051] Specifically, after obtaining the first data pool corresponding to the current process stage, the first data pool is queried to see whether there is historical test data that matches the target information data, that is, the requirement information in the target information data and the field information in the historical test data in the first data pool are matched to determine whether the field information matches the requirement information, thereby obtaining information matching results corresponding to each historical test data. Then, all information matching results are checked, and when at least one information matching result indicates that the requirement information and the field information match successfully, that is, the field information of a certain historical test data in the first database meets the requirement information of the target information data, it is confirmed that the first data pool includes historical test data that matches the target information data. When all information matching results indicate that the requirement information and the field information fail to match, that is, the field information of all historical test data in the first database does not meet the requirement information of the target information data, it is confirmed that the first data pool does not include historical test data that matches the target information data.

[0052] In this embodiment, by searching the data required by the user in the first database, the information matching result is obtained. When the match is successful, the data is quickly obtained. When the match fails, it is confirmed that the first data pool includes historical test data that matches the target information data, and it is confirmed that the test data needs to be constructed.

[0053] In one embodiment, if Figure 2As shown, in step S30, the initial data and the target information data are constructed by the number-generating script to recycle the historical data corresponding to each test account to obtain the test data corresponding to the current process stage, including:

[0054] S301, obtaining a verification rule corresponding to the current process stage, and determining whether the target information data and the initial data in the historical data satisfy the verification rule.

[0055] S302, when it is determined that the target information data and the initial data in the historical data satisfy the verification rule, construct test data corresponding to the current process stage for the initial data and the target information data through the number-generating script.

[0056] S303, when it is determined that the target information data and the initial data in the historical data do not satisfy the verification rules, the target information data is updated according to the verification rules to obtain the target data, and test data is constructed for the initial data and the target data through the number-making script.

[0057] Understandably, verification rules refer to the requirements of various rules, such as the limit requirements, exceeding 1 million, risk control review requirements, whether there is repayment ability, etc.

[0058] Specifically, the validation rule corresponding to the current process stage is obtained from all the rules, which may be one validation rule or multiple validation rules. Then, it is determined whether the initial data and the target information data meet the validation rules, that is, the initial data and the target information data are detected according to the validation rules to see whether they meet the specific rule content. Then, when it is determined that the initial data and the target information data meet the validation rules, that is, the information in the initial data and the target information data meets the specific rule content, the simulation data corresponding to the target information data is constructed on the basis of the initial data through the construction ability of the number-making script, and is determined as the test data corresponding to the current process stage, so that the test data that meets the user's needs can be constructed. Further, when it is determined that the initial data and the target information data do not meet the validation rules, the target information data is updated based on the validation rules, that is, the target information data is modified and corrected according to the data range in the validation rules, so that the target information data meets the validation rules, thereby obtaining the target data, and the simulation data corresponding to the target information data is constructed on the basis of the initial data through the construction ability of the number-making script, and is determined as the test data corresponding to the current process stage, that is, the test data that meets the user's needs is constructed.

[0059] In this embodiment, by obtaining the verification rules corresponding to the current process stage and judging whether the initial data and the target information data satisfy the verification rules, a reverse mock based on the verification rules is implemented, thereby ensuring the success rate of number generation, thereby realizing the construction of test data through number generation scripts, and further realizing the recycling of historical test data.

[0060] In one embodiment, if Figure 3 As shown, in the step S40, the test data is subjected to process verification through the target process corresponding to the current stage state to obtain a process verification result, including:

[0061] S401, auditing the data attributes in the test data respectively through all audit nodes in the target process to obtain audit results.

[0062] S402: If the audit result of at least one of the audit nodes indicates that the test data audit has not passed, the test data is re-audited after a preset time interval, and an exception message is sent to a preset management party.

[0063] S403, when the audit results of all the audit nodes indicate that the test data has passed the audit, a process verification result indicating that the test data has passed the verification is obtained.

[0064] Understandably, the audit result is used to indicate whether the test data has passed the audit of each approval node in the target process. The preset time interval refers to the time interval for setting the retest, for example, 15 seconds. The abnormal information refers to the information of the audit node where the test data has not passed.

[0065] Specifically, after obtaining the test data, through the current process stage, the target process corresponding to the current stage state is matched from all preset processes, and then, the data attributes in the test data are audited and processed respectively through all audit nodes in the target process, that is, the test data passes through all audit nodes in the target process in sequence, and the data attributes of the test data are audited according to the audit rules of each audit node. When the current audit node passes the audit, that is, the test data meets the audit rules of the audit node, thereby obtaining an audit result representing that the test data has passed the audit. When the audit of the previous audit node fails, the audit result representing that the test data has failed the audit is obtained. Further, if the audit result of at least one audit node represents that the test data has failed the audit, the test data is re-audited after a preset time interval, that is, according to the exception handling method, the test data is audited again after a preset time, and after a preset number of audits, the exception information is sent to the preset management party to notify the preset management party that the test data is abnormal. When the audit results of all audit nodes represent that the test data has passed the audit, that is, the test data meets all the audit requirements of the target process, thereby obtaining a process verification result representing that the test data has passed the process verification corresponding to the current process stage.

[0066] In this embodiment, all audit nodes in the target process are used to audit the data attributes in the test data, thereby testing the test data and ensuring that the test data can pass the target process, thereby obtaining the process verification result. When the audit result of the audit node indicates that the test data has not passed the audit, the test data is repeatedly tested, thereby notifying the abnormal information.

[0067] In one embodiment, if Figure 5 As shown, the method further includes:

[0068] S601, updating the original data ratio in the first data pool through hotspot data to obtain an updated data pool; the original data ratio refers to the data volume ratio of each type of data.

[0069] S602, monitoring the updated data ratio in the updated data pool, and sending an alarm message to a preset management party when it is detected that the updated data ratio is less than a preset data pool threshold.

[0070] Understandably, hot data refers to data that is frequently acquired or accessed within a certain period of time. The original data ratio refers to the ratio between the various types of data in the first data pool, for example, the ratio of trusted users to untrusted users is 3:7. The updated data pool refers to the data pool after the ratio of each type of data is changed. The preset management party refers to the management personnel of the data pool. The preset data pool threshold refers to the threshold of the ratio of each type of data in the data pool. The updated data ratio refers to the ratio of each data type in the updated data pool.

[0071] Specifically, the data acquired or accessed by the user is integrated and analyzed according to a preset time period to obtain hot data. Then, the original data ratio in the first data pool is updated through the hot data, that is, the proportion of hot data in the first data pool is increased, and the proportion of non-hot data (that is, data that is acquired or accessed less) in the first data pool is reduced, so as to obtain an updated data pool; the original data ratio refers to the data volume ratio of each type of data. Next, the updated data ratio in the updated data pool is monitored, that is, the updated data ratio of each type of data in the updated data pool is regularly compared with the preset data pool threshold. When it is monitored that the updated data ratio is less than the preset data pool threshold, that is, the ratio of each type of data in the first data pool is unbalanced, an alarm message is sent to the preset management party to adjust the updated data ratio in the first data pool. Among them, the data pools corresponding to other process stages are regularly updated and monitored using the above method.

[0072] In this embodiment, the original data ratio in the first data pool is updated through hot data, so that the adjustment of various types of data in the data pool is achieved, ensuring that the data in the first data pool is the data required by the user, thereby improving the efficiency of number generation.

[0073] In one embodiment, if Figure 6 As shown, the method further includes:

[0074] S70, periodically releasing the stage test data of the current test account, and performing verification processing on the stage test data according to the verification rule to obtain a data verification result; the stage test data refers to the test data of different process stages in the current test account.

[0075] S80, when the data verification result indicates that the stage test data verification fails, performing data repair on the stage test data according to a preset repair rule to obtain complete data, and storing the complete data in the first data pool.

[0076] S90, when it is confirmed through the preset recycling rule evaluation that the complete data does not meet the requirements, the current test account is recycled, and all stage test data on the current test account are deleted.

[0077] Understandably, stage test data refers to the test data of different process stages in the current test account. The data verification result is used to indicate whether the stage test data has passed the verification. Complete data refers to the data that can pass the verification rules after data repair.

[0078] Specifically, the stage test data on the current test account is released regularly, and all the stage test data on the current test account are released according to the preset time. Then, the verification rules of the data reuse module are obtained, and all the stage test data are verified by the verification rules of the data reuse module to determine whether the stage test data meets the verification rules, thereby obtaining the data verification result. When the data verification result indicates that the stage test data meets the verification rules, the stage test data is stored again in the first data pool. Then, when the data verification result indicates that the stage test data verification fails, the stage test data is repaired by the preset repair rules, that is, the content data in the stage test data that does not meet the verification rules is modified according to the preset repair rules, so that the repaired stage test data can pass the verification rules, thereby obtaining complete data, and storing the complete data in the first data pool. For example, in the financing matching stage, if the limit rule does not pass, the amount data is modified so that it passes the limit rule. Further, the preset recycling rules are obtained, and the complete data is evaluated according to the preset recycling rules, that is, the complete data is verified according to the preset recycling rules to determine whether it can pass the verification of the preset recycling rules. When it is confirmed that the complete data does not meet the requirements of the preset recycling rules, the current test account is recycled, and all stage test data on the current test account are deleted according to the requirements of the preset recycling rules. Among them, all other test accounts can be verified, repaired and recycled according to the above process.

[0079] In this embodiment, by periodically releasing the stage test data on the current test account, the test data is recycled and data expansion is avoided. The stage test data is verified by the verification rules to obtain the data verification results, thereby ensuring that the stage test data complies with the reuse rules. The stage test data is repaired by the preset repair rules to obtain the complete data and repair the stage test data. When it is confirmed that the complete data does not meet the requirements, the current test account is recovered to achieve the recycling of the test account and the management of the test account.

[0080] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.

[0081] In one embodiment, a test data construction device is provided, and the test data construction device corresponds one-to-one to the test data construction method in the above embodiment. Figure 7 As shown, the test data construction device includes a phase data module 10, a number-making script module 20, a construction data module 30, a data verification module 40 and a construction completion module 50. Each functional module is described in detail as follows:

[0082] The stage data module 10 is used to obtain target information data corresponding to the current test account to determine the current process stage, and determine a first data pool corresponding to the current process stage; the first data pool includes historical test data that conforms to the current process stage;

[0083] The number-generating script module 20 is used to obtain the number-generating script corresponding to the current process stage when it is determined that the first data pool does not include the historical test data corresponding to the target information data, and obtain the initial data from the second data pool corresponding to the previous process stage of the current process stage;

[0084] A data construction module 30 is used to construct data on the initial data and the target information data through the number-making script, so as to recycle the historical data corresponding to each test account to obtain the test data corresponding to the current process stage; the historical data includes the historical test data in the first data pool and the initial data in the second data pool;

[0085] A data verification module 40 is used to perform process verification on the test data through a target process corresponding to the current process stage to obtain a process verification result;

[0086] The construction completion module 50 is used to confirm that the construction of the test data is completed when the test data corresponding to the process verification result is verified according to the target information data, and feed back the test data to the current test account and store it in the first data pool.

[0087] Optionally, the construction data module 30 includes:

[0088] A data judgment unit, used to obtain a verification rule corresponding to the current process stage, and judge whether the target information data and the initial data in the historical data meet the verification rule;

[0089] A data satisfying unit, configured to construct test data corresponding to the current process stage for the initial data and the target information data by using the number-generating script when it is determined that the initial data in the target information data and the historical data satisfy the verification rule;

[0090] A data updating unit is used to update the target information data according to the verification rules to obtain target data when it is determined that the target information data and the initial data in the historical data do not meet the verification rules, and to construct test data for the initial data and the target data through the number-making script.

[0091] Optionally, the data verification module 40 includes:

[0092] A data audit unit, used to audit the data attributes in the test data through all audit nodes in the target process to obtain an audit result;

[0093] An audit failure unit, configured to re-examine the test data after a preset time interval if the audit result of at least one of the audit nodes indicates that the test data has failed the audit, and send an exception message to a preset management party;

[0094] The audit passing unit is used to obtain a process verification result indicating that the test data has passed the audit when the audit results of all the audit nodes indicate that the test data has passed the audit.

[0095] Optionally, the stage data module 10 includes:

[0096] An information matching unit, used for matching the demand information in the target information data with the field information in each historical test data in the first data pool, and obtaining an information matching result corresponding to each historical test data;

[0097] A matching success unit, configured to confirm that the first data pool includes historical test data corresponding to the target information data when at least one of the information matching results indicates that the requirement information and the field information are matched successfully;

[0098] The matching failure unit is used to confirm that the first data pool does not include historical test data corresponding to the target information data when all the information matching results indicate that the requirement information and the field information fail to match.

[0099] Optionally, the device further comprises:

[0100] An update processing unit, used to update the original data ratio in the first data pool through hotspot data to obtain an updated data pool; the original data ratio refers to the data volume ratio of each type of data;

[0101] The data ratio unit is used to monitor the updated data ratio in the updated data pool, and send an alarm message to a preset management party when it is detected that the updated data ratio is less than a preset data pool threshold.

[0102] Optionally, the device further comprises:

[0103] A verification processing unit, used for periodically releasing the stage test data of the current test account, and performing verification processing on the stage test data according to the verification rules to obtain a data verification result; the stage test data refers to the test data of different process stages in the current test account;

[0104] A data repair unit, configured to repair the stage test data by using a preset repair rule to obtain complete data when the data verification result indicates that the stage test data verification fails, and store the complete data in the first data pool;

[0105] The account recovery unit is used to recover the current test account and delete all stage test data on the current test account when it is confirmed through a preset recovery rule evaluation that the complete data does not meet the requirements.

[0106] This application further provides Figure 8 A computer device is shown, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor is used to execute the test data construction method.

[0107] The specific definition of the computer device, processor and its units and modules can be found in the above definition of the test data construction method, which will not be repeated here. Each module in the above processor can be implemented in whole or in part by software, hardware and a combination thereof. Understandably, the processor includes a processor, a memory, a network interface and a database connected by a device bus. Each module of the processor can be embedded in or independent of the processor in hardware form, or can be stored in the memory in software form, so that the processor calls and executes the operations corresponding to the above modules. Among them, the processor is used to provide computing and control capabilities. The memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating device, a computer program and a database. The internal memory provides an environment for the operation of the operating device and the computer program in the non-volatile storage medium. The database is used to store the data used by the test data construction method in the above embodiment. The network interface is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a test data construction method is implemented.

[0108] In one embodiment, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the test data construction method described above is implemented.

[0109] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

[0110] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0111] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included in the protection scope of the present invention.

Claims

1. A test data construction method, characterized in that: include: Acquire target information data corresponding to the current test account to determine the current process stage, and determine a first data pool corresponding to the current process stage; The first data pool includes historical test data that matches the current process stage; When it is determined that the first data pool does not include historical test data corresponding to the target information data, obtaining a number-generating script corresponding to the current process stage, and obtaining initial data from a second data pool corresponding to a process stage previous to the current process stage; The initial data and the target information data are constructed by the number-generating script to recycle the historical data corresponding to each test account to obtain the test data corresponding to the current process stage; the historical data includes the historical test data in the first data pool and the initial data in the second data pool; Performing process verification on the test data through a target process corresponding to the current process stage to obtain a process verification result; When the test data corresponding to the process verification result is verified according to the target information data, it is confirmed that the test data construction is completed, and the test data is fed back to the current test account and stored in the first data pool.

2. The test data construction method according to claim 1, characterized in that: The data construction of the initial data and the target information data by the number-generating script to recycle the historical data corresponding to each test account to obtain the test data corresponding to the current process stage includes: Acquire the validation rules corresponding to the current process stage, and determine whether the target information data and the initial data in the historical data satisfy the validation rules; When it is determined that the target information data and the initial data in the historical data satisfy the verification rule, constructing test data corresponding to the current process stage for the initial data and the target information data through the number-generating script; When it is determined that the target information data and the initial data in the historical data do not satisfy the verification rules, the target information data is updated according to the verification rules to obtain the target data, and test data is constructed for the initial data and the target data through the number-making script.

3. The test data construction method according to claim 1, characterized in that: The process verification of the test data is performed through the target process corresponding to the stage data to obtain the process verification result, including: Auditing the data attributes in the test data through all audit nodes in the target process to obtain audit results; If the audit result of at least one of the audit nodes indicates that the test data audit has not passed, the test data is re-audited after a preset time interval, and an abnormality message is sent to a preset management party; When the audit results of all the audit nodes indicate that the test data has passed the audit, a process verification result indicating that the test data has passed the verification is obtained.

4. The test data construction method according to claim 1, characterized in that: After determining the first data pool corresponding to the current process stage, the method includes: Performing information matching on the demand information in the target information data and the field information in each historical test data in the first data pool to obtain information matching results corresponding to each historical test data; When at least one of the information matching results indicates that the requirement information and the field information are successfully matched, confirming that the first data pool includes historical test data corresponding to the target information data; When all the information matching results indicate that the requirement information and the field information fail to match, it is confirmed that the first data pool does not include historical test data corresponding to the target information data.

5. The test data construction method according to claim 1, characterized in that: The method further comprises: The original data ratio in the first data pool is updated by using hotspot data to obtain an updated data pool; the original data ratio refers to the data volume ratio of each type of data; The updated data ratio in the updated data pool is monitored, and when it is detected that the updated data ratio is less than a preset data pool threshold, an alarm message is sent to a preset management party.

6. The test data construction method according to claim 1, characterized in that: The method further comprises: Periodically releasing the stage test data of the current test account, and performing verification processing on the stage test data according to the verification rules to obtain data verification results; the stage test data refers to the test data of different process stages in the current test account; When the data verification result indicates that the stage test data verification fails, data repair is performed on the stage test data according to a preset repair rule to obtain complete data, and the complete data is stored in the first data pool; When it is confirmed through the preset recycling rule evaluation that the complete data does not meet the requirements, the current test account is recycled and all stage test data on the current test account are deleted.

7. A test data construction device, characterized in that: include: A stage data module, used to obtain target information data corresponding to the current test account to determine the current process stage, and determine a first data pool corresponding to the current process stage; The first data pool includes historical test data that matches the current process stage; a number-generating script module, configured to obtain a number-generating script corresponding to the current process stage when it is determined that the first data pool does not include historical test data corresponding to the target information data, and to obtain initial data from a second data pool corresponding to a process stage previous to the current process stage; A data construction module is used to construct data on the initial data and the target information data through the number creation script, so as to recycle the historical data corresponding to each test account to obtain the test data corresponding to the current process stage; the historical data includes the historical test data in the first data pool and the initial data in the second data pool; A data verification module, used to perform process verification on the test data through a target process corresponding to the current process stage to obtain a process verification result; The construction completion module is used to confirm that the construction of the test data is completed when the test data corresponding to the process verification result is verified according to the target information data, and feed back the test data to the current test account and store it in the first data pool.

8. The test data construction device according to claim 7, characterized in that: The construction data module comprises: A data judgment unit, used to obtain a verification rule corresponding to the current process stage, and judge whether the target information data and the initial data in the historical data meet the verification rule; A data satisfying unit, configured to construct test data corresponding to the current process stage for the initial data and the target information data by using the number-generating script when it is determined that the initial data in the target information data and the historical data satisfy the verification rule; A data updating unit is used to update the target information data according to the verification rules to obtain target data when it is determined that the target information data and the initial data in the historical data do not meet the verification rules, and to construct test data for the initial data and the target data through the number-making script.

9. A computer device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor is used to execute the test data construction method according to any one of claims 1 to 6.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the test data construction method according to any one of claims 1 to 6 is implemented.