Test method and device for approval process, equipment, storage medium and computer program product

By generating an approval process model and role canvas, and generating test cases with preset test patterns, the problems of omissions and inefficiency in the approval process test are solved, and more efficient testing and more accurate path verification are achieved.

CN119127666APending Publication Date: 2024-12-13CHINA MERCHANTS BANK
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411058665.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-02
Publication Date
2024-12-13

AI Technical Summary

Technical Problem

The existing approval process testing methods are prone to omissions in sorting and path errors, the testing efficiency is low, and the relationship between roles is ignored.

Method used

By obtaining roles and role elements in the approval process, generating an approval process model, creating a role canvas, and generating test cases based on the preset test pattern for systematic testing, and generating test reports.

Benefits of technology

Improves testing efficiency, reduces combing omissions and path errors, and can meet different testing needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119127666A_ABST
    Figure CN119127666A_ABST
Patent Text Reader

Abstract

The invention discloses a test method and device of an approval process, equipment, a storage medium and a computer program product, and relates to the technical field of electronic information, and the method comprises the steps: obtaining a role and a role element according to the approval process; modeling based on the role and the role elements to generate an approval process model; generating a role canvas of the approval process based on the approval process model; generating a test case of the approval process according to the role canvas and a preset test mode; and testing the approval process according to the test case, and generating a test report of the approval process. According to the role canvas and the preset test mode, the test case of the approval process is automatically generated, so that the test efficiency of the approval process is improved, and sorting omission and path errors are reduced; different test requirements can be met by testing according to the preset test mode.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of electronic information technology, and in particular to a testing method, device, equipment, storage medium and computer program product for an approval process. Background Art

[0002] As a typical business scenario based on approval flow, the credit application approval of a bank is characterized by the fact that the business processing involves multiple approval processing roles, some roles have their own unique processing nodes, some roles share the same processing nodes, some roles must participate in the processing, and some roles are optional. The process scenario branches are many and complex. At present, the testing of the approval process is basically based on the subjective case design of the tester, and a small number of them are supplemented by simple flowcharts. For example, some are tested separately by role. The problem is that the test case pays more attention to the local part of a single role, and ignores whether the serial connection between roles is normal; some rely on pure manual reasoning to reason out the processing path. When the path is long, it is easy to miss the path branch combing, or even cause the whole path error after a node error. Some do not consider the background of project transformation and carry out full path testing under any circumstances. This is mainly easy to waste test resources and fail to complete the test work efficiently.

[0003] Therefore, in the traditional testing method of the approval process, the method of breaking down the process by role and then testing it ignores the connection between roles, while the method of relying solely on manual reasoning of the test path is prone to omissions when the test path is long, which ultimately leads to path errors and low testing efficiency.

[0004] The above contents are only used to assist in understanding the technical solution of the present application and do not constitute an admission that the above contents are prior art. Summary of the invention

[0005] The main purpose of this application is to provide a testing method, device, equipment and storage medium for an approval process, aiming to solve the technical problems that the approval process is prone to omissions and low testing efficiency.

[0006] To achieve the above purpose, this application proposes a testing method for the approval process, the method comprising:

[0007] Get roles and role elements based on approval process;

[0008] Modeling is performed based on the roles and the role elements to generate an approval process model;

[0009] Based on the approval process model, generating a role canvas of the approval process;

[0010] Generate test cases for the approval process based on the role canvas and the preset test mode;

[0011] The approval process is tested according to the test case, and a test report of the approval process is generated.

[0012] In one embodiment, the step of obtaining roles and role elements according to the approval process includes:

[0013] Acquire a role according to the approval process, where the role is a role that performs approval operations in the approval process;

[0014] According to the approval process, role elements are acquired, where the role elements are preset elements that limit the role to perform the approval process, and the role elements include nodes, operations, and rules.

[0015] In one embodiment, the step of generating the role canvas of the approval process based on the approval process model includes:

[0016] According to the approval process model, obtaining the roles in the approval process model;

[0017] Classifying the roles according to the operations of the roles in the approval process;

[0018] According to the approval process model, extracting the node of the role;

[0019] A role canvas of the approval process is generated according to the roles, the role classifications, and the nodes corresponding to the roles.

[0020] In one embodiment, the step of classifying the roles according to the operations of the roles in the approval process includes:

[0021] If the role is a role that must participate in the approval process, the role is set as a required role;

[0022] If the role is a role that may participate in the approval process, the role is set as a contingent role;

[0023] If at least one of several roles participates in the approval process, the several roles are set as pool roles.

[0024] In one embodiment, the step of generating a test case for the approval process according to the role canvas and a preset test mode includes:

[0025] Based on a preset test mode, determining in the role canvas the test roles and test nodes required in the test mode;

[0026] Generate a target test path according to the test role and the test node;

[0027] Generate test cases for the approval process based on the target test path.

[0028] In one embodiment, the step of determining the test roles and test nodes required in the test mode in the role canvas based on the preset test mode includes:

[0029] If the preset test mode is the full path mode, all roles in the role canvas are determined as test roles, and all nodes of the roles are determined as test nodes;

[0030] If the preset test mode is the full-role mode, all the roles in the role canvas are determined as test roles, and the minimum nodes covering all the roles are determined as test nodes;

[0031] If the preset test mode is the full node mode, all nodes in the role canvas are determined as test nodes, and the minimum roles covering all nodes are determined as test roles;

[0032] If the preset test mode is the designated role mode, the designated role in the role canvas is determined as the test role, and the minimum nodes covering all designated roles are determined as the test nodes;

[0033] If the preset test mode is the designated node mode, the designated nodes in the role canvas are determined as test nodes, and the minimum roles covering all designated nodes are determined as test roles;

[0034] If the preset test mode is the autonomous mode, the required roles in the role canvas are determined as test roles according to the test requirements of the approval process, and the required nodes in the role canvas are determined as test nodes according to the test requirements of the approval process.

[0035] In one embodiment, after the step of generating a target test path according to the test role and the test node, the step further includes:

[0036] Checking the rationality of the target test path to obtain a rationality check result;

[0037] If the rationality check result is reasonable, then generating a test case for the approval process according to the target test path;

[0038] If the rationality check result is unreasonable, an unreasonable warning of the target test path is sent to the approval process system.

[0039] In addition, to achieve the above purpose, the present application also proposes a testing device for an approval process, the testing device for the approval process comprising:

[0040] A data acquisition module is used to obtain roles and role elements according to the approval process;

[0041] A process modeling module, used to perform modeling based on the roles and role elements to generate an approval process model;

[0042] A canvas generation module, used to generate a role canvas of the approval process based on the approval process model;

[0043] A use case generation module, used to generate a test case for the approval process according to the role canvas and a preset test mode;

[0044] The use case testing module is used to test the approval process according to the test case and generate a test report for the approval process.

[0045] In addition, to achieve the above-mentioned purpose, the present application also proposes a testing device for the approval process, which includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, and the computer program is configured to implement the steps of the testing method for the approval process as described above.

[0046] In addition, to achieve the above-mentioned purpose, the present application also proposes a storage medium, which is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by the processor, the steps of the testing method of the approval process described above are implemented.

[0047] In addition, to achieve the above-mentioned purpose, the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, it implements the steps of the testing method of the approval process as described above.

[0048] One or more technical solutions proposed in this application have at least the following technical effects:

[0049] The embodiments of the present application propose a testing method, apparatus, device, storage medium and computer program product for an approval process, which obtains roles and role elements according to the approval process; performs modeling based on the roles and the role elements to generate an approval process model; generates a role canvas for the approval process based on the approval process model; generates test cases for the approval process according to the role canvas and a preset test mode; tests the approval process according to the test cases and generates a test report for the approval process. The present application generates a role canvas according to roles and role elements, generates test cases for the approval process according to the role canvas and a preset test mode, performs system testing on the approval process system according to the test cases, and generates a test report for the approval process, thereby improving testing efficiency and reducing combing omissions and path errors; testing according to preset test modes can meet different testing requirements. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0051] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0052] Figure 1 A flowchart diagram of the first embodiment of the testing method for the application approval process;

[0053] Figure 2 A schematic diagram of an exemplary approval process model provided for the testing method of the application approval process;

[0054] Figure 3 An example role canvas diagram for the testing approach to this application approval process;

[0055] Figure 4 A schematic diagram of the module structure of the testing device for the approval process of the embodiment of the present application;

[0056] Figure 5 A schematic diagram of the device structure of the hardware operating environment involved in the testing method of the approval process in the embodiment of the present application.

[0057] The purpose, features and advantages of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0058] It should be understood that the specific embodiments described herein are only used to explain the technical solutions of the present application and are not used to limit the present application.

[0059] In order to better understand the technical solution of the present application, a detailed description will be given below in conjunction with the accompanying drawings and specific implementation methods.

[0060] The main solution of the embodiment of the present application is: obtain roles and role elements according to the approval process; model based on the roles and the role elements to generate an approval process model; generate a role canvas of the approval process based on the approval process model; generate test cases of the approval process according to the role canvas and the preset test mode; test the approval process according to the test case and generate a test report of the approval process. The present application can improve the testing efficiency and reduce combing omissions and path errors by generating a role canvas according to roles and role elements, and generating test cases of the approval process according to the role canvas and the preset test mode; testing according to the preset test mode can meet different testing requirements.

[0061] In the existing testing method of the approval process, the method of breaking down the process by role and then testing it ignores the connection between roles, while the method of relying solely on manual reasoning of the test path is prone to omissions when the test path is long, which ultimately leads to path errors, low testing efficiency, and a single testing mode.

[0062] This application generates a role canvas based on roles and role elements, and generates test cases for the approval process based on the role canvas and preset test modes, which can improve testing efficiency and reduce omissions and path errors; testing according to preset test modes can meet different testing needs.

[0063] It should be noted that the execution subject of this embodiment can be a computing service device with data processing, network communication and program running functions, such as a tablet computer, a personal computer, a mobile phone, etc., or an electronic device capable of realizing the above functions, a testing device for the approval process, etc. The following takes the testing device for the approval process as an example to illustrate this embodiment and the following embodiments.

[0064] Based on this, the present application embodiment provides a testing method for the approval process, referring to Figure 1 , Figure 1 This is a flowchart of the first embodiment of the testing method of the application approval process.

[0065] In this embodiment, the testing method of the approval process includes steps S10 to S50:

[0066] Step S10, obtaining roles and role elements according to the approval process.

[0067] It should be noted that the approval process system is a software system that automates various approval processes inside or outside the enterprise. Through preset processes and rules, the system transforms the cumbersome process of traditional paper approval and manual circulation into a digital and automated processing flow to improve work efficiency, reduce errors, enhance transparency, and ensure the standardization and standardization of enterprise processes.

[0068] In addition, it should be noted that the role refers to the role that performs approval operations in the approval process system, which is usually divided according to the responsibilities and permissions in the approval process. Common roles in the approval process include submitter (applicant), approver, collaborator, and process administrator.

[0069] In addition, it should be noted that the role elements refer to the preset elements that limit the role to perform the approval process, and the role elements include nodes, operations, and rules.

[0070] The node refers to a step in the approval process system. For example, node 6 indicates that the node is located at the sixth step in the approval process.

[0071] The operation refers to the specific operation mode in the node, for example, application, return, deletion, review, forwarding, etc. are all node operations.

[0072] The rule refers to the conditions that need to be met to perform the operation. That is, the operation can only be performed if the rule is met. For example, it is determined whether role C needs to perform processing. When the judgment result is yes, role C will perform the processing.

[0073] Specifically, based on the approval process system and business needs, according to the business scenario of the approval process, determine the roles required in the business scenario, and then determine the role elements of the roles in the approval process of the business context.

[0074] First, determine the main goals of approval process modeling, such as improving approval efficiency, optimizing resource allocation, ensuring compliance, etc.; then, through interviews, questionnaires, document reviews, etc., collect comprehensive information on the current approval process, including the roles and role elements involved. Role elements include but are not limited to the responsibilities, permissions, key elements in the process, etc. of the role; then, based on business needs, define specific approval process scenarios, and clarify the business goals, inputs and outputs, constraints, etc. of each scenario; then, perform role identification and role element identification based on the approval process system and business scenarios, identify all roles involved in the approval process, including applicants, approvers at all levels, system administrators, etc., analyze the responsibilities, permissions, decision-making basis and other elements of each role, ensure that the role definition is clear and unambiguous, identify the role elements of the roles in the approval process, such as approval conditions, approval standards, approval documents, approval results, etc., analyze how these elements affect the execution of the approval process, as well as the relationship and dependency between them, and finally determine the roles and role elements required for modeling the approval process model.

[0075] Step S20: Modeling is performed based on the roles and the role elements to generate an approval process model.

[0076] It should be noted that the approval process model refers to modeling based on the business scenario of the approval process based on business requirements and the roles and role elements of the approval process system, to generate a model that can reflect the approval process under the business scenario.

[0077] Specifically, after determining the roles and role elements, the business scenario based on the approval process is modeled to generate an approval process model. Commonly used modeling tools include business process management BPM (Business Process Management), unified modeling language UML (Unified Modeling Language) and other modeling tools.

[0078] For easier understanding, please refer to Figure 2 , Figure 2 is a schematic diagram of an exemplary approval process model. Figure 2The roles in the process include A, B, C, D, E, F, G and H. A starts the process application. If the application is withdrawn, it is initiated again. If the application is deleted, the approval process ends. After A makes the application, it determines whether it needs to be processed by B. If it needs to be processed by B, if B's ​​processing is forwarding, it is transferred back to B for processing. If B's ​​processing is review, it is transferred to determine whether it needs to be processed by C after review. If B's ​​processing is return, it is re-initiated. If it does not need to be processed by B, it is directly transferred to determine whether it needs to be processed by C. If it needs to be processed by C, it will be temporarily processed by C first, and then reviewed by C. After the review is completed, it will be transferred to the role pool of D, E, F, and G for processing. If role C is not required, it will be directly transferred to the role pool of D, E, F, and G for processing; D, E, F, and G are a group of pool roles, and one processing operation requires at least one role in the group of pool roles to perform the processing operation. First, it will be approved by a role in the role pool. After the approval is completed, it will be transferred to the veto person for review, and then to the committee for review. After completion, it will be transferred to the joint group for review. After final completion, it will be transferred to the final approval. After the final approval is completed, it will be transferred to role H for processing, and role H will publish the results, and finally the process ends.

[0079] Step S30: generating a role canvas of the approval process based on the approval process model.

[0080] It should be noted that the role canvas refers to a visual canvas that reflects the relationship between roles and role elements in the approval process model. The visual canvas uses graphics, icons, lines and other elements to intuitively display the various components of the system or process, such as roles, processing nodes, data flows, etc., as well as the relationship between them.

[0081] Specifically, based on the approval process model, the roles and nodes in the role elements in the approval process model are obtained, and the roles are classified according to the operations of the roles in the approval process. The role classification is divided into necessary roles, optional roles, and pool roles. According to the roles and the role classifications, and the nodes corresponding to the roles, a role canvas is generated. Commonly used tools for generating visualization canvases include powerful visualization canvas tools such as Tableau, Power BI, DataV, and FineBI, which can help users quickly create and customize various data visualization charts and canvases.

[0082] For easier understanding, please refer to Figure 3 , Figure 3 For reference Figure 2 A schematic diagram of an exemplary role canvas generated by an exemplary approval process model. Figure 3The role canvas is displayed in a table format, which is divided into three parts: role list, role classification, and processing node. The role list shows the roles in the approval process model, the role classification shows the role classification, and the processing node shows the nodes corresponding to the roles in the role list, the corresponding step number of the node in the process, and the operation of the node.

[0083] Step S40: Generate a test case for the approval process according to the role canvas and the preset test mode.

[0084] It should be noted that the test mode refers to the test mode selected by the user. Based on different test modes, different test cases will be generated to test the approval process.

[0085] In addition, it should be noted that the test case refers to a set of test inputs, execution conditions and expected results designed to test a specific function or verify a specific requirement. Test cases are the basis of software testing. They guide testers on how to perform tests and help ensure the quality and stability of the software. The design of test cases is an important part of the software testing process. It directly affects the quality and efficiency of the test. Through well-designed test cases, it can ensure that the various functions and requirements of the software are fully verified, thereby improving the overall quality of the software. The design of test cases should follow certain principles, such as equivalence class division, boundary value analysis, causal diagram method, error speculation method, etc., to ensure the comprehensiveness and effectiveness of the test.

[0086] A test case usually contains several basic elements: test identifier, test title, test purpose, test preconditions, test input, test steps, expected results, actual results, test status, comments, etc.; the test identifier is used to uniquely identify the number or name of the test case, the test title is used to briefly describe the purpose or function of the test case, the test purpose is used to clarify the software function or requirement that the test case wants to verify, the test precondition is used to meet the conditions or status that must be met before executing the test case, for example, the system must be logged in, a specific configuration must be set, etc., the test input is used to provide data or operations to the system under test in order to execute the test, which can be data values, files, interface operations, etc., the test steps are used to describe in detail the sequence of operations required to execute the test, including all necessary configurations and interactions, the expected result is used for the result or behavior that the system should produce after given the test input and execution steps, the actual result is the actual result observed after executing the test, usually used to compare with the expected result, the test status is used to identify the execution result of the test case, such as pass, fail, blocked, etc., and the comments are used to provide additional information about the test case, such as defect tracking number, tester's observations or suggestions, etc.

[0087] Specifically, according to the approval process model, the roles in the approval process model are obtained; according to the operations of the roles in the approval process, the roles are classified; according to the approval process model, the nodes of the roles are extracted; according to the roles and the role classifications, and the nodes corresponding to the roles, a role canvas of the approval process is generated.

[0088] Step S50: testing the approval process according to the test case and generating a test report of the approval process.

[0089] It should be noted that the test report refers to a summary document of the software testing activity after the software testing activity is completed. It records in detail the testing process, results, defects found, and a series of information for evaluating software quality. The purpose of the test report is to provide comprehensive and accurate information about the quality of the software product to relevant personnel, such as project managers, developers, testers, quality assurance personnel, customers, etc., so as to facilitate them to make decisions, improve product quality or carry out follow-up work.

[0090] A test report usually includes an introduction, test overview, test process, test results, defect analysis, test conclusions, suggestions and improvements, and appendices. The introduction includes the test purpose, test scope, test environment (such as hardware environment, software environment, network conditions, etc.), test methods (such as black box testing, white box testing, gray box testing, etc.), and test basis (such as requirements specifications, design documents, etc.); the test overview is used to summarize the test schedule, test team, test tool usage, etc. The test process is used to describe the test execution steps in detail, including the design of test cases, the test execution process, and the preparation of test data; the test results are the core part of the test report, including the execution status of the test cases (pass / fail / blocked), the list of defects found (defect number, defect description, severity, priority, etc.) , status, discovery date, repair date, etc.), test coverage analysis (such as functional coverage, code coverage, etc.); defect analysis is to classify, count and analyze the defects found, identify the main sources, types, distribution, etc. of defects, and propose improvement measures; the test conclusion is to evaluate the quality of the software product based on the test results and defect analysis, whether it meets the requirements of the requirement specification, whether it can be released or enter the next stage of development, etc.; suggestions and improvements are to propose suggestions for improving software quality and improving testing efficiency for problems found during the testing process; the appendix includes auxiliary information such as test environment configuration details, test case list, defect tracking records, etc.

[0091] Specifically, according to the test cases, the approval process is tested and a test report of the approval process is generated. During the test process, the test environment is ensured to be as consistent as possible with the production environment, including database, network configuration, user permissions, etc. The test is performed one by one according to the steps of the test cases, and the actual results and any abnormal situations are recorded. For important test steps and results, detailed logs and screenshots are recorded for subsequent analysis and report writing. The execution of the test cases is sorted out, including the number of passed cases, the number of failed cases, the number of unexecuted cases, etc. The actual results are compared with the expected results, the differences are found and explained, the causes of errors and defects, as well as performance and stability issues are analyzed, and finally the records and summaries are written to generate a test report.

[0092] This embodiment adopts the above scheme, specifically by obtaining roles and role elements according to the approval process system; modeling based on the roles and role elements to generate an approval process model; generating a role canvas based on the approval process model; generating a test case of the approval process according to the role canvas and a preset test mode; and performing a system test on the approval process system according to the test case to generate a test report of the approval process. It can improve the test efficiency and reduce combing omissions and path errors; testing according to the preset test mode can meet different test requirements.

[0093] Based on the first embodiment, a second embodiment of the present application is proposed. The difference between the second embodiment of the present application and the first embodiment is that:

[0094] In this embodiment, the step of obtaining roles and role elements according to the approval process includes:

[0095] Step S11, obtaining a role according to the approval process, wherein the role is a role for performing approval operations in the approval process system.

[0096] Step S12, obtaining role elements according to the approval process, wherein the role elements are preset elements that limit the role to perform the approval process, and the role elements include nodes, operations, and rules.

[0097] It should be noted that the role is a role that performs approval operations in the approval process system. The role elements are preset elements that limit the role to perform approval processes, and the role elements include nodes, operations, and rules. The node refers to a step in the approval process system; the operation refers to the specific operation method in the node; and the rule refers to the conditions that need to be met to perform the operation.

[0098] Specifically, based on the approval process system and business needs, according to the business scenario of the approval process, determine the roles required in the business scenario, and then determine the role elements of the roles in the approval process of the business context.

[0099] Based on the second embodiment, a third embodiment of the present application is proposed. The difference between the third embodiment of the present application and the second embodiment is that:

[0100] In this embodiment, the step of generating the role canvas of the approval process based on the approval process model includes S31 to S34:

[0101] Step S31: According to the approval process model, obtain the roles in the approval process model.

[0102] Step S32: classify the roles according to the operations of the roles in the approval process.

[0103] Step S33: extracting the role node according to the approval process model.

[0104] Step S34, generating a role canvas according to the role, the role classification, and the node corresponding to the role.

[0105] It should be noted that the role classification divides roles into mandatory roles, optional roles and pool roles. The mandatory roles are roles that must participate in the approval process; the optional roles are roles that may participate in the approval process; the pool roles are roles that are set as pool roles if at least one of the roles in the approval process participates in the approval.

[0106] Specifically, according to the approval process model, all roles in the model are obtained, and the roles are classified according to their operations in the approval process. For example, Figure 2 A schematic diagram of an exemplary approval process model, wherein the roles are classified according to their operations in the approval process, e.g. Figure 2 Role A and role H are required roles, role B and role C are optional roles, and roles D, E, F, and G are pool roles. Then, based on the approval process model, the nodes of the roles and the operations of the nodes are extracted. Finally, based on the roles, the role classifications, and the nodes corresponding to the roles, a role canvas is generated.

[0107] Further, as an implementation mode, the role classification according to the operation of the role in the approval process includes steps S321 to S323:

[0108] Step S321: If the role is a role that must participate in the approval process, the role is set as a required role.

[0109] Step S322: If the role is a role that may participate in the approval process, the role is set as a possible role.

[0110] Step S323: If at least one of the roles in the approval process participates in the approval, the roles are set as pool roles.

[0111] Specifically, based on the operations of the roles in the approval process, the roles are classified. The required roles are roles that must participate in the approval process; the possible roles are roles that may participate in the approval process; the pool roles are roles that are set as pool roles if at least one of the roles in the approval process participates in the approval.

[0112] Based on the third embodiment, a fourth embodiment of the present application is proposed. The difference between the fourth embodiment of the present application and the third embodiment is that:

[0113] In this embodiment, the step of generating a test case of the approval process according to the role canvas and the preset test mode includes steps S41 to S43:

[0114] Step S41, based on a preset test mode, determining in the role canvas the test roles and test nodes required in the test mode.

[0115] Step S42: Generate a target test path according to the test role and the test node.

[0116] Step S43: Generate a test case for the approval process according to the target test path.

[0117] It should be noted that the target test path refers to the complete process of executing each statement from the program entry. Path testing is a technology that ensures that all possible execution paths in a software program are tested, aiming to reveal potential errors that may not be detected by other testing methods.

[0118] Specifically, based on the preset test mode, the test roles and test nodes required under the test mode are determined in the role canvas; based on the test roles and the test nodes, the test path of the approval process under the corresponding test mode is generated, and then a set of test cases are designed for each independent path to ensure that the program is executed at least once along the path. The test case should include a description of the test scenario, expected results, test data, and specific test steps. The test case should be written into a document, including information such as the test case name, number, description, prerequisites, test steps, expected results, etc.

[0119] Further, as an implementation manner, based on the preset test mode, determining the test roles and test nodes required in the test mode in the role canvas includes steps S411 to S416:

[0120] Step S411: If the preset test mode is the full path mode, all roles in the role canvas are determined as test roles, and all nodes of the roles are determined as test nodes.

[0121] Step S412: If the preset test mode is the full-role mode, all the roles in the role canvas are determined as test roles, and the minimum nodes covering all the roles are determined as test nodes.

[0122] Step S413: If the preset test mode is the full-node mode, all nodes in the role canvas are determined as test nodes, and the minimum roles covering all nodes are determined as test roles.

[0123] Step S414: if the preset test mode is the designated role mode, the designated role in the role canvas is determined as the test role, and the minimum nodes covering all designated roles are determined as the test nodes.

[0124] Step S415: If the preset test mode is the designated node mode, the designated nodes in the role canvas are determined as test nodes, and the minimum roles covering all designated nodes are determined as test roles.

[0125] Step S416, if the preset test mode is the autonomous mode, the required roles in the role canvas are determined as test roles according to the test requirements of the approval process, and the required nodes in the role canvas are determined as test nodes according to the test requirements of the approval process.

[0126] Specifically, the full-path mode requires that all roles in the role canvas be identified as test roles, and all nodes of the role be identified as test nodes. It is suitable for new systems or after system reconstruction. It is necessary to test all approval process branches combining all roles and all nodes of the approval process system. At this time, the full-path mode can be selected to generate the most complete process test cases based on all roles and all nodes.

[0127] The full-role mode requires that all roles in the role canvas be identified as test roles, and the minimum nodes covering all roles be identified as test nodes. This mode is suitable for certain business scenarios where the test only focuses on the verification of all roles and there is no requirement for role processing nodes. The full-role mode can be selected. The test paths generated in the full-role mode are aggregated to involve all roles, and each role covers the minimum number of nodes. At the same time, duplication of nodes between roles is avoided as much as possible.

[0128] The full node mode requires that all nodes in the role canvas be identified as test nodes, and the minimum roles covering all nodes be identified as test roles. In some business scenarios, the test only focuses on the verification of all nodes. When there is no requirement for roles, the full node mode can be selected. The test paths generated in the full node mode are summarized to involve all nodes and cover the minimum roles.

[0129] The specified role mode requires that the specified role in the role canvas be determined as the test role, and the minimum nodes covering all the specified roles be determined as the test nodes. In some business scenarios, project changes only involve the characteristics of a certain role, so this test only focuses on the process scenario verification of a certain role. When there is no requirement for other roles, you can choose the specified role mode. This mode only requires the user to select one or more specified roles to be tested on the role canvas. The generated cases are all carried out around the specified role, that is, to ensure that the generated test cases include all nodes of the role after aggregation, and other roles and other nodes are covered as little as possible.

[0130] The specified node mode requires that the specified node in the role canvas be determined as the test node, and the minimum role covering all the specified nodes be determined as the test role. In some business scenarios, the change of the business scenario only involves the logic of a certain node, so the test under the business scenario only focuses on the process scenario verification of a certain node, that is, a full verification of the roles involved in the node is performed. When there is no requirement for the roles and other nodes not involving the node, the specified node mode can be selected. This mode only requires the user to select one or more specified nodes that need to be paid attention to on the canvas. The generated cases are all carried out around the specified nodes, that is, to ensure that the generated test cases are summarized to include all process cases of all roles of the specified node, and the roles and other nodes not involving the specified node are covered as little as possible.

[0131] The autonomous mode requires that the required roles in the role canvas be determined as test roles according to the test requirements of the approval process, and the required nodes in the role canvas be determined as test nodes according to the test requirements of the approval process. It is suitable for testers who are familiar with business requirements and systems and have strong thinking skills. It supports testers to adopt the autonomous mode, that is, testers can analyze the test strategy for this project based on the changes made in this project and the actual use of the system by business personnel in production (such as frequency, risk and other factors). Then, they can check the roles and nodes that need to be tested in this test on the canvas, and generate test cases for this test in a targeted manner. The generated cases can cover the selected roles and nodes after being summarized, and at least cover other roles and nodes.

[0132] Based on the fourth embodiment, a fifth embodiment of the present application is proposed. The difference between the fifth embodiment of the present application and the fourth embodiment is that:

[0133] In this embodiment, the step of generating a target test path according to the role and the test node further includes the following steps:

[0134] Step S441, checking the rationality of the target test path to obtain a rationality check result.

[0135] Step S442: If the rationality check result is reasonable, a test case for the approval process is generated according to the target test path.

[0136] Step S443: If the rationality check result is unreasonable, an unreasonable warning of the target test path is sent to the approval process system.

[0137] Specifically, first review each node and step in the target test path point by point to ensure its logical coherence, compliance with business requirements, and no omissions or redundant operations. Then verify whether the test path covers all key business logic in the approval process, including normal processes, abnormal processes, boundary conditions, etc., and then evaluate whether the test path is technically feasible and whether factors such as system architecture, performance requirements, and security are considered. Finally, obtain the rationality check results, which can be reasonable or unreasonable.

[0138] If the rationality check result is reasonable, then generate test cases for the approval process according to the target test path. Design test cases for the approval process based on the refined test path. Each test case should include key elements such as test scenarios, preconditions, test steps, and expected results. The designed test cases should be documented to ensure that the document structure is clear, easy to understand, and contains enough details to guide the test execution.

[0139] If the result of the rationality check is unreasonable, an unreasonable warning of the target test path is sent to the approval process system. According to the analysis results, write clear and specific unreasonable warning information, clearly point out the problems and unreasonableness of the test path, and determine the recipient of the unreasonable warning. The recipient is usually the development team, test leader or relevant stakeholders of the approval process system. Send the unreasonable warning to the recipient through appropriate communication channels, such as email, instant messaging tools, project management software, etc. If the recipient improves the unreasonable warning and resubmits the test path, it is necessary to re-check the rationality to ensure that the problem is resolved. If the problem still exists, continue to send warnings and track the processing until the problem is completely resolved.

[0140] It should be noted that the above examples are only used to understand the present application and do not constitute a limitation on the testing method of the approval process of the present application. More simple transformations based on this technical concept are all within the scope of protection of the present application.

[0141] This application also provides a test device for the approval process, please refer to Figure 4 , Figure 4 The module structure diagram of the testing device of the approval process is as follows:

[0142] The data acquisition module 401 is used to acquire roles and role elements according to the approval process system;

[0143] A process modeling module 402, used to perform modeling based on the roles and the role elements to generate an approval process model;

[0144] A canvas generation module 403 is used to generate a role canvas based on the approval process model;

[0145] A use case generation module 404, used to generate a test case for the approval process according to the role canvas and a preset test mode;

[0146] The use case testing module 405 is used to test the approval process system according to the test case and generate a test report of the approval process.

[0147] The testing device for the approval process provided by the present application adopts the testing method for the approval process in the above-mentioned embodiment, which can solve the technical problems that the approval process is easy to sort out and miss and the testing efficiency is low. Compared with the prior art, the beneficial effects of the testing device for the approval process provided by the present application are the same as the beneficial effects of the testing method for the approval process provided by the above-mentioned embodiment, and the other technical features in the testing device for the approval process are the same as the features disclosed in the above-mentioned embodiment method, which will not be repeated here.

[0148] The present application provides a testing device for an approval process, and the testing device for the approval process includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the testing method for the approval process in the above-mentioned embodiment one.

[0149] Reference below Figure 5, which shows a schematic diagram of the structure of the test equipment suitable for implementing the approval process of the embodiment of the present application. The test equipment of the approval process in the embodiment of the present application may include but is not limited to mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 5 The testing equipment for the approval process shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0150] like Figure 5 As shown, the test device for the approval process may include a processing device 1001 (e.g., a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM: Read Only Memory) 1002 or a program loaded from a storage device 1003 to a random access memory (RAM: Random Access Memory) 1004. In RAM1004, various programs and data required for the operation of the test device for the approval process are also stored. The processing device 1001, ROM1002, and RAM1004 are connected to each other through a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems can be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touch pad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 can allow the testing device of the approval process to communicate with other devices wirelessly or by wire to exchange data. Although the figure shows the testing device of the approval process with various systems, it should be understood that it is not required to implement or have all the systems shown. More or fewer systems can be implemented or have alternatively.

[0151] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device 1003, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, the above-mentioned functions defined in the method of the embodiment disclosed in the present application are executed.

[0152] The testing device for the approval process provided by the present application adopts the testing method for the approval process in the above-mentioned embodiment, which can solve the technical problems that the approval process is easy to sort out and miss and the testing efficiency is low. Compared with the prior art, the beneficial effects of the testing device for the approval process provided by the present application are the same as the beneficial effects of the testing method for the approval process provided by the above-mentioned embodiment, and the other technical features in the testing device for the approval process are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.

[0153] It should be understood that the various parts disclosed in this application can be implemented by hardware, software, firmware or a combination thereof. In the description of the above embodiments, specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.

[0154] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

[0155] The present application provides a computer-readable storage medium having computer-readable program instructions (ie, computer programs) stored thereon, and the computer-readable program instructions are used to execute the testing method of the approval process in the above-mentioned embodiment.

[0156] The computer-readable storage medium provided in the present application may be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, systems or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, system or device. The program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination of the above.

[0157] The computer-readable storage medium may be included in the testing device of the approval process; or may exist independently without being assembled into the testing device of the approval process.

[0158] The computer-readable storage medium carries one or more programs. When the one or more programs are executed by the testing device of the approval process, the testing device of the approval process: obtains roles and role elements according to the approval process; performs modeling based on the roles and the role elements to generate an approval process model; generates a role canvas of the approval process system based on the approval process model; generates a test case of the approval process according to the role canvas and a preset test mode; and tests the approval process system according to the test case to generate a test report of the approval process.

[0159] Computer program code for performing the operations of the present application may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0160] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0161] The modules involved in the embodiments described in this application may be implemented by software or hardware, wherein the name of the module does not constitute a limitation on the unit itself in some cases.

[0162] The readable storage medium provided by the present application is a computer-readable storage medium, which stores computer-readable program instructions (i.e., computer programs) for executing the above-mentioned test method of the approval process, and can solve the technical problems that the approval process is easy to sort out and miss and the test efficiency is low. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided by the present application are the same as the beneficial effects of the test method of the approval process provided by the above-mentioned embodiment, and will not be repeated here.

[0163] The present application also provides a computer program product, including a computer program, which implements the steps of the above-mentioned testing method for the approval process when executed by a processor.

[0164] The computer program product provided by this application can solve the technical problems that the approval process is easy to sort out and miss and the testing efficiency is low. Compared with the prior art, the beneficial effects of the computer program product provided by this application are the same as the beneficial effects of the testing method of the approval process provided by the above embodiment, which will not be repeated here.

[0165] The above descriptions are only some embodiments of the present application, and are not intended to limit the patent scope of the present application. All equivalent structural changes made using the contents of the present application specification and drawings under the technical concept of the present application, or direct / indirect applications in other related technical fields are included in the patent protection scope of the present application.

Claims

1. A testing method for approval process, characterized in that: The method comprises: Get roles and role elements based on approval process; Modeling is performed based on the roles and the role elements to generate an approval process model; Based on the approval process model, generating a role canvas of the approval process; Generate test cases for the approval process based on the role canvas and the preset test mode; The approval process is tested according to the test case, and a test report of the approval process is generated.

2. The method according to claim 1, characterized in that The steps of obtaining roles and role elements according to the approval process include: Acquire a role according to the approval process, where the role is a role that performs approval operations in the approval process; According to the approval process, role elements are acquired, where the role elements are preset elements that limit the role to perform the approval process, and the role elements include nodes, operations, and rules.

3. The method according to claim 1, characterized in that The step of generating the role canvas of the approval process based on the approval process model comprises: According to the approval process model, obtaining the roles in the approval process model; Classifying the roles according to the operations of the roles in the approval process; According to the approval process model, extracting the node of the role; A role canvas of the approval process is generated according to the roles, the role classifications, and the nodes corresponding to the roles.

4. The method according to claim 3, characterized in that The step of classifying the roles according to the operations of the roles in the approval process comprises: If the role is a role that must participate in the approval process, the role is set as a required role; If the role is a role that may participate in the approval process, the role is set as a contingent role; If at least one of several roles participates in the approval process, the several roles are set as pool roles.

5. The method according to claim 1, characterized in that The step of generating a test case for the approval process according to the role canvas and the preset test mode includes: Based on a preset test mode, determining in the role canvas the test roles and test nodes required in the test mode; Generate a target test path according to the test role and the test node; Generate test cases for the approval process based on the target test path.

6. The method according to claim 5, characterized in that The step of determining the test roles and test nodes required in the test mode in the role canvas based on the preset test mode includes: If the preset test mode is the full path mode, all roles in the role canvas are determined as test roles, and all nodes of the roles are determined as test nodes; If the preset test mode is the full-role mode, all the roles in the role canvas are determined as test roles, and the minimum nodes covering all the roles are determined as test nodes; If the preset test mode is the full node mode, all nodes in the role canvas are determined as test nodes, and the minimum roles covering all nodes are determined as test roles; If the preset test mode is the designated role mode, the designated role in the role canvas is determined as the test role, and the minimum nodes covering all designated roles are determined as the test nodes; If the preset test mode is the designated node mode, the designated nodes in the role canvas are determined as test nodes, and the minimum roles covering all designated nodes are determined as test roles; If the preset test mode is the autonomous mode, the required roles in the role canvas are determined as test roles according to the test requirements of the approval process, and the required nodes in the role canvas are determined as test nodes according to the test requirements of the approval process.

7. The method according to claim 5, characterized in that After the step of generating a target test path according to the test role and the test node, the step further includes: Checking the rationality of the target test path to obtain a rationality check result; If the rationality check result is reasonable, then generating a test case for the approval process according to the target test path; If the rationality check result is unreasonable, an unreasonable warning of the target test path is sent to the approval process system.

8. A testing device for approval process, characterized in that: The device comprises: A data acquisition module is used to obtain roles and role elements according to the approval process; A process modeling module, used to perform modeling based on the roles and role elements to generate an approval process model; A canvas generation module, used to generate a role canvas of the approval process based on the approval process model; A use case generation module, used to generate a test case for the approval process according to the role canvas and a preset test mode; The use case testing module is used to test the approval process according to the test case and generate a test report for the approval process.

9. A testing device for approval process, characterized in that: The device comprises: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the testing method for the approval process according to any one of claims 1 to 7.

10. A storage medium, characterized in that: The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the testing method of the approval process as described in any one of claims 1 to 7 are implemented.

11. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the steps of the testing method of the approval process according to any one of claims 1 to 7 are implemented.