Nothing Special   »   [go: up one dir, main page]

CN111427789B - Method, device, computer equipment and storage medium for automatically verifying rule - Google Patents

Method, device, computer equipment and storage medium for automatically verifying rule Download PDF

Info

Publication number
CN111427789B
CN111427789B CN202010224113.5A CN202010224113A CN111427789B CN 111427789 B CN111427789 B CN 111427789B CN 202010224113 A CN202010224113 A CN 202010224113A CN 111427789 B CN111427789 B CN 111427789B
Authority
CN
China
Prior art keywords
rule
verification
user
interface
generating
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.)
Active
Application number
CN202010224113.5A
Other languages
Chinese (zh)
Other versions
CN111427789A (en
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 Medical and Healthcare Management Co Ltd
Original Assignee
Ping An Medical and Healthcare 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 Medical and Healthcare Management Co Ltd filed Critical Ping An Medical and Healthcare Management Co Ltd
Priority to CN202010224113.5A priority Critical patent/CN111427789B/en
Publication of CN111427789A publication Critical patent/CN111427789A/en
Application granted granted Critical
Publication of CN111427789B publication Critical patent/CN111427789B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

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
    • 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/3696Methods or tools to render software testable

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The application discloses a method, a device, computer equipment and a storage medium for automatically verifying rules, wherein the method comprises the following steps: the method comprises the steps that a foreground system receives a plurality of rule components called by a user from a preset visual rule component library; generating a corresponding first rule according to a logical operator set between each rule component by a user; automatically presenting a preset verification rule interface on the foreground system page, wherein the verification rule interface is an interface for data transmission; sending the first rule to a background testing end through the verification rule interface, wherein the background testing end is used for verifying the first rule; and receiving the verification result of the background test end. According to the method and the device, when the first rule is verified, the user does not need to copy the rule through storage equipment such as a U disk and then find a developer to verify the rule, or send the mail to the developer, and therefore the working efficiency of the user is improved.

Description

Method, apparatus, computer device and storage medium for automatically verifying rules
Technical Field
The present application relates to the field of computers, and in particular, to a method, an apparatus, a computer device, and a storage medium for automatically validating rules.
Background
The rule engine can strip a large amount of service logic configuration from the service code, thereby obviously reducing the difficulty of realizing the service logic; at the same time, low coupling is maintained with the business system, enabling fast and low cost updates of the business system.
The visual rule engine developed based on drools, a user can easily realize the definition and modification of complex business rules based on a browser, the working efficiency and the learning cost of business personnel are greatly improved, the developers are released from the business, and the productivity is improved. However, for a user using the system, although the rule can be defined and used conveniently and quickly without the participation of technical personnel, a humanized rule creation platform based on a BS architecture and a real-time rule verification test tool are absent in the industry at present, and whether the defined rule is legal or not and whether the rule is really the logic envisaged by the user can be fed back to the user. If the user needs to verify whether the created rule is correct or not, the created rule needs to be sent to a developer in a form of a U disk or an email and verified by the developer, so that the working efficiency of the user is greatly reduced.
Disclosure of Invention
The application mainly aims to provide a method, a device, a computer device and a storage medium for automatically verifying a rule, and aims to solve the technical problem that a user cannot quickly verify the rule created by the user.
In order to achieve the above object, the present application provides a method for automatically verifying a rule, including:
the method comprises the steps that a foreground system receives a plurality of rule components called by a user from a preset visual rule component library;
generating a corresponding first rule according to a logical operator set between each rule component by a user;
automatically presenting a preset verification rule interface on the foreground system page, wherein the verification rule interface is an interface for data transmission;
sending the first rule to a background testing end through the verification rule interface, wherein the background testing end is used for verifying the first rule;
and receiving a verification result of the background test end.
Further, after the step of receiving the verification result of the background test end, the method includes:
when the verification result is failure, analyzing whether the verification result is accompanied by idle information of the background test end;
if yes, generating an option whether to communicate with the background test end for a user to select;
and if a command that the user selects the communication is received, initiating the voice communication to the background testing end.
Further, before the step of sending the first rule to the background test end through the validation rule interface, the method includes:
converting the first rule into a corresponding first MVEL expression;
the step S4 of sending the first rule to the background test end through the validation rule interface includes:
and sending the first MVEL expression to a background test end through the verification rule interface.
Further, before the step of sending the first rule to the background test end through the validation rule interface, the method includes:
generating preset options of a verification scheme, wherein the options of the verification scheme comprise a quick test option and a full path test option;
and receiving the selected verification scheme of the user, and attaching a corresponding verification scheme label to the first rule.
Further, the step of generating the options of the preset verification scheme is preceded by:
collecting the appointed information of the user;
judging whether the user has the authority to verify the first rule or not through the specified information;
if yes, generating options of the verification scheme;
and if not, not generating the option of the verification scheme.
Further, the specified information is face information; the step of collecting the specified information of the user includes:
the foreground system acquires a camera list which can be called, wherein the camera list records the position information and the shooting range of the camera;
determining one or more effective cameras according to the position information and the shooting range of the cameras, wherein the effective cameras are positioned within a specified distance threshold value between the position information and the position of the foreground system, and the shooting range comprises the cameras of the foreground system;
controlling each effective camera to shoot the picture of the position of the foreground system to obtain first images shot by different effective cameras;
intercepting a first face image corresponding to the foreground system display screen area in each first image, and detecting the definition and the face integrity of each first face image;
and determining a final second face image according to the definition and the face integrity of each face image, and taking the second face image as the designated information.
Further, the step of generating the options of the preset verification scheme is preceded by:
judging whether each rule component and the logic operator in the first rule carry a specified verification-free identifier or not;
if yes, not generating options of the verification scheme;
and if not, generating options of the verification scheme.
The present application further provides an apparatus for automatically validating rules, comprising:
the system comprises a calling unit, a display unit and a display unit, wherein the calling unit is used for a foreground system to receive a plurality of rule components called by a user from a preset visual rule component library;
the generating unit is used for generating a corresponding first rule according to a logical operator set between each rule component by a user;
the presentation unit is used for automatically presenting a preset verification rule interface on the foreground system page, wherein the verification rule interface is an interface for data transmission;
the sending unit is used for sending the first rule to a background testing end through the verification rule interface, wherein the background testing end is used for verifying the first rule;
and the receiving unit is used for receiving the verification result of the background testing end.
The present application further provides a computer device comprising a memory and a processor, the memory storing a computer program, the processor implementing the steps of any of the above methods when executing the computer program.
The present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, carries out the steps of the method of any of the above.
According to the method, the device, the computer equipment and the storage medium for automatically verifying the rules, when the method is executed, the verification rule interface is arranged on the execution engine of the foreground system, the first rules created by the user can be directly sent to the corresponding background test end for verification, the user does not need to copy the rules through storage equipment such as a U disk and then find developers for rule verification, or send mails to the developers, and therefore the working efficiency of the user is improved. Similarly, the developer does not need to connect the storage device such as the USB flash disk and the like to read the rule created by the user, and the workload of the developer is saved.
Drawings
FIG. 1 is a flow chart illustrating a method for automatically validating rules according to an embodiment of the present application;
FIG. 2 is a block diagram illustrating an exemplary structure of an apparatus for automatically validating rules according to an embodiment of the present application;
FIG. 3 is a block diagram illustrating a computer device according to an embodiment of the present invention.
The implementation, functional features and advantages of the objectives of the present application will be further explained with reference to the accompanying drawings.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
Referring to fig. 1, an embodiment of the present application provides a method for automatically verifying a rule, including the steps of:
s1, the foreground system receives a plurality of rule components called by a user from a preset visualization rule component library;
s2, generating a corresponding first rule according to a logical operator set by a user among the rule components;
s3, automatically presenting a preset verification rule interface on the foreground system page, wherein the verification rule interface is an interface for data transmission;
s4, sending the first rule to a background testing end through the verification rule interface, wherein the background testing end is used for verifying the first rule;
and S5, receiving the verification result of the background test end.
As described in step S1, the foreground system is one end of the user operation. The visual rule component library is a database for storing the rule components with set logics, and is presented on a page of a foreground system, and after the visual rule component library is opened, a user can visually see the rule components, the names of the rule components and the like. Furthermore, after the cursor moves to a certain rule component, the corresponding description is called from the preset rule component description library and is presented at the cursor, so that the user can know the function of the rule component designated by the cursor conveniently. When the cursor is moved away, the corresponding description automatically disappears.
As described in step S2, the logical operators represent different symbols of the running logic, which are also visually arranged in the preset logical operator library, and different operation logics are generated by connecting different logical operators to two rule elements. The first rule is generally stored in the form of json data, which stores basic information and logical information of the rule.
As described in the foregoing steps S3 and S4, the validation rule interface is a data transmission interface connected to the background test end, and as long as the user selects to invoke the validation rule interface, the first rule is sent to the corresponding background test end for rule validation, and the first rule is accompanied by a corresponding URL (Uniform Resource Locator), so as to facilitate the original path of the background test end to feed back the test validation result. In an embodiment of the present application, the background test end is generally managed by a developer, and after receiving the first rule, the developer can quickly call the corresponding test data, so as to complete the test on the first rule. After the user creates the first rule, the user needs to use storage tools such as a USB flash disk and the like to store the rule data, and then finds developers to test, so that the efficiency and timeliness of the rule verification are greatly improved.
As described in step S5, the verification result is displayed on the interface of the foreground system. The verification result includes verification pass, verification failure and the like. If the verification fails, the reason for the failure is also presented, and the like.
In an embodiment, after the step S5 of receiving the verification result of the background test end, the method includes:
s6, when the verification result is failure, analyzing whether the verification result is accompanied by idle information of the background test terminal;
s7, if yes, generating an option whether to communicate with the background test end for the user to select;
and S8, if a command that the user selects to talk is received, initiating a voice call to the background test end.
In this embodiment, the verification result includes two types, namely verification pass and verification failure, and if the verification pass, it indicates that the first rule created by the user can be used, and the user can use the first rule to perform corresponding rule processing; if the verification fails, it indicates that the first rule created by the user has a problem, and since the user is not a professional in software development, the user cannot know why the creation failed, and even if the verification failed with a failure reason, the user cannot understand the failure, in this application, when the verification result is a failure, the background test end attaches information on whether the background test end is idle to the verification result. The background test end is idle, which means that the background test end does not verify other second rules, and idle information of the background test end can be automatically attached to a verification result or can be actively attached to the verification result by developers of the background test end. When the background testing end is judged to be idle, it is shown that a developer corresponding to the background testing end has time to communicate with the user, so that an option of whether to communicate with the background testing end is provided, if necessary, the communication is selected, and if the user can clearly see the failure reason, the communication is abandoned. Specifically, the option is presented in a highlight manner on the interface of the foreground system, and the presentation time is a preset time length, such as 5 seconds.
In an embodiment, before the step S4 of sending the first rule to the background testing end through the validation rule interface, the method includes:
s401, converting the first rule into a corresponding first MVEL expression;
the step S4 of sending the first rule to the background testing end through the validation rule interface includes:
s41, sending the first MVEL expression to a background testing end through the verification rule interface.
In the present embodiment, the first rule is not directly verified, but the first rule is now converted into a first MVEL (MVFLEX Expression Language, which is an abbreviation of dynamic/static embeddable Expression Language and a Language that provides Runtime for the Java platform) Expression. The reason for converting into the first MVEL expression is that the MVEL supports attribute expressions, boolean expressions, method calls, function definitions, and the like, so that the rules created by the user need to be converted into MVEL expressions and the like through the analysis engine. Further, when the first MVEL expression is sent to the background testing end, the first MVEL expression is split, for example, the first MVEL expression is ((a + B) > C) & & D | E |, F, and is split into three expressions and two operators: 1. (A + B) > C; 2. d; 3. e, F; 4. and &; 5. |.
In an embodiment, before the step S4 of sending the first rule to the background testing end through the validation rule interface, the method includes:
s402, generating options of a preset verification scheme, wherein the options of the verification scheme comprise a quick test option and a full path test option;
s403, receiving the selected verification scheme of the user, and attaching a corresponding verification scheme label to the first rule.
In this embodiment, the test scheme corresponding to the fast test option is as follows: and finding out random generated test data for true conditions according to a plurality of expressions, quickly completing the test, and finally providing test message data and URL for page test. The test scheme corresponding to the full path test option is as follows: generating full-path-coverage test data according to the condition that the expressions are true, testing whether the rule meets expected logic in all directions, and finally providing test message data for page testing of excel documents and URLs. The option of providing the preset verification scheme is convenient for the user to select, and the user selects the applicable test scheme according to the requirement.
In an embodiment, before the step S402 of generating the options of the preset verification scheme, the method includes:
s4021, acquiring the designated information of the user;
s4022, judging whether the user has the authority to verify the first rule or not through the specified information;
s4023, if yes, generating an option of the verification scheme;
s4024, if not, not generating the option of the verification scheme.
In this embodiment, the background test end needs to manage the developer, and in order to reduce unnecessary workload of the developer, the identity of the user is verified, only the user with the right can start the verification function of the first rule, and the user without the right cannot verify the first rule. Specifically, after installing the function application of the automatic verification rule, the foreground system needs to register an account number and then sets the authority for the registered account number, the specified information may be one or more of face feature information, voiceprint feature information and the like, and when the specified information is multiple, the authority verification can be considered to be passed if one passes the verification. For example, some foreground systems are only provided with a camera and no microphone, and at this time, authority authentication of face features and the like can be performed only. The setting of the authority can prevent the operation of a non-working user from affecting developers, for example, an office computer of the user is brought back to home, because the system is a visual system, children in the home can operate the system as a game, and at the moment, if the operation succeeds to obtain the first rule, the first rule does not need to be verified, so the verification of the first rule is automatically filtered through the authority management, and unnecessary work of the developers is reduced. It should be noted that, if the option of the verification scheme is not generated, the verification of the first rule is stopped, that is, the first rule is not sent to the background test end through the verification rule interface for verification.
In one embodiment, the specifying information is face information; the step S4021 of acquiring the specific information of the user includes:
s40211, the foreground system acquires a callable camera list, wherein the camera list records the position information and the shooting range of the camera;
s40212, determining one or more effective cameras according to the position information and the shooting range of the cameras, wherein the effective cameras are that the position distance between the position information and the foreground system is within a specified distance threshold value, and the shooting range comprises the cameras of the foreground system;
s40213, controlling the effective cameras to shoot the pictures of the positions of the foreground system to obtain first images shot by different effective cameras;
s4024, intercepting first face images corresponding to the foreground system display screen area in each first image, and detecting the definition and the face integrity of each first face image;
s4025, determining a final second face image according to the definition and the face integrity of each face image, and taking the second face image as the designated information.
In this embodiment, instead of acquiring the face image through the front-facing camera of the foreground system and directly using the face image, the face image with high definition and high face integrity is selected from a plurality of pictures shot by each effective camera. Specifically, a first face image with the face integrity meeting a preset requirement is selected from a plurality of first face images, and then a face image with the highest definition is selected from the first face images with the face integrity meeting the requirement as a second face image, so that the accuracy of later-stage face verification is improved.
In another embodiment, before the step S402 of generating the options of the preset verification scheme, the method includes:
judging whether each rule component and the logic operator in the first rule carry a specified verification-free identifier or not;
if yes, not generating options of the verification scheme;
and if not, generating options of the verification scheme.
In this embodiment, some rule components in the visualization rule component library are common rule components, and some common logic operators are also present in the same logic operators, and after the common rule components and the common logic operators are combined to form the first rule, the first rule does not have the problems of unclear logic and incoordination, so that the first rule does not need to be verified, so as to save the workload of a background testing end and the workload of corresponding developers. The common rule components and the common logical operators are provided with verification-free identifiers, when all the rule components selected by a user are common rule components and all the logical operators are common rule operators, the first rule does not make a mistake, or the probability of making a mistake is extremely low or slight, so that verification is not needed. And as long as one rule component or logic operator does not carry the verification-free identifier, the corresponding first rule needs to be verified so as to prevent the first rule from being directly used and causing errors. It should be noted that, if the option of the verification scheme is not generated, the verification of the first rule is stopped, that is, the first rule is not sent to the background test end through the verification rule interface for verification.
According to the method for automatically verifying the rules, the verification rule interface is arranged on the execution engine of the foreground system, the first rules created by the user can be directly sent to the corresponding background test end for verification, the user does not need to copy the rules through storage equipment such as a U disk and then find developers for rule verification, or mails are sent to the developers, and therefore working efficiency of the user is improved. Similarly, the developer does not need to connect the storage device such as the USB flash disk and the like to read the rule created by the user, and the workload of the developer is saved.
Referring to fig. 2, an embodiment of the present application further provides an apparatus for automatically verifying a rule, including:
the system comprises a calling unit 10, a display unit and a display unit, wherein the calling unit is used for a foreground system to receive a plurality of rule components called by a user from a preset visual rule component library;
a generating unit 20, configured to generate a corresponding first rule according to a logical operator set by a user between each rule component;
the presentation unit 30 is configured to automatically present a preset validation rule interface on the foreground system page, where the validation rule interface is an interface for data transmission;
a sending unit 40, configured to send the first rule to a background testing end through the validation rule interface, where the background testing end is configured to validate the first rule;
a receiving unit 50, configured to receive a verification result of the background testing end.
In an embodiment, the apparatus for automatically verifying rules further includes:
the analysis unit is used for analyzing whether the verification result is attached with the idle information of the background test terminal or not when the verification result is failed;
the option generating unit is used for generating an option whether to communicate with the background testing terminal for a user to select if the verification result is accompanied by the idle information of the background testing terminal;
and the call unit is used for initiating voice call to the background test end if a command that the user selects the call is received.
In an embodiment, the apparatus for automatically verifying a rule includes:
the conversion unit is used for converting the first rule into a corresponding first MVEL expression;
the above-mentioned sending unit, including: and the sending module is used for sending the first MVEL expression to a background testing end through the verification rule interface.
In an embodiment, the apparatus for automatically verifying rules includes:
the system comprises an option generation unit, a verification unit and a verification unit, wherein the option generation unit is used for generating options of a preset verification scheme, and the options of the verification scheme comprise a quick test option and a full path test option;
and the receiving selection unit is used for receiving the selected verification scheme of the user and attaching a corresponding verification scheme label to the first rule.
Further, the apparatus for automatically verifying rules further includes:
the acquisition unit is used for acquiring the specified information of the user;
an authority verification unit configured to determine whether the user has an authority to verify the first rule through the designation information;
and the first execution unit is used for generating the option of the verification scheme if the verification scheme exists, or else, not generating the option of the verification scheme.
In one embodiment, the specified information is face information; the acquisition unit includes:
the acquisition module is used for the foreground system to acquire a callable camera list, wherein the camera list records the position information and the shooting range of the camera;
the determining module is used for determining one or more effective cameras according to the position information and the shooting range of the cameras, wherein the effective cameras are positioned within a specified distance threshold value between the position information and the foreground system, and the shooting range contains the cameras of the foreground system;
the shooting module is used for controlling the effective cameras to shoot the pictures of the positions of the foreground system to obtain first images shot by different effective cameras;
the intercepting detection module is used for intercepting first face images corresponding to the display screen area of the foreground system in each first image and detecting the definition and the human face integrity of each first face image;
and the selection module is used for determining a final second face image according to the definition and the face integrity of each face image and taking the second face image as the designated information.
In an embodiment, the apparatus for automatically verifying rules further includes:
a carrying detection unit, configured to determine whether each rule component and the logical operator in the first rule carry a specified verification-free identifier;
a second execution unit, configured to not generate an option of the verification scheme if the verification scheme is not generated; otherwise, generating the option of the verification scheme.
The above units, modules, sub-modules, etc. are all devices for executing the test method of the system code, and therefore, a description thereof will not be provided.
Referring to fig. 3, a computer device is also provided in the embodiment of the present application, where the computer device may be the management server described above, or a server corresponding to a management node, and its internal structure may be as shown in fig. 3. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the computer designed processor is used to provide computational and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used for storing data of various components and the like. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a method of automatically validating rules.
The method for executing the automatic validation rule by the processor comprises the following steps: the method comprises the steps that a foreground system receives a plurality of rule components called by a user from a preset visual rule component library; generating a corresponding first rule according to a logical operator set between each rule component by a user; automatically presenting a preset verification rule interface on the foreground system page, wherein the verification rule interface is an interface for data transmission; sending the first rule to a background testing end through the verification rule interface, wherein the background testing end is used for verifying the first rule; and receiving a verification result of the background test end.
In one embodiment, after the step of receiving the verification result of the background test end, the method includes: when the verification result is failure, analyzing whether the verification result is accompanied by idle information of the background test terminal; if yes, generating an option whether to communicate with the background test end for a user to select; and if a command that the user selects the communication is received, initiating the voice communication to the background testing end.
In one embodiment, before the step of sending the first rule to the background test end through the validation rule interface, the method includes: converting the first rule into a corresponding first MVEL expression; the step S4 of sending the first rule to the background test end through the validation rule interface includes: and sending the first MVEL expression to a background test end through the verification rule interface.
In one embodiment, before the step of sending the first rule to the background test end through the validation rule interface, the method includes: generating preset options of a verification scheme, wherein the options of the verification scheme comprise a quick test option and a full path test option; and receiving the selected verification scheme of the user, and attaching a corresponding verification scheme label to the first rule.
In one embodiment, the step of generating the options of the preset verification scheme is preceded by: collecting the appointed information of the user; judging whether the user has the authority to verify the first rule or not through the specified information; if yes, generating options of the verification scheme; and if not, not generating the option of the verification scheme.
In one embodiment, the specified information is face information; the step of collecting the specified information of the user includes: the foreground system acquires a callable camera list, wherein the camera list records the position information and the shooting range of the camera; determining one or more effective cameras according to the position information and the shooting range of the cameras, wherein the effective cameras are positioned within a specified distance threshold value between the position information and the position of the foreground system, and the shooting range comprises the cameras of the foreground system; controlling each effective camera to shoot a picture of the position of the foreground system to obtain first images shot by different effective cameras; intercepting a first face image corresponding to the foreground system display screen area in each first image, and detecting the definition and the face integrity of each first face image; and determining a final second face image according to the definition and the face integrity of each face image, and taking the second face image as the designated information.
In one embodiment, the step of generating the options of the preset verification scheme is preceded by: judging whether each rule component and the logic operator in the first rule carry a specified verification-free identifier or not; if yes, not generating options of the verification scheme; and if not, generating options of the verification scheme.
Those skilled in the art will appreciate that the architecture shown in fig. 3 is only a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects may be applied.
According to the computer equipment, when the processor executes the method, the verification rule interface is arranged on the execution engine of the foreground system, the first rule created by the user can be directly sent to the corresponding background test end for verification, the user does not need to copy the rule through storage equipment such as a U disk and the like, and then finds the developer for rule verification, or sends the mail to the developer, and therefore the working efficiency of the user is improved. Similarly, the developer does not need to connect the storage device such as the USB flash disk and the like to read the rule created by the user, and the workload of the developer is saved.
An embodiment of the present application further provides a computer-readable storage medium having a computer program stored thereon, the computer program, when executed by a processor, implementing a method for automatically validating rules, comprising: the method comprises the steps that a foreground system receives a plurality of rule components called by a user from a preset visual rule component library; generating a corresponding first rule according to a logical operator set between each rule component by a user; automatically presenting a preset verification rule interface on the foreground system page, wherein the verification rule interface is an interface for data transmission; sending the first rule to a background testing end through the verification rule interface, wherein the background testing end is used for verifying the first rule; and receiving a verification result of the background test end.
When the processor executes the method, the verification rule interface is arranged on the execution engine of the foreground system, the first rule created by the user can be directly sent to the corresponding background test end for verification, the user does not need to copy the rule through storage equipment such as a U disk and the like and then find a developer for rule verification, or a mail is sent to the developer, and the working efficiency of the user is improved. Similarly, the developer does not need to connect the storage device such as the USB flash disk and the like to read the rule created by the user, and the workload of the developer is saved.
In one embodiment, after the step of receiving the verification result of the background test end, the method includes: when the verification result is failure, analyzing whether the verification result is accompanied by idle information of the background test terminal; if yes, generating an option whether to communicate with the background test end for a user to select; if a command that a user selects to communicate is received, voice communication is initiated to the background testing end.
In one embodiment, before the step of sending the first rule to the background test end through the validation rule interface, the method includes: converting the first rule into a corresponding first MVEL expression; the step S4 of sending the first rule to the background test end through the validation rule interface includes: and sending the first MVEL expression to a background test end through the verification rule interface.
In one embodiment, before the step of sending the first rule to the background test end through the validation rule interface, the method includes: generating preset options of a verification scheme, wherein the options of the verification scheme comprise a quick test option and a full path test option; and receiving the selected verification scheme of the user, and attaching a corresponding verification scheme label to the first rule.
In one embodiment, the step of generating the options of the preset verification scheme is preceded by: collecting the appointed information of the user; judging whether the user has the authority to verify the first rule or not through the specified information; if yes, generating options of the verification scheme; and if not, not generating the option of the verification scheme.
In one embodiment, the specified information is face information; the step of collecting the specified information of the user includes: the foreground system acquires a callable camera list, wherein the camera list records the position information and the shooting range of the camera; determining one or more effective cameras according to the position information and the shooting range of the cameras, wherein the effective cameras are that the position distance between the position information and the foreground system is within a specified distance threshold value, and the shooting range comprises the cameras of the foreground system; controlling each effective camera to shoot the picture of the position of the foreground system to obtain first images shot by different effective cameras; intercepting a first face image corresponding to the foreground system display screen area in each first image, and detecting the definition and the face integrity of each first face image; and determining a final second face image according to the definition and the face integrity of each face image, and taking the second face image as the designated information.
In one embodiment, the step of generating the options of the preset verification scheme is preceded by: judging whether each rule component and the logic operator in the first rule carry a specified verification-free identifier or not; if yes, not generating options of the verification scheme; and if not, generating options of the verification scheme.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium provided herein and used in the examples may 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. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), double-rate SDRAM (SSRSDRAM), Enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and bus dynamic RAM (RDRAM).
The above description is only a preferred embodiment of the present application, and not intended to limit the scope of the present application, and all modifications of equivalent structures and equivalent processes, which are made by the contents of the specification and the drawings of the present application, or which are directly or indirectly applied to other related technical fields, are also included in the scope of the present application.

Claims (9)

1. A method for automatically validating rules, comprising:
the method comprises the steps that a foreground system receives a plurality of rule components called by a user from a preset visual rule component library;
generating a corresponding first rule according to a logical operator set between each rule component by a user;
automatically presenting a preset verification rule interface on the foreground system page, wherein the verification rule interface is an interface for data transmission;
sending the first rule to a background testing end through the verification rule interface, wherein the background testing end is used for verifying the first rule;
receiving a verification result of the background test end;
when the verification result is failure, analyzing whether the verification result is accompanied by idle information of the background test terminal;
if yes, generating an option whether to communicate with the background test end for a user to select;
and if a command that the user selects the communication is received, initiating the voice communication to the background testing end.
2. The method of automatically validating rules according to claim 1, wherein the step of sending the first rule to a background test end through the validation rule interface is preceded by:
converting the first rule into a corresponding first MVEL expression;
the step S4 of sending the first rule to the background test end through the validation rule interface includes:
and sending the first MVEL expression to a background test end through the verification rule interface.
3. The method of automatically validating rules of claim 2, wherein the step of sending the first rule to a background test end through the validation rule interface is preceded by:
generating preset options of a verification scheme, wherein the options of the verification scheme comprise a quick test option and a full path test option;
and receiving the selected verification scheme of the user, and attaching a corresponding verification scheme label to the first rule.
4. The method of automatically validating rules of claim 3, wherein the step of generating options of the preset validation scheme is preceded by:
collecting the appointed information of the user;
judging whether the user has the authority to verify the first rule or not through the specified information;
if yes, generating options of the verification scheme;
if not, the options of the verification scheme are not generated.
5. The method of automatically validating a rule according to claim 4, wherein the specified information is face information; the step of collecting the specified information of the user includes:
the foreground system acquires a callable camera list, wherein the camera list records the position information and the shooting range of the camera;
determining one or more effective cameras according to the position information and the shooting range of the cameras, wherein the effective cameras are that the position distance between the position information and the foreground system is within a specified distance threshold value, and the shooting range comprises the cameras of the foreground system;
controlling each effective camera to shoot the picture of the position of the foreground system to obtain first images shot by different effective cameras;
intercepting a first face image corresponding to the display screen area of the foreground system from each first image, and detecting the definition and the face integrity of each first face image;
and determining a final second face image according to the definition and the face integrity of each face image, and taking the second face image as the designated information.
6. The method of automatically validating rules according to claim 4, wherein the step of generating the options of the preset validation scheme is preceded by:
judging whether each rule component and the logic operator in the first rule carry a specified verification-free identifier or not;
if yes, not generating options of the verification scheme;
and if not, generating options of the verification scheme.
7. An apparatus for automatically validating rules, comprising:
the system comprises a calling unit, a display unit and a display unit, wherein the calling unit is used for a foreground system to receive a plurality of rule components called by a user from a preset visual rule component library;
the generating unit is used for generating a corresponding first rule according to a logical operator set between each rule component by a user;
the presentation unit is used for automatically presenting a preset verification rule interface on the foreground system page, wherein the verification rule interface is an interface for data transmission;
the sending unit is used for sending the first rule to a background testing end through the verification rule interface, wherein the background testing end is used for verifying the first rule;
the receiving unit is used for receiving the verification result of the background testing end;
the analysis unit is used for analyzing whether the verification result is accompanied with idle information of the background test end or not when the verification result is failed;
the option generating unit is used for generating an option whether to communicate with the background testing end for the user to select if the verification result is accompanied by the idle information of the background testing end;
and the call unit is used for initiating voice call to the background test end if a command that the user selects the call is received.
8. A computer device comprising a memory and a processor, the memory storing a computer program, wherein the processor implements the steps of the method of any one of claims 1 to 6 when executing the computer program.
9. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 6.
CN202010224113.5A 2020-03-26 2020-03-26 Method, device, computer equipment and storage medium for automatically verifying rule Active CN111427789B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010224113.5A CN111427789B (en) 2020-03-26 2020-03-26 Method, device, computer equipment and storage medium for automatically verifying rule

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010224113.5A CN111427789B (en) 2020-03-26 2020-03-26 Method, device, computer equipment and storage medium for automatically verifying rule

Publications (2)

Publication Number Publication Date
CN111427789A CN111427789A (en) 2020-07-17
CN111427789B true CN111427789B (en) 2022-08-16

Family

ID=71555660

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010224113.5A Active CN111427789B (en) 2020-03-26 2020-03-26 Method, device, computer equipment and storage medium for automatically verifying rule

Country Status (1)

Country Link
CN (1) CN111427789B (en)

Family Cites Families (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2740482B2 (en) * 1995-09-26 1998-04-15 日本電気移動通信株式会社 Automatic test procedure manual creation system
US8868353B2 (en) * 2007-02-02 2014-10-21 Beckman Coulter, Inc. System and method for testing autoverification rules
CN102663444B (en) * 2012-03-26 2015-02-11 广州商景网络科技有限公司 Method for preventing account number from being stolen and system thereof
US9606903B2 (en) * 2014-06-06 2017-03-28 Paypal, Inc. Unit test automation for business rules and applications
US20190392724A1 (en) * 2014-08-22 2019-12-26 Intelligent Technologies International, Inc. Secure Testing Device
US10503483B2 (en) * 2016-02-12 2019-12-10 Fisher-Rosemount Systems, Inc. Rule builder in a process control network
CN206684726U (en) * 2017-04-14 2017-11-28 深圳市优力特技术有限公司 A kind of APP test devices
CN108304708A (en) * 2018-01-31 2018-07-20 广东欧珀移动通信有限公司 Mobile terminal, face unlocking method and related product
CN109284106A (en) * 2018-07-18 2019-01-29 平安科技(深圳)有限公司 Method for release management, electronic device and the readable storage medium storing program for executing of business rule
CN109377393A (en) * 2018-10-18 2019-02-22 阳光人寿保险股份有限公司 Regular method of calibration and device
CN109783107B (en) * 2019-01-10 2022-05-24 深圳市小赢信息技术有限责任公司 Visual rule generation method and device and electronic equipment
CN109783071B (en) * 2019-01-21 2022-03-29 浪潮软件股份有限公司 Drools rule engine-based government rule design method and system
CN109960654A (en) * 2019-02-22 2019-07-02 德联易控科技(北京)有限公司 Test method, device, equipment and the storage medium of setting loss rule
CN110618910A (en) * 2019-08-27 2019-12-27 中国第一汽车股份有限公司 Test system and method

Also Published As

Publication number Publication date
CN111427789A (en) 2020-07-17

Similar Documents

Publication Publication Date Title
CN109683988B (en) Micro services start method, apparatus, computer equipment and storage medium
CN111177005A (en) Service application testing method, device, server and storage medium
US9262396B1 (en) Browser compatibility checker tool
CN108427613B (en) Abnormal interface positioning method and device, computer equipment and storage medium
CN109977012B (en) Joint debugging test method, device, equipment and computer readable storage medium of system
CN111290742A (en) Parameter verification method and device, electronic equipment and readable storage medium
CN109582583B (en) Software testing method, device, computer equipment and storage medium
CN113961332A (en) Method and device for realizing workflow engine, electronic equipment and storage medium
CN109657475A (en) Code vulnerabilities check method, apparatus, equipment and storage medium
CN110969417A (en) Government affair item synchronization method, device, system, computer equipment and storage medium
CN112035163A (en) Software development kit configuration method, device and storage medium
CN113886262A (en) Software automation test method and device, computer equipment and storage medium
CN112597016A (en) Recording method, device and equipment of automatic test script and storage medium
CN112579461A (en) Assertion processing method, system and storage medium
CN114254022B (en) RPA and AI-based flow task processing method, device, system and server
CN116909936B (en) Big data automatic test method, equipment and readable storage medium
CN112131127B (en) Interface testing method, device and system and electronic equipment
CN112612706A (en) Automated testing method, computer device and storage medium
CN111427789B (en) Method, device, computer equipment and storage medium for automatically verifying rule
CN111062676A (en) Method and device for realizing government affair approval process
CN113360365B (en) Flow test method and flow test system
CN108804309B (en) Automatic test method and test tool for contract management system
CN110704218B (en) Data processing method, data processing device, computer equipment and storage medium
CN114528213A (en) Automatic baffle plate testing method, device, equipment and storage medium
CN110532186B (en) Method, device, electronic equipment and storage medium for testing by using verification code

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant