Front-end and back-end business process test method and device, equipment and storage medium
By obtaining the matching processing of the front-end navigation components and the back-end business nodes, building the front-end and back-end business processes and testing them, the problem of not being able to determine the processing status of the other end in time during individual testing is solved, and the accuracy and efficiency of the test are improved.
Patent Information
- Application Number
- CN202510818761.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-18
- Publication Date
- 2025-09-26
AI Technical Summary
When executing front-end and back-end test scripts separately, it is impossible to determine the processing status of the other end in a timely manner, which can easily lead to false success and delayed problem discovery and risk avoidance.
By obtaining the front-end navigation components corresponding to user operation requests, extracting back-end business nodes from the log system, building front-end and back-end business processes, and testing based on test scripts.
It enables timely detection of problems and avoidance of risks, improves testing efficiency and accuracy, and ensures stable operation of applications.
Smart Images

Figure CN120705047A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of financial technology or other related fields, and in particular to a testing method, device, equipment and storage medium for front-end and back-end business processes. Background Art
[0002] As user interfaces become increasingly complex and features are added, front-end and back-end testing should be performed to ensure stable application operation.
[0003] Currently, automated test scripts and back-end interface test scripts are usually executed at a scheduled time through user interface (UI) automation testing tools. When a script reports an error, the error code is automatically categorized. For scripts suspected of program problems, the cause of the error is analyzed in detail based on the log.
[0004] However, when executing the front-end and back-end test scripts separately, when an exception occurs on one end, false success is likely to occur because the processing status of the other end cannot be determined in time. Therefore, problems cannot be discovered in time and risks cannot be avoided in time. Summary of the Invention
[0005] The present application provides a testing method, apparatus, device and storage medium for front-end and back-end business processes, which is used to solve the technical problem that when an exception occurs on one end when executing the front-end and back-end test scripts separately, false success is easily caused because the processing status of the other end cannot be determined in time.
[0006] In a first aspect, the present application provides a method for testing front-end and back-end business processes, including:
[0007] In response to a user operation request, obtaining a front-end navigation component corresponding to the user operation request;
[0008] Determine a business log from a log system, and extract multiple backend business nodes from the business log, wherein the business log is used to indicate a log containing a unique identifier corresponding to the user operation request;
[0009] Matching the front-end navigation component with the multiple back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request;
[0010] The front-end and back-end business processes are tested based on the test script corresponding to the user operation request.
[0011] In a second aspect, the present application provides a testing device for front-end and back-end business processes, including:
[0012] An acquisition module, in response to a user operation request, configured to acquire a front-end navigation component corresponding to the user operation request;
[0013] a processing module, configured to determine a business log from a log system and extract a plurality of backend business nodes from the business log, wherein the business log is used to indicate a log containing a unique identifier corresponding to the user operation request;
[0014] The processing module is further configured to perform matching processing on the front-end navigation component and the plurality of back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request;
[0015] The testing module is used to test the front-end and back-end business processes based on the test script corresponding to the user operation request.
[0016] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a memory, a processor;
[0017] The memory stores computer-executable instructions;
[0018] The processor executes the computer-executable instructions stored in the memory, so that the processor executes the above first aspect and / or various possible implementations of the first aspect.
[0019] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, they are used to implement the first aspect above and / or various possible implementation methods of the first aspect.
[0020] In a fifth aspect, an embodiment of the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the above first aspect and / or various possible implementation methods of the first aspect.
[0021] The testing method, apparatus, equipment and storage medium for the front-end and back-end business processes provided in the present application obtain the front-end navigation component corresponding to the user operation request by responding to the user operation request, determine the business log from the log system, and extract multiple back-end business nodes from the business log to provide data support for subsequent front-end and back-end testing; match the front-end navigation component and multiple back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request, forming a complete business process, clearly showing the back-end processing process after a user operation request is performed on the business front-end, and testing the front-end and back-end business processes based on the test script corresponding to the user operation request, thereby avoiding false success when an exception occurs on one end, and helping to promptly discover problems and avoid risks. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] 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.
[0023] Figure 1 A schematic diagram of a scenario for a front-end and back-end business process testing method provided in an embodiment of the present application;
[0024] Figure 2 A schematic diagram of a front-end and back-end business process testing method provided in an embodiment of the present application Figure 1 ;
[0025] Figure 3 A schematic diagram of a front-end and back-end business process testing method provided in an embodiment of the present application Figure 2 ;
[0026] Figure 4 A user operation diagram provided in an embodiment of the present application;
[0027] Figure 5 A schematic diagram of a backend business process provided in an embodiment of the present application;
[0028] Figure 6 A schematic diagram of a front-end and back-end business process provided in an embodiment of the present application;
[0029] Figure 7 A schematic diagram of the structure of a testing device for front-end and back-end business processes provided in an embodiment of the present application;
[0030] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.
[0031] The above drawings illustrate specific embodiments of the present application, which will be described in more detail below. These drawings and the textual description are not intended to limit the scope of the present application in any way, but rather to illustrate the concepts of the present application to those skilled in the art by reference to specific embodiments. DETAILED DESCRIPTION
[0032] Exemplary embodiments will be described in detail herein, with examples illustrated in the accompanying drawings. In the following description, when referring to the drawings, identical numerals in different figures represent identical or similar elements, unless otherwise indicated. The embodiments described in the following exemplary embodiments are not intended to represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present application, as detailed in the appended claims.
[0033] It should be noted that the testing methods, devices, equipment and storage media for the front-end and back-end business processes provided in this application can be used in the field of financial technology, and can also be used in any field other than the field of financial technology. The application fields of the testing methods, devices, equipment and storage media for the front-end and back-end business processes in this application are not limited.
[0034] "Multiple" refers to two or more, and other quantifiers are similar. "And / or" describes the relationship between related objects, indicating that three possible relationships exist. For example, "A and / or B" can mean: A exists alone, A and B exist simultaneously, and B exists alone. The character " / " generally indicates that the related objects are in an "or" relationship.
[0035] The terms "first," "second," "third," "fourth," and so on (if any) in the description and claims of the present invention and in the accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a particular order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate, so that the embodiments of the present invention described herein can, for example, be implemented in an order other than that illustrated or described herein. In addition, the terms "including" and "having," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, system, product, or apparatus comprising a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, products, or apparatuses.
[0036] It should be noted that in the embodiments of this application, words such as "exemplary" or "for example" are used to indicate examples, illustrations, or descriptions. Any embodiment or design described in this application as "exemplary" or "for example" should not be interpreted as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "for example" is intended to present the relevant concepts in a concrete manner.
[0037] In order to give readers a preliminary understanding of the testing method of the front-end and back-end business processes of this application, Figure 1 The application scenarios of the testing method of the front-end and back-end business processes of this application are introduced. Figure 1 A schematic diagram of a scenario for testing a front-end and back-end business process provided in an embodiment of the present application. Figure 1As shown, on a test application, a user (or a test tool for simulating user operations) accesses the application through a browser or mobile application, and operates the user interface 11, such as clicking a navigation button (a prompt message may be displayed on the user interface). At this time, the user request will be sent to the server 12, and the server 12 performs business processing based on the user request. After the processing is completed, the processing result is fed back to the user interface 11. As the user interface continues to become more complex and the functions are increasingly superimposed, front-end and back-end testing should be carried out to ensure the stable operation of the application. In the prior art, front-end testing and back-end testing are usually carried out through automated test scripts of the test device 13 and the user interface (UI) automation testing tool, as well as back-end interface test scripts. However, when performing front-end testing and back-end testing in the prior art, the scripts are basically executed separately at a fixed time. When the script reports an error, the error code is automatically classified. For scripts suspected of program problems, the cause of the error is analyzed in detail based on the log.
[0038] However, when executing the front-end and back-end test scripts separately, when an exception occurs on one end, false success is likely to occur because the processing status of the other end cannot be determined in time. Therefore, problems cannot be discovered in time and risks cannot be avoided in time.
[0039] The testing method for front-end and back-end business processes provided in this application aims to build a complete front-end and back-end business process by matching the front-end navigation components and the back-end business nodes, and then test the front-end and back-end business processes through test scripts to solve the above technical problems of the existing technology.
[0040] First, let’s explain the terms used in this application:
[0041] Unique identifier: An identifier that uniquely identifies an object, entity, or record. It can be any identifier and is typically used to ensure that each object is unique within a specific context.
[0042] The following specific embodiments describe in detail the technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0043] Figure 2 A schematic diagram of a front-end and back-end business process testing method provided in an embodiment of the present application Figure 1 The execution subject of this embodiment may be, for example, Figure 1 The test setup shown, Figure 1 As shown, the method includes:
[0044] S201: In response to a user operation request, obtain a front-end navigation component corresponding to the user operation request;
[0045] User operation requests refer to instructional data generated when performing user operations on the user interface, which trigger back-end data processing on the server. User operations can be simulated using user interface (UI) automation testing tools or performed by human testers. User operation requests can include account login, receiving and transferring money, and so on.
[0046] The front-end navigation component refers to the visual page elements in the user interface that provide information for executing user operations. For example, when performing a login operation, the front-end navigation component includes the login menu and the login button; when performing a message transfer entry, the front-end navigation component includes the message details page, the transfer entry button, the transfer entry menu, the confirm button, the message transfer review menu, the approved review button, the message review page, the message transfer authorization menu, and the approved authorization button.
[0047] When a user action occurs on the user interface, a user action request is generated, along with a unique identifier corresponding to the user action request. To obtain the front-end navigation component corresponding to the user action request, you can use a screen recording tool to record the user action. Alternatively, you can use a UI testing framework to locate elements through scripts to obtain the corresponding front-end navigation component.
[0048] S202, determining a business log from a log system, and extracting a plurality of back-end business nodes from the business log;
[0049] Among them, the business log is used to indicate the log containing the unique identifier corresponding to the user operation request, and the back-end business node is used to indicate the node corresponding to the unique identifier for executing back-end data processing. The back-end business node can be, for example, a compliance check, an interest check, a position check, a message accounting, etc.
[0050] The log system stores multiple logs related to test devices, user interfaces, and server operations. Based on the unique identifier corresponding to a user operation request, the system determines whether the log contains the unique identifier. If so, the log is determined to be a service log. From the multiple nodes in the service log, the node that triggers the unique identifier is identified as the backend service node.
[0051] S203: Match the front-end navigation component with multiple back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request;
[0052] Among them, matching processing refers to connecting the front-end navigation component and the back-end business node in series.
[0053] The front-end navigation component and the multiple back-end business nodes can be arranged in order according to their corresponding timestamps to determine the front-end and back-end business processes corresponding to the user operation request; the front-end navigation component and the multiple back-end business nodes can also be matched with the nodes with a trigger relationship between the front-end navigation component and the back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request according to the trigger relationship between the front-end navigation component and the multiple back-end business nodes.
[0054] For example, when the user operation request is a login request, the backend performs authentication processing according to the login request, and thus matches the frontend navigation component corresponding to the login request with the backend business node that performs authentication processing.
[0055] S204: Test the front-end and back-end business processes based on the test script corresponding to the user operation request.
[0056] In one possible implementation, the front-end and back-end business processes include multiple processing nodes. The test script corresponding to the user operation request is described in detail to test the front-end and back-end business processes, including:
[0057] Execute a test script corresponding to the user operation request; for any one of the multiple processing nodes, determine whether the processing node is normal; if so, perform a first marking process on the processing node; if not, perform a second marking process on the processing node.
[0058] By marking processing nodes differently, the results of front-end and back-end business process tests are intuitively reflected. When an exception is detected in the test script, staff can identify the error node by checking the markings of the entire back-end business process during the test, saving error analysis time.
[0059] In a possible implementation, the method further includes: when an exception is detected in the test script, extracting the second marked processing node and using the second marked processing node as an error reporting node, thereby saving error reporting analysis time.
[0060] This embodiment provides a testing method for front-end and back-end business processes, which responds to user operation requests, obtains the front-end navigation component corresponding to the user operation request, determines the business log from the log system, and extracts multiple back-end business nodes from the business log to provide data support for subsequent front-end and back-end testing; matches the front-end navigation component and multiple back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request, forming a complete business process, clearly showing the back-end processing process after a user operation request is performed on the business front-end, and testing the front-end and back-end business processes based on the test script corresponding to the user operation request, avoiding false success when an exception occurs on one end, and helping to discover problems and avoid risks in a timely manner.
[0061] Figure 3 A schematic diagram of a front-end and back-end business process testing method provided in an embodiment of the present application Figure 2 In this embodiment, the front-end navigation component includes an operation menu and a navigation button corresponding to the operation menu. Figure 2 Based on the embodiment, the front-end navigation component and multiple back-end business nodes are matched and processed to determine the front-end and back-end business processes corresponding to the user operation request. Figure 3 As shown, the method includes:
[0062] S301: Determine the front-end business process corresponding to the user operation request based on the operation menu and navigation button;
[0063] Among them, the front-end business process refers to the process in which users perform orderly operations in the user interface to achieve business goals.
[0064] Based on the operation menu, navigation buttons and the user's operation sequence, determine the front-end business process corresponding to the user operation request.
[0065] Exemplary: Figure 4 A user operation diagram provided in an embodiment of the present application is as follows: Figure 4 As shown, Figure 4 The operation menu of a is "Message Processing Menu", which includes multiple services. The user clicks service 1 to enter the following menu: Figure 4 Click the navigation button "Transfer Entry" on the message details page as shown in b in the figure to enter the following Figure 4 After completing the transfer entry page, click on the transfer entry page shown in c. Figure 4 Click the navigation button "OK" shown in c to complete the business submission and enter the Figure 4 The operation menu shown in d is the page of "Receipt and Transfer Review Menu". After querying business 1 in the "Receipt and Transfer Review Menu", click business 1 to enter the following Figure 4Click the navigation button "Review Pass" on the message review page to submit the business successfully; enter the operation menu "Receiving and Transfer Authorization Menu", and after querying business 1 in the "Receiving and Transfer Authorization Menu", click business 1 to enter the following Figure 4 The message authorization page shown in Figure f; on the message authorization page, click the navigation button "Authorization Passed" to submit the business successfully, and the front-end page operation is completed.
[0066] In a possible implementation, the operation menu includes at least one submenu, combined with Figure 4 The front-end business process for determining the corresponding user operation request based on the operation menu and navigation button is described in detail, including:
[0067] Determine a first menu from at least one submenu, and determine a front-end business process according to a first navigation button corresponding to the first menu;
[0068] Among them, the first menu is the starting menu, for example Figure 4 The message processing menu shown in a.
[0069] A first menu is determined from at least one submenu, and according to a first navigation button corresponding to the first menu, a front-end business process is determined to be {first menu>-first navigation button}.
[0070] For example: Figure 4 The user operation diagram shown in the figure determines that the front-end business process is {Receiving Processing Menu>-Remittance Entry}.
[0071] Determine whether at least one submenu is in the front-end business process; if at least one submenu is in the front-end business process, determine the second menu; based on the first menu, the first navigation button, the second menu and the second navigation button corresponding to the second menu, update the front-end business process until at least one submenu is in the front-end business process.
[0072] The second menu is obtained by jumping to the first menu by pressing the first navigation button;
[0073] Determine whether all submenus are in the front-end business process. If not, continue to determine whether the submenu obtained by operating the first navigation is the second menu, and the navigation button corresponding to the second menu is the second navigation button. Figure 4The "Remittance Entry Menu" shown in c is the second menu, and the second navigation button is "OK." The front-end business process is now {Message Receipt Processing Menu > Remittance Entry > Remittance Entry Menu > OK}. Continue to confirm the second menu and the corresponding second navigation button until all submenus are within the front-end business process. The final front-end business process is {Message Receipt Processing Menu > Remittance Entry > Remittance Entry Menu > OK > Message Remittance Verification Menu > Verification Approved > Message Authorization Menu > Authorization Approved}.
[0074] By determining the front-end business process, data support is provided for the subsequent determination of the front-end and back-end business processes and the front-end and back-end testing.
[0075] S302: Determine a backend business process corresponding to the user operation request based on multiple backend business nodes and corresponding timestamps;
[0076] In one possible implementation, backend business nodes include phase nodes and branch nodes. Phase nodes refer to the main process (phase) of each application module; different scenario branches (steps) under the phase nodes are branch nodes. Different scenarios under the main process execute different scenario branch steps. A detailed description of the extraction of multiple backend business nodes from business logs includes:
[0077] Acquire multiple backend business nodes recorded in the business log; for any one of the multiple backend business nodes, determine whether the backend business node is a stage node; if the backend business node is a stage node, determine the branch node corresponding to the stage node from the multiple backend business nodes;
[0078] The branch node is used to indicate the backend business node that has a calling relationship with the stage node.
[0079] By determining the branch nodes and stage nodes, it is easy to directly determine the error reporting node during testing, which is conducive to improving testing efficiency.
[0080] In one possible implementation, the backend business process for determining the corresponding backend business request of the user operation request based on multiple backend business nodes and corresponding timestamps is described in detail, including:
[0081] Based on the stage nodes and the branch nodes corresponding to the stage nodes, the sub-processes are determined; according to the timestamps corresponding to the multiple stage nodes, the sub-processes corresponding to the multiple stage nodes are spliced to obtain the back-end business process corresponding to the user operation request.
[0082] Exemplary: Figure 5 This is a schematic diagram of a backend business process provided by an embodiment of the present application. Figure 5As shown, phase is used to indicate the phase node, and step is used to indicate the branch node. It includes phase nodes: compliance check, interest check, position check, message recording, and branch nodes: insufficient position, sufficient position, insufficient position return. If the front-end user completes the message receiving authorization, it will enter the following steps respectively. Figure 5 As shown in the compliance check, value interest check, position check, message sending and accounting phase nodes, each phase node phase will also have different branch nodes step, for example, in the position check phase, if the message sending position is sufficient, it will enter the message sending position sufficient step, otherwise, it will enter the position insufficient step. At this time, there are two ways to handle it. One is to enter the position processing menu on the front-end page, and the user clicks the navigation button "Release". After the processing is successful, it will enter the position insufficient release step. If the navigation button "Return" is clicked, the message will enter the position insufficient return step, and the status will return to the message receiving and remittance modification menu; the other is to wait for the back-end automatic processing. After the position is replenished, the back-end scan meets the conditions and the automatic processing is successful, and then enter the message sending and accounting phase. In this way, the construction of the back-end business process of a business is completed.
[0083] By building business backend processes, it is possible to accurately locate abnormal nodes during testing, which helps improve testing efficiency.
[0084] S303: Match the front-end business process and the back-end business process to determine the front-end and back-end business processes corresponding to the user operation request.
[0085] In one possible implementation, the front-end navigation component includes a state component, which is used to interact with the back-end business process, match the front-end business process with the back-end business process, and determine the front-end and back-end business processes corresponding to the user operation request. The detailed description includes:
[0086] Based on the end navigation button of the front-end business process and the back-end business process, temporary front-end and back-end business processes are obtained by splicing; based on the association relationship between the state component and the back-end business process, the state component is matched with the front-end business process to update the temporary front-end and back-end business processes to obtain the front-end and back-end business processes.
[0087] According to the front-end operation menu and navigation button corresponding to the same unique identifier, as well as the back-end stage node and branch node, the end navigation button of the front-end business process is spliced with the response starting point of the back-end business process to obtain a temporary front-end and back-end business process. Based on the association relationship between the state component and the back-end business process, the state component is matched with the front-end business process to update the temporary front-end and back-end business process to obtain the front-end and back-end business process.
[0088] Exemplary: Figure 6 A schematic diagram of a front-end and back-end business process provided in an embodiment of the present application, such as Figure 6 As shown, the terminal navigation button in the front-end business process {Receipt Processing Menu > Remittance Entry > Remittance Entry Menu > Confirmation > Receipt and Remittance Review Menu > Verification Approved > Message Authorization Menu > Authorization Approved} is spliced with the response starting point "Compliance Check" of the back-end business process to obtain a temporary front-end and back-end business process. Then, based on the relationship between the status component "Insufficient Position Menu" and the back-end business process, for example, when the position is insufficient, the insufficient position menu is entered. The temporary front-end and back-end business process is updated. The front-end and back-end business process is obtained, as shown in the figure. Figure 6 As shown, when the position is sufficient, the front-end and back-end business processes are {Receipt Processing Menu > Remittance Entry > Remittance Entry Menu > Confirm > Receipt Remittance Review Menu > Verification Approved > Message Authorization Menu > Authorization Approved > Compliance Check > Value Interest Check > Position Check > Sufficient Position > Send Message Accounting}.
[0089] By building front-end and back-end business processes, the efficiency of subsequent testing is improved, which is conducive to accurately locating problems and ensuring the comprehensiveness of testing.
[0090] An embodiment of the present application provides a testing method for front-end and back-end business processes, which determines the front-end business process corresponding to the user operation request through operation menus and navigation buttons, focuses on user experience design, and helps optimize user experience; determines the back-end business process corresponding to the user operation request based on multiple back-end business nodes and corresponding timestamps, and determines the back-end business process according to the time sequence relationship, ensuring the accuracy and completeness of the back-end business process construction; matches the front-end business process and the back-end business process, determines the front-end and back-end business process corresponding to the user operation request, and constructs an end-to-end closed-loop front-end and back-end business process, providing data support for subsequent front-end and back-end business process testing, which is conducive to achieving full-link monitoring and problem tracking.
[0091] Figure 7 A schematic diagram of a front-end and back-end business process testing device provided in an embodiment of the present application is shown in FIG. Figure 7 As shown, the front-end and back-end business process testing device 70 provided in this embodiment includes:
[0092] The acquisition module 701 is used to acquire the front-end navigation component corresponding to the user operation request in response to the user operation request;
[0093] Processing module 702 is used to determine a business log from the log system and extract multiple backend business nodes from the business log, where the business log is used to indicate a log containing a unique identifier corresponding to the user operation request;
[0094] The processing module 702 is further used to match the front-end navigation component with multiple back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request;
[0095] The testing module 703 is used to test the front-end and back-end business processes based on the test script corresponding to the user operation request.
[0096] In one possible implementation, the front-end navigation component includes an operation menu and a navigation button corresponding to the operation menu. The processing module 702 is also used to determine the front-end business process corresponding to the user operation request based on the operation menu and the navigation button; determine the back-end business process corresponding to the user operation request based on multiple back-end business nodes and corresponding timestamps; match the front-end business process and the back-end business process to determine the front-end and back-end business processes corresponding to the user operation request.
[0097] In one possible implementation, the backend business node includes a stage node and a branch node. The processing module 702 is further used to obtain multiple backend business nodes recorded in the business log; for any one of the multiple backend business nodes, determine whether the backend business node is a stage node; if the backend business node is a stage node, determine the branch node corresponding to the stage node from the multiple backend business nodes, and the branch node is used to indicate the backend business node that has a call relationship with the stage node.
[0098] In one possible implementation, the processing module 702 is also used to determine the sub-process based on the stage node and the branch node corresponding to the stage node; according to the timestamps corresponding to the multiple stage nodes, the sub-processes corresponding to the multiple stage nodes are spliced to obtain the back-end business process corresponding to the user operation request.
[0099] In one possible implementation, the operation menu includes at least one submenu, and the processing module 702 is further used to determine the first menu from the at least one submenu, and determine the front-end business process based on the first navigation button corresponding to the first menu; determine whether at least one submenu is in the front-end business process; if at least one submenu is in the front-end business process, determine the second menu, and the second menu is obtained by jumping after operating the navigation button of the first menu; based on the first menu, the first navigation button, the second menu and the second navigation button corresponding to the second menu, update the front-end business process until at least one submenu is in the front-end business process.
[0100] In one possible implementation, the front-end navigation component includes a state component, a processing module 702, and is also used to splice the end navigation button and the back-end business process based on the front-end business process to obtain a temporary front-end and back-end business process; based on the association relationship between the state component and the back-end business process, the state component is matched with the front-end business process to update the temporary front-end and back-end business process to obtain the front-end and back-end business process.
[0101] In one possible implementation, the front-end and back-end business processes include multiple processing nodes, and the test module is used to execute the test script corresponding to the user operation request; for any one of the multiple processing nodes, it is determined whether the processing node is processing normally; if so, the processing node is subjected to a first marking process; if not, the processing node is subjected to a second marking process.
[0102] The testing device for the front-end and back-end business processes provided in this embodiment can execute the method provided in the above method embodiment. Its implementation principle and technical effects are similar, and are not described in detail in this embodiment.
[0103] Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. Figure 8 As shown, the electronic device 80 provided in this embodiment includes: at least one processor 801 and a memory 802. Optionally, the device 80 also includes a communication component 803. The processor 801, the memory 802 and the communication component 803 are connected via a bus 804.
[0104] During the specific implementation process, at least one processor 801 executes the computer-executable instructions stored in the memory 802, so that the at least one processor 801 performs the above method.
[0105] The specific implementation process of the processor 801 can be found in the above method embodiment. Its implementation principle and technical effects are similar and will not be repeated here in this embodiment.
[0106] In the above embodiments, it should be understood that the processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASICs), etc. A general-purpose processor may be a microprocessor or any conventional processor. The steps of the method disclosed in the present invention may be directly executed by a hardware processor or by a combination of hardware and software modules within the processor.
[0107] The memory may include random access memory (RAM) and may also include non-volatile memory (NVM), such as at least one disk storage.
[0108] A bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus. Buses can be categorized as address buses, data buses, and control buses. For ease of illustration, the buses in the drawings of this application are not limited to just one bus or just one type of bus.
[0109] The present application also provides a computer program product, including a computer program, which implements the above method when executed by a processor.
[0110] The present application also provides a computer-readable storage medium, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the above method is implemented.
[0111] If an integrated unit / module is implemented in hardware, the hardware may be digital circuits, analog circuits, etc. The physical implementation of the hardware structure includes, but is not limited to, transistors, memristors, etc. Unless otherwise specified, the processor may be any appropriate hardware processor, such as a CPU, GPU, FPGA, DSP, and ASIC. Unless otherwise specified, the storage unit may be any appropriate magnetic storage medium or magneto-optical storage medium, such as resistive random access memory (RRAM), dynamic random access memory (DRAM), static random access memory (SRAM), enhanced dynamic random access memory (EDRAM), high-bandwidth memory (HBM), hybrid memory cube (HMC), etc.
[0112] If the integrated unit / module is implemented in the form of a software program module and sold or used as an independent product, it can be stored in a computer-readable memory. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a memory and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the various embodiments of the present application.
[0113] It should be noted that for the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that this application is not limited by the order of the actions described, because according to this application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in this specification are all optional embodiments, and the actions and modules involved are not necessarily required by this application.
[0114] It should be further noted that, although the various steps in the flowchart are shown in sequence as indicated by the arrows, these steps are not necessarily performed in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and these steps may be performed in other orders. Moreover, at least a portion of the steps in the flowchart may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily performed at the same time, but may be performed at different times. The execution order of these sub-steps or stages is not necessarily to be performed in sequence, but may be performed in turn or alternately with other steps or at least a portion of the sub-steps or stages of other steps.
[0115] It should be understood that the above-described device embodiments are merely illustrative, and the device of the present application may also be implemented in other ways. For example, the division of units / modules in the above-described embodiments is merely a logical functional division, and actual implementations may employ other division methods. For example, multiple units, modules, or components may be combined or integrated into another system, or some features may be omitted or not implemented.
[0116] In addition, unless otherwise specified, the functional units / modules in the various embodiments of the present application may be integrated into a single unit / module, each unit / module may exist physically separately, or two or more units / modules may be integrated together. The aforementioned integrated units / modules may be implemented in the form of hardware or software program modules.
[0117] In the above embodiments, the description of each embodiment has its own emphasis. For parts not described in detail in a particular embodiment, please refer to the relevant description of other embodiments. The technical features of the above embodiments can be combined in any way. To keep the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0118] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the present application that follow the general principles of the present application and include common knowledge or customary techniques in the art not disclosed herein. The description and examples are to be considered as exemplary only, and the true scope and spirit of the present application are indicated by the following claims.
[0119] It should be understood that the present application is not limited to the exact structure described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.
Claims
1. A testing method for front-end and back-end business processes, characterized in that: include: In response to a user operation request, obtaining a front-end navigation component corresponding to the user operation request; Determine a business log from a log system, and extract multiple backend business nodes from the business log, wherein the business log is used to indicate a log containing a unique identifier corresponding to the user operation request; Matching the front-end navigation component with the multiple back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request; The front-end and back-end business processes are tested based on the test script corresponding to the user operation request.
2. The method according to claim 1, characterized in that The front-end navigation component includes an operation menu and a navigation button corresponding to the operation menu. The matching processing of the front-end navigation component and the plurality of back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request includes: Determining a front-end business process corresponding to the user operation request based on the operation menu and the navigation button; Determining a backend business process corresponding to the user operation request based on the multiple backend business nodes and corresponding timestamps; Matching processing is performed on the front-end business process and the back-end business process to determine the front-end and back-end business processes corresponding to the user operation request.
3. The method according to claim 1, characterized in that The backend service nodes include stage nodes and branch nodes, and the extracting multiple backend service nodes from the service log includes: Obtain multiple backend service nodes recorded in the service log; For any one of the multiple backend service nodes, determine whether the backend service node is a stage node; In the case that the backend service node is a stage node, a branch node corresponding to the stage node is determined from the multiple backend service nodes, and the branch node is used to indicate a backend service node that has a calling relationship with the stage node.
4. The method according to claim 3, characterized in that The determining, based on the multiple backend business nodes and corresponding timestamps, a backend business process corresponding to the user operation request includes: Determine a sub-process based on the stage node and the branch node corresponding to the stage node; According to the timestamps corresponding to the multiple stage nodes, the sub-processes corresponding to the multiple stage nodes are spliced together to obtain the back-end business process corresponding to the user operation request.
5. The method according to claim 2, characterized in that The operation menu includes at least one submenu, and determining the front-end business process corresponding to the user operation request based on the operation menu and the navigation button includes: Determining a first menu from the at least one submenu, and determining a front-end business process according to a first navigation button corresponding to the first menu; Determining whether the at least one submenu is in the front-end business process; In a case where the at least one submenu is in the front-end business process, determining a second menu, where the second menu is obtained by jumping after operating a navigation button of the first menu; Based on the first menu, the first navigation button, the second menu, and the second navigation button corresponding to the second menu, the front-end business process is updated until the at least one submenu is in the front-end business process.
6. The method according to claim 2, characterized in that The front-end navigation component includes a state component. The matching process between the front-end business process and the back-end business process to determine the front-end and back-end business processes corresponding to the user operation request includes: Based on the end navigation button of the front-end business process and the back-end business process, a temporary front-end and back-end business process is obtained; Based on the association relationship between the state component and the backend business process, the state component is matched with the frontend business process to update the temporary frontend and backend business processes to obtain the frontend and backend business processes.
7. The method according to claim 1, characterized in that The front-end and back-end business processes include multiple processing nodes, and the testing of the front-end and back-end business processes based on the test script corresponding to the user operation request includes: Execute the test script corresponding to the user operation request; For any one of the plurality of processing nodes, determining whether the processing of the processing node is normal; If yes, performing a first marking process on the processing node; If not, perform a second marking process on the processing node.
8. A testing device for front-end and back-end business processes, characterized in that: include: An acquisition module, in response to a user operation request, configured to acquire a front-end navigation component corresponding to the user operation request; a processing module, configured to determine a business log from a log system and extract a plurality of backend business nodes from the business log, wherein the business log is used to indicate a log containing a unique identifier corresponding to the user operation request; The processing module is further configured to perform matching processing on the front-end navigation component and the plurality of back-end business nodes to determine the front-end and back-end business processes corresponding to the user operation request; The testing module is used to test the front-end and back-end business processes based on the test script corresponding to the user operation request.
9. An electronic device, characterized in that: include: a processor, and a memory communicatively connected to the processor; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory to implement the method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer-executable instructions, which are used to implement the method according to any one of claims 1 to 7 when executed by a processor.
11. A computer program product, characterized in that The invention comprises a computer program, which implements the method according to any one of claims 1 to 7 when being executed by a processor.