CN-121979770-A - Test review method and device
Abstract
The application provides a test review method which can be applied to the technical field of artificial intelligence. The method comprises the steps of determining target test cases for achieving target business requirements in N test cases to be screened based on a large language model, determining target execution logs generated by executing the target test cases in M execution logs to be screened, wherein N and M are positive integers, and determining test review results based on the large language model according to the target business requirements, the target test cases and the target execution logs. The application also provides a test review device, equipment, a storage medium and a program product.
Inventors
- SUN YUAN
- ZHANG ZHAN
- WANG JINGKAI
- WANG JINGYUAN
Assignees
- 中国工商银行股份有限公司
Dates
- Publication Date
- 20260505
- Application Date
- 20250630
Claims (14)
- 1. A test review method, the method comprising: Aiming at target service demands, determining target test cases for realizing the target service demands from N test cases to be screened based on a large language model, and determining target execution logs generated by executing the target test cases from M execution logs to be screened; And determining a test review result based on a large language model aiming at the target business requirement, the target test case and the target execution log.
- 2. The method according to claim 1, wherein the method further comprises: Clustering is carried out aiming at the acquired business requirements, test cases and execution logs, and clustering results are obtained; The N test cases to be screened comprise test cases belonging to the same cluster with the target service requirement in the clustering result; the M execution logs to be screened comprise execution logs belonging to the same cluster with the target service requirement in the clustering result.
- 3. The method according to claim 1, wherein the method further comprises: updating a preset knowledge graph based on the target business requirement, the target test case and the target execution log, wherein the preset knowledge graph is at least used for representing the association relationship among any two of the business requirement, the test case and the execution log; the determining a test review result based on a large language model for the target business requirement, the target test case and the target execution log includes: and aiming at the target business requirements, the target test cases and the target execution logs, determining a test review result based on a large language model according to the updated preset knowledge graph.
- 4. The method of claim 3, wherein the updated preset knowledge-graph comprises at least one of: A target demand node for characterizing the target business demand; the target log node is used for representing the target execution log; An edge between the target demand node and the target case node for characterizing the target test case for implementing the target business demand, and And the edge between the target case node and the target log node is used for representing and executing the target test case to generate the target execution log.
- 5. The method of claim 1, wherein the determining test review results based on a large language model for the target business requirements, the target test cases, and the target execution log comprises: Determining a test review result based on a large language model aiming at the target service requirement, the target test case, the target execution log and service related personnel information; the business related personnel information comprises at least one of related personnel information of the target business requirement, related personnel information of the target test case and related personnel information of the target execution log.
- 6. The method of claim 5, wherein the method further comprises: updating a preset knowledge graph based on the target service requirement, the target test case, the target execution log and service related personnel information, wherein the preset knowledge graph is at least used for representing the association relationship among any two of the service requirement, the test case, the execution log and the service related personnel; The determining a test review result based on a large language model aiming at the target service requirement, the target test case, the target execution log and service related personnel information comprises the following steps: And aiming at the target service requirement, the target test case, the target execution log and the service related personnel information, determining a test review result based on a large language model according to the updated preset knowledge graph.
- 7. The method according to claim 3 or 6, wherein the preset knowledge-graph comprises at least one of the following: A demand node for characterizing business demands; the case node is used for representing the test case; the system comprises a log node, a personnel node, an object node, a defect node, a fault node, a test object node, a fault node and a test platform, wherein the log node is used for representing an execution log; the edge between the demand node and the use case node is used for representing that the test use case represented by the use case node is used for realizing the service requirement represented by the demand node; the edge between the case node and the log node is used for representing that the test case represented by the case node is executed to generate an execution log represented by the log node; The edge between the case node and the object node is used for representing that the test case represented by the case node is used for testing the test object represented by the object node; The edge between the log node and the defect node is used for representing that the defect type represented by the defect node exists in an execution log represented by the log node; and the edge between the personnel node and any other node is used for representing that the service related personnel represented by the personnel node are related to the representation content of the other node.
- 8. The method according to claim 3 or 6, wherein determining the test review result based on the large language model according to the updated preset knowledge-graph comprises: and determining a test review result based on the large language model according to the updated preset knowledge graph and the current historical updating condition of the preset knowledge graph.
- 9. The method according to claim 3 or 6, wherein determining the test review result based on the large language model according to the updated preset knowledge-graph comprises: and determining a test review result based on the large language model according to the updated nodes in the updated preset knowledge graph and other nodes and/or other edges related to the updated nodes.
- 10. The method of claim 1, wherein the test review results comprise at least one of: The method comprises the steps of covering the target test case, realizing the target service requirement, testing results of the target test case, testing risk information, supplementing suggestions of the test case, testing defect information and testing defect root cause analysis results.
- 11. A test review device, the device comprising: The screening unit is used for determining target test cases for testing the target service requirements in N test cases to be screened based on a large language model, and determining target execution logs generated by executing the target test cases in M execution logs to be screened; And the review unit is used for determining a test review result based on the large language model aiming at the target business requirement, the target test case and the target execution log.
- 12. An electronic device, comprising: One or more processors; a memory for storing one or more computer programs, Characterized in that the one or more processors execute the one or more computer programs to implement the steps of the method according to any one of claims 1 to 10.
- 13. A computer-readable storage medium, on which a computer program or instructions is stored, which, when executed by a processor, carries out the steps of the method according to any one of claims 1 to 10.
- 14. A computer program product comprising a computer program or instructions which, when executed by a processor, implement the steps of the method according to any one of claims 1 to 10.
Description
Test review method and device Technical Field The application relates to the technical field of artificial intelligence, in particular to a test review method and device. Background At present, the test of the test case often needs to be manually checked. For example. And judging the test result of the test case, determining whether the test case covers the test requirement, whether the test case covers all branch conditions in the process of executing the test case, and the like. But manually performing test reviews is inefficient. Disclosure of Invention In view of the foregoing, the present application provides a test review method, apparatus, device, medium, and program product that improve test review efficiency. According to the first aspect of the application, a test review method is provided, which comprises the steps of determining target test cases for realizing target service requirements in N test cases to be screened based on a large language model, and determining target execution logs for executing target test case generation in M execution logs to be screened, wherein N and M are positive integers; And determining a test review result based on a large language model aiming at the target business requirement, the target test case and the target execution log. Optionally, the method further comprises clustering the acquired service requirements, test cases and execution logs to obtain a clustering result, wherein the N test cases to be screened comprise test cases which belong to the same cluster with the target service requirements in the clustering result, and the M execution logs to be screened comprise execution logs which belong to the same cluster with the target service requirements in the clustering result. The method comprises the steps of updating a preset knowledge graph based on the target business requirement, the target test case and the target execution log, wherein the preset knowledge graph is at least used for representing the association relation among the business requirement, the test case and the execution log, determining a test review result based on a large language model aiming at the target business requirement, the target test case and the target execution log, and determining the test review result based on the large language model according to the updated preset knowledge graph. Optionally, the updated preset knowledge graph comprises at least one of a target demand node for representing the target service demand, a target use case node for representing the target test case, a target log node for representing the target execution log, an edge between the target demand node and the target use case node for representing the target test case for realizing the target service demand, and an edge between the target use case node and the target log node for representing the target test case for generating the target execution log. Optionally, the determining test review results based on the large language model aiming at the target business requirement, the target test case and the target execution log comprises determining test review results based on the large language model aiming at the target business requirement, the target test case and the target execution log and business related personnel information, wherein the business related personnel information comprises at least one of related personnel information of the target business requirement, related personnel information of the target test case and related personnel information of the target execution log. The method comprises the steps of updating a preset knowledge graph based on the target business requirement, the target test case, the target execution log and business related personnel information, wherein the preset knowledge graph is at least used for representing the association relation among any two of business requirement, test case, execution log and business related personnel, determining a test review result based on a large language model according to the target business requirement, the target test case, the target execution log and the business related personnel information, and determining the test review result based on the large language model according to the updated preset knowledge graph according to the target business requirement, the target test case, the target execution log and the business related personnel information. Optionally, the preset knowledge graph comprises at least one of a requirement node used for representing service requirements, a case node used for representing test cases, a log node used for representing execution logs, a personnel node used for representing service related personnel, an object node used for representing test objects, a defect node used for representing defect types, an edge between the requirement node and the case node used for representing the test cases represented by the case node and used for realizing the service requirements represented by