A method and system for generating a full-scene test case set based on a message log
By receiving configuration information and generating a full-scenario test case set, the problem of generating multiple transaction node test case sets in the existing technology is solved, and the test case sequence customization and scenario restoration are realized, reducing manual costs.
Patent Information
- Application Number
- CN202310789341.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-30
- Publication Date
- 2026-11-24
- Estimated Expiration
- 2043-06-30
AI Technical Summary
Existing technologies struggle to generate test case sets that cover multiple transaction nodes, and the sequence relationships between test cases are difficult to arrange according to actual needs, making it impossible to recreate the test scenario and resulting in high manual costs.
By receiving configuration information, determining the test scenario type and status, finding and packaging message logs, generating a single test scenario message log set, extracting data fields, generating a single test scenario test case set, and combining them into a full-scenario test case set, the test case generation process does not depend on the data platform.
It enables the generation of test case sets that span multiple transaction nodes. The test case sequence can be set according to business needs, avoiding duplication and automatically generating long-link test case sets, saving manual writing and maintenance costs.
Smart Images

Figure CN116881133B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of automated testing technology, and in particular to a method and system for generating a full-scenario test case set based on message logs. Background Technology
[0002] As banking operations become increasingly complex and cross-system business chains grow longer, the writing and maintenance of end-to-end test cases becomes more and more complicated, requiring significant manual labor costs. Currently, the data needed to generate banking business test cases mainly relies on test data provided by a data platform. The cost of writing and maintaining these cases is high, and existing methods for automatically generating test cases based on message logs can only cover a single transaction node, not multiple transaction nodes in long chains, severely limiting the number of nodes that can be automatically generated for scenario test cases. Even if test case sets covering multiple nodes can be generated, the sequence relationships between test cases are difficult to arrange according to actual needs, and the function of recreating test scenarios cannot be achieved.
[0003] Application No. 201911304492.2 discloses a method for parsing transaction message logs. This method can extract transaction data from the message logs and generate visualization results. However, this method can only generate a single test case for a single transaction node and cannot generate a test case set containing transaction data from multiple transaction nodes. Application No. 202211149764.8 discloses a method for generating test case sets. However, the sequence relationship between the test cases is generated based on a random algorithm, and the test case sequence is arbitrary. It is impossible to set the sequence relationship between test cases according to actual business needs. The generated test case set has weak practicality and cannot realize the function of reproducing test scenarios. Summary of the Invention
[0004] To address the shortcomings of existing technologies, this invention proposes a method and system for generating a full-scenario test case set based on message logs. The technical solution adopted in this invention includes:
[0005] In a first aspect, the present invention provides a method for generating a full-scenario test case set based on message logs, the method comprising:
[0006] S11. Receive configuration information, which includes node combination relationships and test scenario type status, and the test scenario type status is unmarked by default.
[0007] S12. Determine whether there is a test scenario type with an unmarked state. If there is a test scenario type with an unmarked state, proceed to step S13. If there is no test scenario type with an unmarked state, proceed to step S16.
[0008] S13. Select a message log under any of the test scenario types in the unmarked state as the selected message log, find and package all message logs of the test scenario where the selected message log is located according to the node combination relationship, and generate a single test scenario message log set.
[0009] S14. Extract the data fields from the message log set of the single test scenario to generate a normal test case set for the single test scenario;
[0010] S15. Mark the test scenario type corresponding to the normal test case set of the single test scenario, so that the status of the corresponding test scenario type changes from unmarked to marked, and repeat step S12.
[0011] S16. Combine all the generated individual test scenario normal test case sets to generate a full scenario normal test case set.
[0012] Secondly, the present invention also provides a system for generating a full-scenario test case set based on message logs. The system includes: a normal test case generation module, used to receive configuration information, the configuration information including node combination relationships and test scenario type status, the test scenario type status being unmarked by default; determine whether to enter the message log search module and send the configuration information to the message log search module; extract data fields from the message log set of a single test scenario to generate a normal test case set for a single test scenario; mark the test scenario type corresponding to the normal test case set of the single test scenario; combine all the generated normal test case sets of the single test scenario to generate a full-scenario normal test case set; and a message log search module, used to receive the configuration information sent by the normal test case generation module; arbitrarily select a message log under the unmarked test scenario type as a selected message log, search and package all message logs of the test scenario where the selected message log is located according to the node combination relationship, and generate a single test scenario message log set.
[0013] Thirdly, the present invention also provides a system for generating a full-scenario test case set based on message logs, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the method described in the first aspect.
[0014] The beneficial effects of the technical solution provided by this invention are:
[0015] The solution provided by this invention can generate test case sets spanning multiple transaction nodes. The test case set contains transaction data from multiple transaction nodes, and the sequence between each test case can be set according to actual business needs. It can realize the function of reproducing test scenarios. While exhausting the types of test case scenarios, it can also avoid the problem of test cases of the same type of scenario appearing repeatedly. The test case generation process does not rely on the data platform and can automatically generate long-link test case sets, which greatly saves the cost of manually writing and maintaining test case sets. Attached Figure Description
[0016] To more clearly illustrate the technical solutions in this invention, the accompanying drawings used in the description of this invention will be briefly introduced below.
[0017] Figure 1 A flowchart illustrating a method for generating a full-scenario test case set based on message logs provided by the present invention;
[0018] Figure 2 A flowchart illustrating step S13 of the present invention, which involves searching and packaging nodes based on their combination relationships.
[0019] Figure 3 A schematic diagram of the structure of a system for generating a full-scenario test case set based on message logs provided by the present invention;
[0020] Figure 4 A schematic diagram of the structure of an exemplary electronic device provided by the present invention. Detailed Implementation
[0021] This application provides a method for generating a full-scenario test case set based on message logs. This method can generate test case sets spanning multiple transaction nodes, containing transaction data from these nodes. The sequence of test cases can be customized according to actual business needs, enabling the reproduction of test scenarios. While exhaustively covering all test case scenario types, it also avoids the problem of duplicate test cases for the same scenario. The test case generation process does not rely on a data platform and can automatically generate long-link test case sets, significantly reducing the cost of manually writing and maintaining test case sets. The following will describe exemplary embodiments of this application in detail with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. It should be understood that this application is not limited to the exemplary embodiments described herein.
[0022] Application Overview
[0023] The data required to generate test cases for banking operations mainly relies on test data provided by the data platform. The cost of writing and maintaining test cases is high. Existing methods for automatically generating test cases based on message logs can only cover a single transaction node, not multiple transaction nodes in a long chain, severely limiting the number of nodes that can be automatically generated for scenario test cases. Even if test case sets covering multiple nodes can be generated, the sequence relationships between test cases are difficult to arrange according to actual needs, and the function of recreating test scenarios cannot be achieved.
[0024] To address the aforementioned technical problems, the overall approach of the technical solution provided in this application is as follows:
[0025] This application provides a method for generating a full-scenario test case set based on message logs, characterized by including:
[0026] S11. Receive configuration information, which includes node combination relationships and test scenario type status, and the test scenario type status is unmarked by default.
[0027] S12. Determine whether there is a test scenario type with an unmarked state. If there is a test scenario type with an unmarked state, proceed to step S13. If there is no test scenario type with an unmarked state, proceed to step S16.
[0028] S13. Select a message log under any of the test scenario types in the unmarked state as the selected message log, find and package all message logs of the test scenario where the selected message log is located according to the node combination relationship, and generate a single test scenario message log set.
[0029] S14. Extract the data fields from the message log set of the single test scenario to generate a normal test case set for the single test scenario;
[0030] S15. Mark the test scenario type corresponding to the normal test case set of the single test scenario, so that the status of the corresponding test scenario type changes from unmarked to marked, and repeat step S12.
[0031] S16. Combine all the generated individual test scenario normal test case sets to generate a full scenario normal test case set.
[0032] After introducing the basic principles of this application, various non-limiting embodiments of this application will be described in detail below with reference to the accompanying drawings.
[0033] Example 1
[0034] like Figure 1 As shown in the figure, this application provides a method for generating a full-scenario test case set based on message logs, the method including:
[0035] Step S11: Receive configuration information, which includes node combination relationships and test scenario type status. The test scenario type status is unmarked by default.
[0036] Specifically, the configuration information is configured by the user according to actual business needs when executing the method described in this embodiment. This includes node combination relationships and test scenario type status. Generally, the node combination relationship includes both the number of two or more nodes and the functional relationship between different nodes. The functional relationship between different nodes mainly includes the relationship between data fields under each node. Each data field under each node includes dictionary values, non-fixed values, and dictionary value status values. The user can configure non-fixed values with equivalent functional relationships for different nodes in the same test scenario as test scenario values, and further configure non-fixed values with arithmetic sequence relationships for different nodes in the same test scenario as node order values. This configures the functional relationship between different nodes and serves as the basis for subsequently searching all message logs of the same test scenario based on the node combination relationship. The test scenario type status is optional configuration information. It can be configured as a marked state or an unmarked state. If the test scenario type status is not configured, the default unmarked state is used.
[0037] Step S12: Determine whether there is a test scenario type with an unlabeled state. If there is a test scenario type with an unlabeled state, proceed to step S13. If there is no test scenario type with an unlabeled state, proceed to step S16.
[0038] Specifically, when a user executes the method described in this embodiment for the first time, there are usually test scenario types in an unmarked state, and then the user proceeds to step S13 to continue executing subsequent steps. Only when the method described in this embodiment has been executed two or more times, or when the user has configured all message log data test scenario types to a marked state in step S11, there may be no test scenario types in an unmarked state, and steps S13-S15 will be skipped, and step S16 will be executed directly.
[0039] Step S13: Select a message log under any of the test scenario types in the unmarked state as the selected message log, find and package all message logs of the test scenario where the selected message log is located according to the node combination relationship, and generate a single test scenario message log set;
[0040] Furthermore, such as Figure 2 As shown, the step of searching and packaging based on the node combination relationship further includes:
[0041] Step S1301: Locate the upstream transaction node message log of the test scenario where the selected message log is located based on the node combination relationship;
[0042] Step S1302: Based on the node combination relationship, find the downstream transaction node message log of the test scenario where the selected message log is located;
[0043] Step S1303: Arrange the upstream transaction node message log, the selected message log, and the downstream transaction node message log according to the order of their respective transaction nodes to obtain the message log arrangement order for a single test scenario;
[0044] Step S1304: According to the arrangement order of the message logs of the single test scenario, the upstream transaction node message logs, the selected message logs, and the downstream transaction node message logs are sequentially loaded into the message log set to generate the single test scenario message log set.
[0045] Specifically, when a user executes the method described in this embodiment for the first time, the process of searching and packaging according to the node combination relationship begins by searching and selecting the selected message log from the transaction node with the smallest node order value. Typically, the message log under the transaction node with the smallest node order value is the selected message log. In this case, step S1301 is often skipped, and steps S1302-S1304 are executed directly. The downstream transaction node message logs of the selected message log are searched sequentially according to the configured node combination relationship until the transaction node with the largest node order value is found, at which point the search step terminates. The found message logs are then arranged and packaged according to their node order values from smallest to largest to generate the single test scenario message log set. Only when the method described in this embodiment is executed two or more times, or when the user has configured some or all of the message log data test scenario type states to the marked state in step S11, may the selected message log be found outside the transaction node with the smallest node order value. In this case, steps S1301-S1304 need to be executed sequentially.
[0046] Step S14: Extract the data fields from the message log set of the single test scenario to generate a normal test case set for the single test scenario;
[0047] Furthermore, the data fields in the message log set include field dictionary values, field non-fixed values, and dictionary value status values. The test scenario type status defaults to an unmarked state, including the dictionary value status value defaulting to an unmarked state. Marking the test scenario type corresponding to the normal test case set of a single test scenario includes:
[0048] Change the dictionary value's state from unmarked to marked.
[0049] Furthermore, during the generation of the normal test case set for a single test scenario, the normal test case set for a single test scenario is named according to the extracted data fields to obtain the corresponding normal test name for the single test scenario.
[0050] Step S15: Mark the test scenario type corresponding to the normal test case set of the single test scenario, so that the status of the corresponding test scenario type changes from unmarked to marked, and repeat step S12.
[0051] Step S16: Combine all the generated individual test scenario normal test case sets to generate a full scenario normal test case set.
[0052] Furthermore, generating a full-scenario normal test case set also includes combining the normal test name of a single test scenario with the normal test case set of a single test scenario;
[0053] Step S17: Select one or more single-scenario normal test case sets from the generated full-scenario normal test case set, modify the data fields of the selected single-scenario normal test case set, and generate one or more corresponding single-scenario abnormal test case sets.
[0054] Furthermore, during the generation of the single test scenario exception test case set, the single test scenario exception test case set is named according to the extracted data fields to obtain the corresponding single test scenario exception test name;
[0055] Step S18: Combine all the normal test case sets of the single test scenario with all the abnormal test case sets of the single test scenario to generate a full-scenario test case set.
[0056] Furthermore, generating a full-scenario test case set also includes combining the individual test scenario exception test name with the individual test scenario exception test case set.
[0057] In summary, the method and system for generating a full-scenario test case set based on message logs provided in this application have the following technical effects:
[0058] The solution provided by this invention can generate test case sets spanning multiple transaction nodes. The test case set contains transaction data from multiple transaction nodes, and the sequence between each test case can be set according to actual business needs. It can realize the function of reproducing test scenarios. While exhausting the types of test case scenarios, it can also avoid the problem of test cases of the same type of scenario appearing repeatedly. The test case generation process does not rely on the data platform and can automatically generate long-link test case sets, which greatly saves the cost of manually writing and maintaining test case sets.
[0059] Example 2
[0060] Based on the same inventive concept as the method for generating a full-scenario test case set based on message logs in the foregoing embodiments, this invention also provides a system for generating a full-scenario test case set based on message logs, such as... Figure 3 As shown, the system includes:
[0061] The normal test case generation module 321 is used to receive configuration information, including node combination relationships and test scenario type status, wherein the test scenario type status is unmarked by default; determine whether to enter the message log search module 311 and send the configuration information to the message log search module 311; receive a single test scenario message log set sent by the message log search module 311, extract data fields from the single test scenario message log set, and generate a single test scenario normal test case set; mark the test scenario type corresponding to the single test scenario normal test case set; and combine all the generated single test scenario normal test case sets to generate a full scenario normal test case set.
[0062] The message log lookup module 311 is used to receive the configuration information sent by the normal test case generation module 321; arbitrarily select a message log under the unmarked test scenario type as the selected message log; search and package all message logs of the test scenario where the selected message log is located according to the node combination relationship; generate a single test scenario message log set; and send the generated single test scenario message log set to the normal test case generation module 321.
[0063] Furthermore, the system also includes:
[0064] The test case generation module 320 includes the normal test case generation module 321 and the abnormal test case generation module 322.
[0065] The abnormal test case generation module 322 is used to select one or more single test scenario normal test case sets from the generated full-scenario normal test case set, modify the data fields of the selected single test scenario normal test case set, and generate one or more corresponding single test scenario abnormal test case sets.
[0066] Furthermore, the system also includes:
[0067] The use case naming module 330 includes a normal use case naming module 331 and an abnormal use case naming module 332.
[0068] Normal test case naming module 331 is used to name the normal test case set of a single test scenario according to the extracted data fields during the generation process of the normal test case set of a single test scenario, so as to obtain the corresponding normal test name of a single test scenario.
[0069] The abnormal test case naming module 332 is used to name the abnormal test case set of a single test scenario according to the extracted data fields during the generation process of the abnormal test case set of a single test scenario, so as to obtain the corresponding abnormal test name of a single test scenario.
[0070] Furthermore, the system also includes:
[0071] The full test case generation module 341 is used to combine all the normal test case sets of the single test scenario with all the abnormal test case sets of the single test scenario to generate a full scenario test case set.
[0072] The generation of the full-scenario test case set also includes combining the normal test name of the single test scenario with the normal test case set of the single test scenario, and combining the abnormal test name of the single test scenario with the abnormal test case set of the single test scenario.
[0073] The foregoing Figure 1 The various variations and specific embodiments of the method for generating a full-scenario test case set based on message logs in Embodiment 1 are also applicable to the system for generating a full-scenario test case set based on message logs in this embodiment. Through the foregoing detailed description of the method for generating a full-scenario test case set based on message logs, those skilled in the art can clearly understand the implementation method of the system for generating a full-scenario test case set based on message logs in this embodiment. For the sake of brevity, it will not be described in detail here.
[0074] Exemplary electronic devices
[0075] The following is based on Figure 4 The electronic device described is an embodiment of this application.
[0076] Figure 4 A schematic diagram of the structure of an electronic device according to an embodiment of this application is shown.
[0077] Based on the inventive concept of the method for generating a full-scenario test case set based on message logs in the foregoing embodiments, the present invention also provides a system for generating a full-scenario test case set based on message logs, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement any of the steps of the aforementioned method for generating a full-scenario test case set based on message logs.
[0078] Among them, Figure 4 In this document, a bus architecture (represented by bus 400) is used. Bus 400 may include any number of interconnected buses and bridges, linking various circuits including one or more processors represented by processor 403 and memory represented by memory 404. Bus 400 may also link various other circuits such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and therefore will not be described further herein. Bus interface 406 provides an interface between bus 400 and receiver 401 and transmitter 402. Receiver 401 and transmitter 402 may be the same element, i.e., a transceiver, providing a unit for communicating with various other systems over a transmission medium.
[0079] The processor 403 is responsible for managing the bus 400 and general processing, while the memory 404 can be used to store the data used by the processor 403 when performing operations.
[0080] This invention provides a method for generating a full-scenario test case set based on message logs. The method includes: S11, receiving configuration information, the configuration information including node combination relationships and test scenario type status, the test scenario type status being unmarked by default; S12, determining whether there is an unmarked test scenario type, if there is, proceeding to step S13, if there is no unmarked test scenario type, proceeding to step S16; S13, arbitrarily selecting a message log under the unmarked test scenario type as the selected message log, based on... S14. Based on the node combination relationship, find and package all message logs of the selected message log in the test scenario to generate a single test scenario message log set; S15. Extract the data fields from the single test scenario message log set to generate a single test scenario normal test case set; S16. Mark the test scenario type corresponding to the single test scenario normal test case set, and change the test scenario type status from unmarked to marked, then return to step S2; S17. Combine all the generated single test scenario normal test case sets to generate a full-scenario normal test case set. This can generate test case sets spanning multiple transaction nodes, containing transaction data from multiple transaction nodes. The sequence between each test case can be set according to actual business needs, enabling the restoration of test scenarios. While exhaustively covering test case scenario types, it also avoids the problem of repeated test cases of the same type of scenario. The test case generation process does not rely on the data platform and can automatically generate long-link test case sets, greatly saving the cost of manually writing and maintaining test case sets.
[0081] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0082] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, systems, and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1One or more processes and / or boxes Figure 1 A system that specifies functions in one or more boxes.
[0083] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including an instruction set implemented in a process. Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0084] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the functions specified in one or more boxes. Although preferred embodiments of the invention have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of the invention.
[0085] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.
Claims
1. A method for generating a full-scenario test case set based on message logs, characterized in that, include: S11. Receive configuration information, which includes node combination relationships and test scenario type status, and the test scenario type status is unmarked by default. S12. Determine whether there is a test scenario type with an unmarked state. If there is a test scenario type with an unmarked state, proceed to step S13. If there is no test scenario type with an unmarked state, proceed to step S16. S13. Select a message log under any of the test scenario types in the unmarked state as the selected message log, find and package all message logs of the test scenario where the selected message log is located according to the node combination relationship, and generate a single test scenario message log set. S14. Extract the data fields from the message log set of the single test scenario to generate a normal test case set for the single test scenario; S15. Mark the test scenario type corresponding to the normal test case set of the single test scenario, so that the status of the corresponding test scenario type changes from unmarked to marked, and repeat step S12. S16. Combine all the generated single-scenario normal test case sets to generate a full-scenario normal test case set. Step S13, which involves searching and packaging based on the node combination relationship, includes: S1301. Based on the node combination relationship, find the upstream transaction node message log of the test scenario where the selected message log is located; S1302. Based on the node combination relationship, find the downstream transaction node message log of the test scenario where the selected message log is located; S1303. Arrange the upstream transaction node message log, the selected message log, and the downstream transaction node message log according to the order of their respective transaction nodes to obtain the message log arrangement order for a single test scenario. S1304. According to the arrangement order of the message logs of the single test scenario, the upstream transaction node message logs, the selected message logs, and the downstream transaction node message logs are sequentially loaded into the message log set to generate the single test scenario message log set.
2. The method according to claim 1, characterized in that, The method further includes: S17. Select one or more single-scenario normal test case sets from the generated full-scenario normal test case set, modify the data fields of the selected single-scenario normal test case set, and generate one or more corresponding single-scenario abnormal test case sets. S18. Combine all the normal test case sets of the individual test scenarios with all the abnormal test case sets of the individual test scenarios to generate a full-scenario test case set.
3. The method according to claim 1, characterized in that, The data fields in the message log set include dictionary values, non-fixed values, and dictionary value status values. The test scenario type status defaults to an unmarked state, including the dictionary value status value. Marking the test scenario type corresponding to the normal test case set of a single test scenario includes: Change the dictionary value's state from unmarked to marked.
4. The method according to claim 3, characterized in that, The method further includes: During the generation of the normal test case set for a single test scenario, the normal test case set for a single test scenario is named according to the extracted data fields to obtain the corresponding normal test name for the single test scenario. During the generation of the single test scenario exception test case set, the single test scenario exception test case set is named according to the extracted data fields to obtain the corresponding single test scenario exception test name; The generation of the full-scenario normal test case set also includes combining the normal test name of the individual test scenario with the normal test case set of the individual test scenario; The generation of the full-scenario test case set also includes combining the single test scenario exception test name with the single test scenario exception test case set.
5. A system for generating a full-scenario test case set based on message logs, wherein, The system includes: The normal test case generation module receives configuration information, including node combination relationships and test scenario type status, where the test scenario type status is unmarked by default; determines whether to enter the message log search module and sends the configuration information to the message log search module; receives a single test scenario message log set sent by the message log search module, extracts data fields from the single test scenario message log set, and generates a single test scenario normal test case set; marks the test scenario type corresponding to the single test scenario normal test case set; and combines all the generated single test scenario normal test case sets to generate a full-scenario normal test case set. The message log lookup module is used to receive the configuration information sent by the normal test case generation module; arbitrarily select a message log under the test scenario type of the unmarked state as the selected message log; search and package all message logs of the test scenario where the selected message log is located according to the node combination relationship; generate a single test scenario message log set; and send the generated single test scenario message log set to the normal test case generation module. The step of searching and packaging according to the node combination relationship includes: Based on the node combination relationship, locate the upstream transaction node message log of the test scenario where the selected message log is located; Based on the node combination relationship, locate the downstream transaction node message log of the test scenario where the selected message log is located; The upstream transaction node message logs, the selected message logs, and the downstream transaction node message logs are arranged according to the order of their respective transaction nodes to obtain the message log arrangement order for a single test scenario. Based on the order of the message logs in the single test scenario, the upstream transaction node message logs, the selected message logs, and the downstream transaction node message logs are sequentially loaded into the message log set to generate the single test scenario message log set.
6. The system according to claim 5, characterized in that, The system also includes a test case generation module, which includes a normal test case generation module and an abnormal test case generation module. The abnormal test case generation module includes a function to select one or more normal test case sets for a single test scenario from the generated normal test case set for the entire scenario, modify the data fields of the selected normal test case set for the single test scenario, and generate one or more abnormal test case sets for the corresponding single test scenario.
7. The system according to claim 5, characterized in that, The system also includes a use case naming module, which includes: The normal test case naming module is used to name the normal test case set of a single test scenario based on the extracted data fields during the generation process of the normal test case set of the single test scenario, so as to obtain the corresponding normal test name of the single test scenario. The exception test case naming module is used to name the exception test case set of a single test scenario based on the extracted data fields during the generation process of the exception test case set of a single test scenario, so as to obtain the corresponding exception test name of a single test scenario.
8. The system according to claim 7, characterized in that, The system also includes: The full test case generation module is used to combine all the normal test case sets of the single test scenario with all the abnormal test case sets of the single test scenario to generate a full scenario test case set; The generation of the full-scenario test case set also includes combining the normal test name of the single test scenario with the normal test case set of the single test scenario, and combining the abnormal test name of the single test scenario with the abnormal test case set of the single test scenario.
9. A system for generating a full-scenario test case set based on message logs, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein, When the processor executes the program, it implements the steps of the method according to any one of claims 1-4.
Citation Information
Patent Citations
Transaction message log analysis method and device
CN111061696A
Test case set generation method and device, computer equipment and storage medium
CN115422080A
Test case generation method, device and system
CN108319547A
Test case generation method and device for order distribution service, electronic equipment and medium
CN111797022A
