CN110134592A - A kind of method and device of supplementary data field, electronic equipment - Google Patents

A kind of method and device of supplementary data field, electronic equipment Download PDF

Info

Publication number
CN110134592A
CN110134592A CN201910317817.4A CN201910317817A CN110134592A CN 110134592 A CN110134592 A CN 110134592A CN 201910317817 A CN201910317817 A CN 201910317817A CN 110134592 A CN110134592 A CN 110134592A
Authority
CN
China
Prior art keywords
field
absent
data
value
default
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910317817.4A
Other languages
Chinese (zh)
Inventor
覃逢思
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Puhui Enterprise Management Co Ltd
Original Assignee
Ping An Puhui Enterprise Management Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Puhui Enterprise Management Co Ltd filed Critical Ping An Puhui Enterprise Management Co Ltd
Priority to CN201910317817.4A priority Critical patent/CN110134592A/en
Publication of CN110134592A publication Critical patent/CN110134592A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management

Abstract

The present invention relates to software testing technology fields, disclose method and device, the electronic equipment of a kind of supplementary data field.The described method includes: detecting endless integer field existing for the data that user inputs in each operation flow node, it is labeled as absent field;Detect the field type of absent field;The field type includes business relevant field and process relevant field;It is that absent field is automatically filled in numerical value according to service fields rule if absent field is business relevant field;The service fields rule includes the corresponding default assignment rule of attribute of different business relevant field;If absent field is process relevant field, default default value is automatically filled in for absent field, it is that endless integer field is automatically filled in numerical value by script, without finding the respective modules of endless integer field, numerical value is input to respective modules again, the process of field supplement can be simplified, reduce the time of supplementary data field, to save the time for generating data.

Description

A kind of method and device of supplementary data field, electronic equipment
Technical field
The present invention relates to software testing technology field, in particular to a kind of method and device of supplementary data field, electronics Equipment.
Background technique
Software product publication before, need to construct a large amount of test data, for test environment to software product into Row test, only by test, software product could be issued online.In general, completing the construction of complete set test data, not only It is related to the interaction of internal multiple systems, it is also necessary to interact with multiple external affiliated parties, process is extremely complex.
The modular script write using Jmeter testing tool can generate the different business stage in different modules Data.Script is found when determining the field that it is required supplementation with by script for the incomplete data information of user's input Corresponding module, after entering data into corresponding module, can just obtain a complete data.But when incomplete data are believed When the field that breath requires supplementation with is more, the process of supplemental field can become more many and diverse, need to consume the excessive time.
Summary of the invention
In order to solve the problems, such as that supplemental field present in the relevant technologies needs to consume the excessive time, the present invention provides one The method and device of kind supplementary data field, electronic equipment.
First aspect of the embodiment of the present invention discloses a kind of method of supplementary data field, which comprises
Endless integer field existing for the data that user inputs in each operation flow node is detected, absent field is labeled as;
Detect the field type of the absent field;The field type includes business relevant field and process related words Section;
It is that the absent field is automatically filled according to service fields rule if the absent field is business relevant field Numerical value;The service fields rule includes the corresponding default assignment rule of attribute of different business relevant field;
If the absent field is process relevant field, default default value is automatically filled in for the absent field.
As an alternative embodiment, in first aspect of the embodiment of the present invention, each operation flow of detection Endless integer field existing for the data that user inputs in node is labeled as absent field, comprising:
Field value is filtered out in the data that each operation flow node inputs from the user do not meet preset format want The aiming field asked;
When the field value for detecting the aiming field is empty, the aiming field is labeled as the first absent field; And it is less than in the length that the field value for detecting the aiming field is not field value that is empty and detecting the aiming field pre- If when field value length, the aiming field is labeled as the second absent field;
The absent field is obtained according to first absent field and/or second absent field.
As an alternative embodiment, in first aspect of the embodiment of the present invention, the detection absent field Field type, comprising:
Identify the identifier of the absent field;The identifier is that the key assignments based on data field carries out classification acquisition The identifier of field type;
The field type of the absent field is determined according to the identifier of the absent field.
As an alternative embodiment, in first aspect of the embodiment of the present invention, if the absent field It is business relevant field, is that the absent field is automatically filled in numerical value according to service fields rule, comprising:
If the absent field is business relevant field, the key assignments of the absent field is extracted, and according to the missing The key assignments of field identifies the attribute of the absent field;
Default assignment rule corresponding with the attribute of the absent field is searched in the service fields rule;
It is that the absent field is automatically filled in numerical value according to the corresponding default assignment rule of the attribute of the absent field.
As an alternative embodiment, in first aspect of the embodiment of the present invention, if the absent field It is process relevant field, is automatically filled in default default value for the absent field, comprising:
If the absent field is process relevant field, the entire fields of the data of user input are divided Analysis, determines the content between the process relevant field in the process relevant field and the endless integer field of the entire fields Corresponding relationship;
Default default value is chosen according to the content corresponding relationship, and is automatically filled in described preset for the absent field and writes from memory Recognize value.
As an alternative embodiment, in first aspect of the embodiment of the present invention, in each Business Stream of detection Endless integer field existing for the data that user inputs in Cheng Jiedian, is labeled as after absent field and the detection is described scarce Before the field type for losing field, the method also includes:
The application odd numbers of user is extracted from the data that the user inputs;One application odd numbers indicates described in one The operation information of user;
It is inquired in the database according to the application odd numbers with the presence or absence of storage information corresponding with the application odd numbers;
If it does, extracting the data field value of the storage information, and according to the data field value of the storage information The absent field is supplemented;
If it does not, the step of executing the field type of the detection absent field.
As an alternative embodiment, in first aspect of the embodiment of the present invention, the method also includes:
Replace what user described in each operation flow node inputted using the data field value of the storage information is corresponding The field value of entire fields in data.
Second aspect of the embodiment of the present invention discloses a kind of device of supplementary data field, and described device includes:
First detection unit, for detecting imperfect word existing for the data that user inputs in each operation flow node Section is labeled as absent field;
Second detection unit, for detecting the field type of the absent field;The field type includes business correlation Field and process relevant field;
First filling unit, for being institute according to service fields rule when the absent field is business relevant field It states absent field and is automatically filled in numerical value;The service fields rule includes the corresponding default tax of attribute of different business relevant field Value rule;
Second filling unit, for being filled out automatically for the absent field when the absent field is process relevant field Enter default default value.
The third aspect of the embodiment of the present invention discloses a kind of electronic equipment, and the electronic equipment includes:
Processor;
Memory is stored with computer-readable instruction on the memory, and the computer-readable instruction is by the processing When device executes, a kind of method of supplementary data field disclosed in first aspect of the embodiment of the present invention is realized.
Fourth aspect of the embodiment of the present invention discloses a kind of computer readable storage medium, stores computer program, institute Stating computer program makes computer execute a kind of method of supplementary data field disclosed in first aspect of the embodiment of the present invention.
The technical solution that the embodiment of the present invention provides can include the following benefits:
A kind of method of supplementary data field provided by the present invention includes the following steps: to detect each operation flow node Endless integer field existing for the data of middle user's input, is labeled as absent field;Detect the field type of absent field;The field Type includes business relevant field and process relevant field;If absent field is business relevant field, advised according to service fields Then numerical value is automatically filled in for absent field;The service fields rule includes the corresponding default tax of attribute of different business relevant field Value rule;If absent field is process relevant field, default default value is automatically filled in for absent field.
Under the method, by detecting endless integer field existing for the data of user's input in each operation flow node, It can be the imperfect word of the data of user's input when generating data using script according to the field type of endless integer field Section is automatically filled in numerical value, a complete data is obtained, for carrying out the test of product, without finding endless integer field Respective modules, then numerical value is input to respective modules can simplify the process of field supplement, reduce supplementary data field when Between, to save the time for generating data.
It should be understood that the above general description and the following detailed description are merely exemplary, this can not be limited Invention.
Detailed description of the invention
The drawings herein are incorporated into the specification and forms part of this specification, and shows and meets implementation of the invention Example, and in specification together principle for explaining the present invention.
Fig. 1 is a kind of structural schematic diagram of device disclosed by the embodiments of the present invention;
Fig. 2 is a kind of flow chart of the method for supplementary data field disclosed by the embodiments of the present invention;
Fig. 3 is the flow chart of the method for another supplementary data field disclosed by the embodiments of the present invention;
Fig. 4 is the flow chart of the method for another supplementary data field disclosed by the embodiments of the present invention;
Fig. 5 is a kind of structural schematic diagram of the device of supplementary data field disclosed by the embodiments of the present invention;
Fig. 6 is the structural schematic diagram of the device of another supplementary data field disclosed by the embodiments of the present invention.
Specific embodiment
Here will the description is performed on the exemplary embodiment in detail, the example is illustrated in the accompanying drawings.Following description is related to When attached drawing, unless otherwise indicated, the same numbers in different drawings indicate the same or similar elements.Following exemplary embodiment Described in embodiment do not represent all embodiments consistented with the present invention.On the contrary, they be only with it is such as appended The example of device and method being described in detail in claims, some aspects of the invention are consistent.
Embodiment one
Implementation environment of the invention can be electronic equipment, such as smart phone, tablet computer, desktop computer.
Fig. 1 is a kind of structural schematic diagram of device disclosed by the embodiments of the present invention.Device 100 can be above-mentioned electronics and set It is standby.As shown in Figure 1, device 100 may include following one or more components: processing component 102, memory 104, power supply module 106, multimedia component 108, audio component 110, sensor module 114 and communication component 116.
The integrated operation of the usual control device 100 of processing component 102, such as with display, telephone call, data communication, phase Machine operation and the associated operation of record operation etc..Processing component 102 may include one or more processors 118 to execute Instruction, to complete all or part of the steps of following methods.In addition, processing component 102 may include one or more modules, For convenient for the interaction between processing component 102 and other assemblies.For example, processing component 102 may include multi-media module, use In to facilitate the interaction between multimedia component 108 and processing component 102.
Memory 104 is configured as storing various types of data to support the operation in device 100.These data are shown Example includes the instruction of any application or method for operating on the device 100.Memory 104 can be by any kind of Volatibility or non-volatile memory device or their combination are realized, such as static random access memory (Static Random Access Memory, abbreviation SRAM), electrically erasable programmable read-only memory (Electrically Erasable Programmable Read-Only Memory, abbreviation EEPROM), Erasable Programmable Read Only Memory EPROM (Erasable Programmable Read Only Memory, abbreviation EPROM), programmable read only memory (Programmable Red- Only Memory, abbreviation PROM), read-only memory (Read-Only Memory, abbreviation ROM), magnetic memory, flash Device, disk or CD.It is also stored with one or more modules in memory 104, is configured to for the one or more module It is executed by the one or more processors 118, to complete all or part of step in method as follows.
Power supply module 106 provides electric power for the various assemblies of device 100.Power supply module 106 may include power management system System, one or more power supplys and other with for device 100 generate, manage, and distribute the associated component of electric power.
Multimedia component 108 includes the screen of one output interface of offer between device 100 and user.In some realities It applies in example, screen may include liquid crystal display (Liquid Crystal Display, abbreviation LCD) and touch panel.If Screen includes touch panel, and screen may be implemented as touch screen, to receive input signal from the user.Touch panel includes One or more touch sensors are to sense the gesture on touch, slide, and touch panel.Touch sensor can be sensed not only The boundary of a touch or slide action, but also detect duration and pressure relevant to touch or slide.Screen may be used also To include display of organic electroluminescence (Organic Light Emitting Display, abbreviation OLED).
Audio component 110 is configured as output and/or input audio signal.For example, audio component 110 includes a Mike Wind (Microphone, abbreviation MIC), when device 100 is in operation mode, such as call model, logging mode and speech recognition mould When formula, microphone is configured as receiving external audio signal.The received audio signal can be further stored in memory 104 or via communication component 116 send.In some embodiments, audio component 110 further includes a loudspeaker, for exporting Audio signal.
Sensor module 114 includes one or more sensors, and the state for providing various aspects for device 100 is commented Estimate.For example, sensor module 114 can detecte the state that opens/closes of device 100, the relative positioning of component, sensor group Part 114 can be with the position change of 100 1 components of detection device 100 or device and the temperature change of device 100.Some In embodiment, which can also include Magnetic Sensor, pressure sensor or temperature sensor.
Communication component 116 is configured to facilitate the communication of wired or wireless way between device 100 and other equipment.Device 100 can access the wireless network based on communication standard, such as WiFi (Wireless-Fidelity, Wireless Fidelity).In the present invention In embodiment, communication component 116 receives broadcast singal or broadcast correlation from external broadcasting management system via broadcast channel Information.In embodiments of the present invention, communication component 116 further includes near-field communication (Near Field Communication, abbreviation NFC) module, for promote short range communication.For example, radio frequency identification (Radio Frequency can be based in NFC module Identification, abbreviation RFID) technology, Infrared Data Association (Infrared Data Association, abbreviation IrDA) Technology, ultra wide band (Ultra Wideband, abbreviation UWB) technology, Bluetooth technology and other technologies are realized.
In the exemplary embodiment, device 100 can be by one or more application specific integrated circuit (Application Specific Integrated Circuit, abbreviation ASIC), it is digital signal processor, digital signal processing appts, programmable Logical device, field programmable gate array, controller, microcontroller, microprocessor or other electronic components are realized, for executing Following methods.
Embodiment two
Referring to Fig. 2, Fig. 2 is a kind of flow diagram of the method for supplementary data field disclosed by the embodiments of the present invention. The method of the supplementary data field as shown in Figure 2 may comprise steps of:
201, endless integer field existing for the data of user's input in each operation flow node is detected, labeled as missing word Section.
In the embodiment of the present invention, the script for generating test data at runtime, can be obtained in each operation flow node Then the data inputted to user carry out field value detection to the field of the data of user's input, it is incomplete to obtain field value Field, as endless integer field;The imperfect field value that can be of field value is also possible to field value and lacks at least one for sky Numerical value.Detect that endless integer field present in the data of user's input can be complete to supplement incomplete necessary field, It obtains complete necessary field and supplement foundation is provided.
202, the field type of absent field is detected;Field type includes business relevant field and process relevant field.
For example, the necessary field in process of providing a loan is broadly divided into business relevant field and process relevant field, industry Business relevant field may include money-lender's name, gender, identification card number, bank's card number, the amount of the loan and property ownership certificate number etc., process Whether relevant field may include whether spouse, whether has had joint owner, has and mortgage and whether have simulated bank's examination & approval etc..
It 203, is that absent field is automatically filled in number according to service fields rule when absent field is business relevant field Value;Service fields rule includes the corresponding default assignment rule of attribute of different business relevant field.
In the embodiment of the present invention, corresponding default assignment rule can be chosen according to the attribute of absent field, according to correspondence Default assignment rule generate the field value of absent field, and the field value of absent field is added to the position where absent field It sets, suitable field value can be generated according to the attribute of absent field, avoid the survey for generating inappropriate field value influence product Examination.
204, when absent field is process relevant field, default default value is automatically filled in for absent field.
In the embodiment of the present invention, the field value of process relevant field will affect operation flow node branch, if user It does not fill in, the script for generating test data can generate complete survey with the default default value in process relevant field imparting script Try data;If user has the field value of fill flow path relevant field, the field value that script can be filled in using user is generated complete Test data.
It is understood that when script generates test data since first operation flow node, at this time first The field value of user data fields existing for a operation flow node is all sky, when null field is business relevant field, root It is automatically filled in numerical value for null field according to service fields rule, or is blank word when null field is process relevant field Section is automatically filled in default default value, can generate a complete test data in this way for carrying out the test of product.
As it can be seen that implement method described in Fig. 2, the number that can be inputted by detecting user in each operation flow node It,, can be defeated for user when generating data using script according to the field type of endless integer field according to existing endless integer field The endless integer field of the data entered is automatically filled in numerical value, obtains a complete data, for carrying out the test of product, without The respective modules of endless integer field are found, then numerical value is input to respective modules, the process of field supplement can be simplified, are reduced The time of supplementary data field, to save the time for generating data.
Embodiment three
Referring to Fig. 3, Fig. 3 is the process signal of the method for another supplementary data field disclosed by the embodiments of the present invention Figure.As shown in figure 3, the method for the supplementary data field may comprise steps of:
301, field value is filtered out in the data that each operation flow node inputs from user do not meet preset format want The aiming field asked.
In the embodiment of the present invention, when being tested using test data product, field value is not met in test data The field that preset format requires may interfere the test of product.Therefore, field value preset format requirement is not met into Aiming field screened from the data that user inputs, the field value that can exclude not meeting preset format requirement is to product The interference of test.
302, when the field value for detecting aiming field is empty, aiming field is labeled as the first absent field;And The field value for detecting aiming field is not the length of field value that is empty and detecting aiming field less than predetermined word segment value length When, aiming field is labeled as the second absent field.
For example, when the field stored in database is shown as " NULL ", indicate that the field value of the field, can for sky With by the field mark be the first absent field;The presetting digit capacity of identification card number is 18, when storing identification card number in database Field field value be 16 when, at this time store identification card number field field value length be less than predetermined word segment value it is long The field mark of the storage identification card number can be the second absent field by degree.
303, absent field is obtained according to the first absent field and/or the second absent field.
As an alternative embodiment, the field value of the data of detection user's input whether there is spcial character, than Such as " & ", "? " Deng if it does, the storage meaning between the key assignments and field value of analysis field;If storing meaning indicates word Segment value error, the field mark by field value error are absent field.Implement the embodiment, can be avoided due to field value Spcial character error causes to malfunction during product test, improves the efficiency of product test.
304, the identifier of absent field is identified;Identifier is the field that the key assignments based on data field carries out classification acquisition The identifier of type.
305, the field type of absent field is determined according to the identifier of absent field.
In the embodiment of the present invention, the key assignments of data field is used to indicate which type of data is the field store, for example, data When the key assignments of field is bank's card number, indicate field storage is bank's card number of user.Therefore, according to the key of data field Value classifies to field, field can be divided into business relevant field and process relevant field, and enclose identifier for field, Therefore, the field type of field can be determined according to the identifier of field.
306, when absent field is business relevant field, the key assignments of absent field is extracted, and according to the key of absent field Value identifies the attribute of absent field.
307, default assignment rule corresponding with the attribute of absent field is searched in service fields rule.
It 308, is that absent field is automatically filled in numerical value according to the corresponding default assignment rule of the attribute of absent field.
It is understood that being found out corresponding with creditor's name when the attribute of absent field indicates creditor's name Default assignment rule, which can are as follows: constructs surname Candidate Set according to One Hundred Family Names, constructs name according to dictionary vocabulary and wait Selected works, set the project to be counted of each element in surname Candidate Set and name Candidate Set, and calculate the system of the project to be counted of each element Evaluation, the project to be counted based on setting generate name building rule, choose each element that statistical value meets name building rule Name is constructed, a name is obtained, then inserts the name of acquisition to the absent field of creditor's name, it can be in missing word Suitable field value is inserted in section.
309, when absent field is process relevant field, the entire fields of the data of user's input are analyzed, really Make the content corresponding relationship between the process relevant field in the process relevant field and endless integer field of entire fields.
310, default default value is chosen according to content corresponding relationship, and is automatically filled in default default value for absent field.
As an example it is assumed that when the field value for " whether having spouse " in the process relevant field of entire fields is "Yes", root Should be "Yes" according to the field value that the field value can extrapolate absent field " whether having joint owner ", therefore, "Yes" can be inserted to The absent field.
Optionally, can also according to the process relevant field in the business relevant fields of entire fields and endless integer field it Between content corresponding relationship choose default default value, if " spouse's name " is complete word in the business relevant field of entire fields Duan Shi, and " whether having spouse " be absent field when, can be inferred to " whether have and match according to the content corresponding relationship of the two Field value occasionally " should be "Yes", then, can insert "Yes" to the absent field.
It, can be by detecting user inputs in each operation flow node number as it can be seen that method described in implementing Fig. 3 According to existing endless integer field, when generating data using script, if endless integer field is business relevant field, according to default Assignment rule is that endless integer field is automatically filled in numerical value, if endless integer field is process relevant field, according to the default of selection Default value is that endless integer field is automatically filled in numerical value, a complete data is obtained, for carrying out the test of product, without looking into The respective modules of endless integer field are found, then are entered data into respective modules, the process of field supplement can be simplified, reduces and mends The time of data field is filled, to save the time for generating data.
Example IV
Referring to Fig. 4, Fig. 4 is the process signal of the method for another supplementary data field disclosed by the embodiments of the present invention Figure.The method of the supplementary data field as shown in Figure 4 may comprise steps of:
401, endless integer field existing for the data of user's input in each operation flow node is detected, labeled as missing word Section.
402, the application odd numbers of user is extracted from the data that user inputs;One application odd numbers indicates the behaviour of a user Make information.
In the embodiment of the present invention, the application odd numbers of user, only one Shen of user can all occur in each operation of user Please odd numbers, can be referred to the identity information of user, can will apply the field of odd numbers as tag field in the database.
403, it is inquired in the database according to application odd numbers with the presence or absence of storage information corresponding with application odd numbers;If It is to execute step 404~step 405;If not, executing step 406~step 408.
404, the data field value of storage information is extracted, and absent field is carried out according to the data field value of storage information Supplement.
405, the corresponding data for replacing user's input in each operation flow node of the data field value of storage information are utilized In entire fields field value.
In the embodiment of the present invention, the priority level of script value are as follows: the priority for the numerical value that database extracts, which is higher than, to be used The numerical value of family input, the priority of the numerical value of user's input are higher than the numerical value that script is automatically filled in, can be taken by three of the above Value method generates a complete test data.
406, the field type of absent field is detected;Field type includes business relevant field and process relevant field.
It 407, is that absent field is automatically filled in number according to service fields rule when absent field is business relevant field Value;Service fields rule includes the corresponding default assignment rule of attribute of different business relevant field.
408, when absent field is process relevant field, default default value is automatically filled in for absent field.
As it can be seen that implement method described in Fig. 4, the number that can be inputted by detecting user in each operation flow node It,, can be defeated for user when generating data using script according to the field type of endless integer field according to existing endless integer field The endless integer field of the data entered is automatically filled in numerical value, obtains a complete data, for carrying out the test of product, without The respective modules of endless integer field are found, then numerical value is input to respective modules, the process of field supplement can be simplified, are reduced The time of supplementary data field, to save the time for generating data;Additionally it is possible to there is application odd numbers pair in the database When the storage information answered, endless integer field is supplemented according to the data field value of storage information, guarantee test data has Effect property.
Embodiment five
Referring to Fig. 5, Fig. 5 is a kind of structural schematic diagram of the device of supplementary data field disclosed by the embodiments of the present invention. As shown in figure 5, the device of the supplementary data field may include: first detection unit 501, second detection unit 502, first fill out Enter unit 503 and the second filling unit 504, wherein
First detection unit 501, it is imperfect existing for the data that user inputs in each operation flow node for detecting Field is labeled as absent field.
In the embodiment of the present invention, the script for generating test data at runtime, can be obtained in each operation flow node Then the data inputted to user carry out field value detection to the field of the data of user's input, it is incomplete to obtain field value Field, as endless integer field;The imperfect field value that can be of field value is also possible to field value and lacks at least one for sky Numerical value.Detect that endless integer field present in the data of user's input can be complete to supplement incomplete necessary field, It obtains complete necessary field and supplement foundation is provided.
Second detection unit 502, for detecting the field type of absent field;Field type include business relevant field and Process relevant field.
For example, the necessary field in process of providing a loan is broadly divided into business relevant field and process relevant field, industry Business relevant field may include money-lender's name, gender, identification card number, bank's card number, the amount of the loan and property ownership certificate number etc., process Whether relevant field may include whether spouse, whether has had joint owner, has and mortgage and whether have simulated bank's examination & approval etc..
First filling unit 503, for being missing according to service fields rule when absent field is business relevant field Field is automatically filled in numerical value;Service fields rule includes the corresponding default assignment rule of attribute of different business relevant field.
In the embodiment of the present invention, corresponding default assignment rule can be chosen according to the attribute of absent field, according to correspondence Default assignment rule generate the field value of absent field, and the field value of absent field is added to the position where absent field It sets, suitable field value can be generated according to the attribute of absent field, avoid the survey for generating inappropriate field value influence product Examination.
Second filling unit 504, for being automatically filled in for absent field default when absent field is process relevant field Default value.
In the embodiment of the present invention, the field value of process relevant field will affect operation flow node branch, if user It does not fill in, the script for generating test data can generate complete survey with the default default value in process relevant field imparting script Try data;If user has the field value of fill flow path relevant field, the field value that script can be filled in using user is generated complete Test data.
It is understood that when script generates test data since first operation flow node, at this time first The field value of user data fields existing for a operation flow node is all sky, and the first filling unit 503 is used in null field It is that null field is automatically filled in numerical value or the second filling unit 504 is used according to service fields rule when being business relevant field In when null field is process relevant field, be automatically filled in default default value for null field, can generate in this way one it is complete Whole test data is used to carry out the test of product.
As it can be seen that implement the device of supplementary data field described in Fig. 5, it can be by detecting each operation flow node Endless integer field existing for the data of middle user's input is generating data using script according to the field type of endless integer field When, it can be automatically filled in numerical value for the endless integer field of the data of user's input, a complete data be obtained, for being produced The test of product without finding the respective modules of endless integer field, then enters data into respective modules, can simplify field The process of supplement, reduces the time of supplementary data field, to save the time for generating data.
Embodiment six
Referring to Fig. 6, Fig. 6 is the structural representation of the device of another supplementary data field disclosed by the embodiments of the present invention Figure.The device of supplementary data field shown in fig. 6 is that the device of supplementary data field as shown in Figure 5 optimizes. Compared with the device of supplementary data field shown in fig. 5, the device of supplementary data field shown in fig. 6 can also include: to mention Take unit 505, query unit 506, supplementary units 507 and replacement unit 508, wherein
First detection unit 501 is used to detect imperfect word existing for the data that user inputs in each operation flow node Section, labeled as the mode of absent field specifically:
First detection unit 501, for filtering out field value in the data that each operation flow node inputs from user The aiming field of preset format requirement is not met;
When the field value for detecting aiming field is empty, aiming field is labeled as the first absent field;And it is detecting It, will when field value to aiming field is not that the length of field value that is empty and detecting aiming field is less than predetermined word segment value length Aiming field is labeled as the second absent field;
Absent field is obtained according to the first absent field and/or the second absent field.
In the embodiment of the present invention, when being tested using test data product, field value is not met in test data The field that preset format requires may interfere the test of product.Therefore, field value preset format requirement is not met into Aiming field screened from the data that user inputs, the field value that can exclude not meeting preset format requirement is to product The interference of test.
For example, when the field stored in database is shown as " NULL ", indicate that the field value of the field, can for sky With by the field mark be the first absent field;The presetting digit capacity of identification card number is 18, when storing identification card number in database Field field value be 16 when, at this time store identification card number field field value length be less than predetermined word segment value it is long The field mark of the storage identification card number can be the second absent field by degree.
As an alternative embodiment, the field value of the data of detection user's input whether there is spcial character, than Such as " & ", "? " Deng if it does, the storage meaning between the key assignments and field value of analysis field;If storing meaning indicates word Segment value error, the field mark by field value error are absent field.Implement the embodiment, can be avoided due to field value Spcial character error causes to malfunction during product test, improves the efficiency of product test.
Second detection unit 502 is used to detect the mode of the field type of absent field specifically:
Second detection unit 502, for identification identifier of absent field;Identifier be the key assignments based on data field into The identifier for the field type that row classification obtains;
The field type of absent field is determined according to the identifier of absent field.
In the embodiment of the present invention, the key assignments of data field is used to indicate which type of data is the field store, for example, data When the key assignments of field is bank's card number, indicate field storage is bank's card number of user.Therefore, according to the key of data field Value classifies to field, field can be divided into business relevant field and process relevant field, and enclose identifier for field, Therefore, the field type of field can be determined according to the identifier of field.
First filling unit 503 is used for when absent field is business relevant field, is missing according to service fields rule Field is automatically filled in the mode of numerical value specifically:
First filling unit 503, for extracting the key assignments of absent field when absent field is business relevant field, and The attribute of absent field is identified according to the key assignments of absent field;
Default assignment rule corresponding with the attribute of absent field is searched in service fields rule;
It is that absent field is automatically filled in numerical value according to the corresponding default assignment rule of the attribute of absent field.
It is understood that the first filling unit 503 is for searching when the attribute of absent field indicates creditor's name Default assignment rule corresponding with creditor's name out, which can are as follows: constructs surname Candidate Set, root according to One Hundred Family Names Name Candidate Set is constructed according to dictionary vocabulary, sets the project to be counted of each element in surname Candidate Set and name Candidate Set, and calculates each member The statistical value of the project to be counted of element, the project to be counted based on setting generate name building rule, choose statistical value and meet surname The each element of name building rule constructs name, obtains a name, and the name of acquisition is then inserted lacking to creditor's name Field is lost, suitable field value can be inserted in absent field.
Second filling unit 504 is used for when absent field is process relevant field, is automatically filled in for absent field default The mode of default value specifically:
Second filling unit 504, for when absent field is process relevant field, to the complete of the data of user's input Field is analyzed, and is determined interior between the process relevant field in the process relevant field and endless integer field of entire fields Hold corresponding relationship;
Default default value is chosen according to content corresponding relationship, and is automatically filled in default default value for absent field.
As an example it is assumed that when the field value for " whether having spouse " in the process relevant field of entire fields is "Yes", root Should be "Yes" according to the field value that the field value can extrapolate absent field " whether having joint owner ", therefore, "Yes" can be inserted to The absent field.
Optionally, can also according to the process relevant field in the business relevant fields of entire fields and endless integer field it Between content corresponding relationship choose default default value, if " spouse's name " is complete word in the business relevant field of entire fields Duan Shi, and " whether having spouse " be absent field when, can be inferred to " whether have and match according to the content corresponding relationship of the two Field value occasionally " should be "Yes", then, can insert "Yes" to the absent field.
Extraction unit 505, for extracting the application odd numbers of user from the data that user inputs;One application odd numbers instruction The operation information of one user.
In the embodiment of the present invention, the application odd numbers of user, only one Shen of user can all occur in each operation of user Please odd numbers, can be referred to the identity information of user, can will apply the field of odd numbers as tag field in the database.
Query unit 506, for according to application odd numbers inquire in the database with the presence or absence of with apply for that odd numbers is corresponding deposits Store up information;
Supplementary units 507 when for there is storage information corresponding with application odd numbers in the database, extract storage information Data field value, and according to storage information data field value absent field is supplemented;
Replacement unit 508 is used for corresponding replace in each operation flow node of the data field value using storage information The field value of entire fields in the data of family input.
In the embodiment of the present invention, the priority level of script value are as follows: the priority for the numerical value that database extracts, which is higher than, to be used The numerical value of family input, the priority of the numerical value of user's input are higher than the numerical value that script is automatically filled in, can be taken by three of the above Value method generates a complete test data.
Second detection unit 502 is also used to detect there is no when storage information corresponding with application odd numbers in the database The field type of absent field.
As it can be seen that implement the device of supplementary data field described in Fig. 6, it can be by detecting each operation flow node Endless integer field existing for the data of middle user's input, when generating data using script, if endless integer field is business phase Field is closed, is that endless integer field is automatically filled in numerical value according to default assignment rule, if endless integer field is process relevant field, It is that endless integer field is automatically filled in numerical value according to the default default value of selection, a complete data is obtained, for carrying out product Test, without finding the respective modules of endless integer field, then enter data into respective modules, field benefit can be simplified The process filled, reduces the time of supplementary data field, to save the time for generating data;Additionally it is possible in the database When storage information corresponding in the presence of application odd numbers, endless integer field is supplemented according to the data field value of storage information, is protected Demonstrate,prove the validity of test data.
The present invention also provides a kind of electronic equipment, which includes:
Processor;
Memory is stored with computer-readable instruction on the memory, when which is executed by processor, The method for realizing a kind of supplementary data field as previously shown.
The electronic equipment can be Fig. 1 shown device 100.
In one exemplary embodiment, the present invention also provides a kind of computer readable storage mediums, are stored thereon with calculating Machine program, when which is executed by processor, the method for realizing a kind of supplementary data field as previously shown.
It should be understood that the present invention is not limited to the precise structure already described above and shown in the accompanying drawings, and And various modifications and change can executed without departing from the scope.The scope of the present invention is limited only by the attached claims.

Claims (10)

1. a kind of method of supplementary data field, which is characterized in that the described method includes:
Endless integer field existing for the data that user inputs in each operation flow node is detected, absent field is labeled as;
Detect the field type of the absent field;The field type includes business relevant field and process relevant field;
It is that the absent field is automatically filled in number according to service fields rule if the absent field is business relevant field Value;The service fields rule includes the corresponding default assignment rule of attribute of different business relevant field;
If the absent field is process relevant field, default default value is automatically filled in for the absent field.
2. the method according to claim 1, wherein user's input in each operation flow node of detection Endless integer field existing for data is labeled as absent field, comprising:
Field value, which is filtered out, in the data that each operation flow node inputs from the user does not meet preset format requirement Aiming field;
When the field value for detecting the aiming field is empty, the aiming field is labeled as the first absent field;And The field value for detecting the aiming field is not the length of field value that is empty and detecting the aiming field less than predetermined word When segment value length, the aiming field is labeled as the second absent field;
The absent field is obtained according to first absent field and/or second absent field.
3. method according to claim 1 or 2, which is characterized in that the field type of the detection absent field, packet It includes:
Identify the identifier of the absent field;The identifier is the field that the key assignments based on data field carries out classification acquisition The identifier of type;
The field type of the absent field is determined according to the identifier of the absent field.
If 4. according to the method described in claim 3, it is characterized in that, the absent field is business relevant field, It is that the absent field is automatically filled in numerical value according to service fields rule, comprising:
If the absent field is business relevant field, the key assignments of the absent field is extracted, and according to the absent field Key assignments identify the attribute of the absent field;
Default assignment rule corresponding with the attribute of the absent field is searched in the service fields rule;
It is that the absent field is automatically filled in numerical value according to the corresponding default assignment rule of the attribute of the absent field.
If 5. according to the method described in claim 3, it is characterized in that, the absent field is process relevant field, Default default value is automatically filled in for the absent field, comprising:
If the absent field is process relevant field, the entire fields of the data of user input are analyzed, really The content made between the process relevant field of the entire fields and the process relevant field in the endless integer field is corresponding Relationship;
Default default value is chosen according to the content corresponding relationship, and is automatically filled in the default default for the absent field Value.
6. described in any item methods according to claim 1~5, which is characterized in that in each operation flow node of detection Endless integer field existing for the data of middle user input, labeled as after absent field and the detection absent field Field type before, the method also includes:
The application odd numbers of user is extracted from the data that the user inputs;One application odd numbers indicates a user Operation information;
It is inquired in the database according to the application odd numbers with the presence or absence of storage information corresponding with the application odd numbers;
If it does, extracting the data field value of the storage information, and according to the data field value of the storage information to institute Absent field is stated to be supplemented;
If it does not, the step of executing the field type of the detection absent field.
7. according to the method described in claim 6, it is characterized in that, the method also includes:
Utilize the corresponding data for replacing the input of user described in each operation flow node of data field value of the storage information In entire fields field value.
8. a kind of device of supplementary data field, which is characterized in that described device includes:
First detection unit, for detecting endless integer field existing for the data that user inputs in each operation flow node, mark It is denoted as absent field;
Second detection unit, for detecting the field type of the absent field;The field type includes business relevant field With process relevant field;
First filling unit, for being described lack according to service fields rule when the absent field is business relevant field It loses field and is automatically filled in numerical value;The service fields rule includes the corresponding default assignment rule of the attribute of different business relevant field Then;
Second filling unit, for being automatically filled in for the absent field pre- when the absent field is process relevant field If default value.
9. a kind of electronic equipment, including memory and processor, the memory are stored with computer program, which is characterized in that The step of processor realizes method according to any one of claims 1 to 7 when executing the computer program.
10. a kind of computer readable storage medium, which is characterized in that it stores computer program, and the computer program makes Computer perform claim requires 1~7 a kind of described in any item methods of supplementary data field.
CN201910317817.4A 2019-04-19 2019-04-19 A kind of method and device of supplementary data field, electronic equipment Pending CN110134592A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910317817.4A CN110134592A (en) 2019-04-19 2019-04-19 A kind of method and device of supplementary data field, electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910317817.4A CN110134592A (en) 2019-04-19 2019-04-19 A kind of method and device of supplementary data field, electronic equipment

Publications (1)

Publication Number Publication Date
CN110134592A true CN110134592A (en) 2019-08-16

Family

ID=67570520

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910317817.4A Pending CN110134592A (en) 2019-04-19 2019-04-19 A kind of method and device of supplementary data field, electronic equipment

Country Status (1)

Country Link
CN (1) CN110134592A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111008191A (en) * 2019-10-30 2020-04-14 深圳震有科技股份有限公司 Completion method and device for database query and computer equipment
CN112101870A (en) * 2020-09-19 2020-12-18 炬星科技(深圳)有限公司 Method and equipment for acquiring physical information and computer readable storage medium
CN113377653A (en) * 2021-06-10 2021-09-10 北京京东振世信息技术有限公司 Method and device for generating test case
CN114187060A (en) * 2021-12-10 2022-03-15 北京金堤科技有限公司 Method and device for determining data of home enterprise
CN114531696A (en) * 2020-11-23 2022-05-24 维沃移动通信有限公司 Method and device for processing partial input missing of AI (Artificial Intelligence) network
CN114564759A (en) * 2022-04-28 2022-05-31 睿至科技集团有限公司 Distributed data detection method and system

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106844781A (en) * 2017-03-10 2017-06-13 广州视源电子科技股份有限公司 The method and device of data processing
CN108153789A (en) * 2016-12-02 2018-06-12 航天星图科技(北京)有限公司 A kind of transaction platform data processing method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108153789A (en) * 2016-12-02 2018-06-12 航天星图科技(北京)有限公司 A kind of transaction platform data processing method
CN106844781A (en) * 2017-03-10 2017-06-13 广州视源电子科技股份有限公司 The method and device of data processing

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111008191A (en) * 2019-10-30 2020-04-14 深圳震有科技股份有限公司 Completion method and device for database query and computer equipment
CN111008191B (en) * 2019-10-30 2023-08-11 深圳震有科技股份有限公司 Completion method and device for database query and computer equipment
CN112101870A (en) * 2020-09-19 2020-12-18 炬星科技(深圳)有限公司 Method and equipment for acquiring physical information and computer readable storage medium
CN114531696A (en) * 2020-11-23 2022-05-24 维沃移动通信有限公司 Method and device for processing partial input missing of AI (Artificial Intelligence) network
CN113377653A (en) * 2021-06-10 2021-09-10 北京京东振世信息技术有限公司 Method and device for generating test case
CN113377653B (en) * 2021-06-10 2023-09-26 北京京东振世信息技术有限公司 Method and device for generating test cases
CN114187060A (en) * 2021-12-10 2022-03-15 北京金堤科技有限公司 Method and device for determining data of home enterprise
CN114564759A (en) * 2022-04-28 2022-05-31 睿至科技集团有限公司 Distributed data detection method and system
CN114564759B (en) * 2022-04-28 2022-07-29 睿至科技集团有限公司 Distributed data detection method and system

Similar Documents

Publication Publication Date Title
CN110134592A (en) A kind of method and device of supplementary data field, electronic equipment
CN104714949A (en) Method for customizing report dynamically
CN103200293A (en) Method of automatically combining tautonomy contacts in process of guiding contacts into contact list
US20180204170A1 (en) Storage location assignment device and method for a storage system
CN101882135B (en) Data processing method and device
CN109359236A (en) Target user's method for digging and device based on big data analysis
CN111951052B (en) Method and device for acquiring potential clients based on knowledge graph
CN110276382A (en) Listener clustering method, apparatus and medium based on spectral clustering
CN109542956A (en) Report form generation method, device, computer equipment and storage medium
CN102346925B (en) Electronic ticket storage equipment, electronic ticket checking system and method
CN110019111A (en) Data processing method, device, storage medium and processor
CN107391535A (en) The method and device of document is searched in document application
CN109033427A (en) The screening technique and device of stock, computer equipment and readable storage medium storing program for executing
CN107729330B (en) Method and apparatus for acquiring data set
CN110232156B (en) Information recommendation method and device based on long text
CN112463986A (en) Information storage method and device
CN106649210A (en) Data conversion method and device
CN104407699A (en) Human-computer interaction method, device and system
CN112069269B (en) Big data and multidimensional feature-based data tracing method and big data cloud server
CN114240672A (en) Method for identifying green asset proportion and related product
CN110363206B (en) Clustering of data objects, data processing and data identification method
US10410095B2 (en) Method and system for identifying a payment card design
CN109857967A (en) Report method for subscribing and system based on big data
CN104839962B (en) A kind of intelligent wallet and its information processing method and device
US20140324918A1 (en) Database Generation System, Method For Generating A Database, Product Line Management System And Non-Transitory Data Carrier

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 201, room 518000, building A, No. 1, front Bay Road, Qianhai Shenzhen Guangdong Shenzhen Hong Kong cooperation zone (Qianhai business secretary)

Applicant after: Pingan Pu Hui Enterprise Management Co., Ltd.

Address before: 518000 Guangdong city of Shenzhen province Qianhai Shenzhen Hong Kong cooperation zone before Bay Road No. 1 building 201 room A

Applicant before: Pingan Pu Hui Enterprise Management Co., Ltd.

SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination