A core case determination method and device, electronic equipment and storage medium
By acquiring code branch coverage information and feature mapping rules of regression test cases in financial systems, and combining them with clustering algorithms, a core case set is determined. This solves the problems of arbitrariness and error in case selection in existing technologies, and improves the accuracy and efficiency of testing.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-31
- Publication Date
- 2026-06-30
AI Technical Summary
In existing technologies, the selection of regression test cases for financial systems lacks objective indicators, leading to arbitrariness and errors, reducing the accuracy and efficiency of testing, and increasing human and time costs.
By obtaining the code branch coverage information of the test cases, and using the code branch coverage feature mapping rules and preset clustering algorithms, the code branch features and classification categories of the test cases are determined, and the core case set with the strongest representativeness and highest discriminative power is selected.
It enables efficient and objective selection of core cases, improves the accuracy and efficiency of transaction-level regression testing, saves manpower and time costs, and enhances testing quality and standardization.
Smart Images

Figure CN115629988B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computer technology, and in particular to a method, apparatus, electronic device, and storage medium for determining core cases. Background Technology
[0002] As financial systems grow increasingly large and financial business rules become more complex, testers often need a framework when analyzing financial business and system logic. One crucial dimension is transactions. The system's underlying layer consists of code written in various programming languages, while the upper layer, facing the client, comprises functional modules organized according to business functions. Between these two layers lies the transaction layer.
[0003] In existing technologies, conventional regression testing typically targets different functional modules, aiming to cover the code of the regressed module as completely as possible. For selecting test cases, the usual practice is for users to choose based on their own understanding or experience, providing only some selection criteria or objective data for users to choose from based on their own judgment and experience. There is no quantifiable objective indicator or scientific calculation method to determine the representativeness of the selected cases, thus increasing manpower and time costs. Furthermore, the selected cases are inherently arbitrary and prone to error, resulting in extremely low accuracy. Summary of the Invention
[0004] In view of this, the present invention provides a core case determination method, apparatus, electronic device and storage medium, which can efficiently, quickly and objectively obtain the most representative and discriminative core cases, avoid the arbitrariness and error in core case selection, effectively improve the accuracy and efficiency of transaction-level regression test case selection, save manpower and time costs, and improve test quality and standardization.
[0005] According to one aspect of the present invention, an embodiment of the present invention provides a method for determining core cases, the method comprising:
[0006] Obtain the code branch coverage information corresponding to the test case;
[0007] The code branch features corresponding to the test case are determined based on the code branch coverage information and the pre-configured code branch coverage feature mapping rules.
[0008] Determine the classification category corresponding to the test case;
[0009] The test cases are selected into the core case set based on the preset clustering algorithm, the code branch features, and the classification category.
[0010] According to another aspect of the present invention, embodiments of the present invention also provide a core case determination apparatus, the apparatus comprising:
[0011] The information acquisition module is used to acquire the code branch coverage information corresponding to the test case;
[0012] The feature determination module is used to determine the code branch features corresponding to the test case based on the code branch coverage information and the pre-configured code branch coverage feature mapping rules.
[0013] The category determination module is used to determine the classification category corresponding to the test case;
[0014] The core case selection module is used to select the test cases into the core case set based on the preset clustering algorithm, the code branch features, and the classification category.
[0015] According to another aspect of the present invention, embodiments of the present invention also provide an electronic device, the electronic device comprising:
[0016] At least one processor; and
[0017] A memory communicatively connected to the at least one processor; wherein,
[0018] The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the core case determination method described in any embodiment of the present invention.
[0019] According to another aspect of the present invention, embodiments of the present invention also provide a computer-readable storage medium storing computer instructions for causing a processor to execute the core case determination method described in any embodiment of the present invention.
[0020] The technical solution of this invention, through code branch coverage information and code branch coverage feature mapping rules, determines the code branch features corresponding to the test case, enabling convenient and efficient calculations and laying a data structure foundation for subsequent efficient, intelligent, and accurate calculations. Based on this, by determining the classification category corresponding to the test case and selecting the test case into the core case set according to a preset clustering algorithm, code branch features, and classification category, the most representative and discriminative core cases can be obtained efficiently, quickly, and objectively, avoiding the arbitrariness and error in core case selection, effectively improving the accuracy and efficiency of core case selection, saving manpower and time costs, and simultaneously improving test quality and standardization.
[0021] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of the present invention, nor is it intended to limit the scope of the invention. Other features of the invention will become readily apparent from the following description. Attached Figure Description
[0022] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0023] Figure 1 A flowchart illustrating a core case determination method provided in an embodiment of the present invention;
[0024] Figure 2 A flowchart illustrating another core case determination method provided in an embodiment of the present invention;
[0025] Figure 3 A flowchart illustrating another core case determination method provided in an embodiment of the present invention;
[0026] Figure 4 A flowchart illustrating another core case determination method provided in an embodiment of the present invention;
[0027] Figure 5 This is a structural block diagram of a core case determination device provided in an embodiment of the present invention;
[0028] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation
[0029] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.
[0030] It should be noted that the terms "first," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises 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, methods, products, or apparatus.
[0031] In one embodiment, Figure 1 This is a flowchart of a core case determination method provided in an embodiment of the present invention. This embodiment is applicable to the case of determining the set corresponding to core cases. The method can be executed by a core case determination device, which can be implemented in hardware and / or software and can be configured in an electronic device.
[0032] like Figure 1 As shown, the specific steps include:
[0033] S110. Obtain the code branch coverage information corresponding to the test case.
[0034] In this context, the test cases can be understood as cases that will be used for transaction-level regression testing. Code branch coverage information can be understood as the coverage data of code branches in the test cases.
[0035] In this embodiment, there can be multiple test cases, each corresponding to one or more code branches. These code branches may represent different test scenarios or different test cases. Each code branch has corresponding branch coverage information, thus forming the code branch coverage information for each test case. It should be noted that the code branch coverage information may include, but is not limited to, the coverage of each code branch, the number of code branches, the coverage of packages involved in the code, the coverage of classes, and the coverage of methods.
[0036] In this embodiment, a code coverage detection tool can be used to determine the code branches and code branch coverage of each test case, and the code structure and code branch coverage can be combined to form code branch coverage information. In some embodiments, a distributed version control system can also be used to obtain the code branches corresponding to each test case and extract information corresponding to at least one code branch.
[0037] S120. Determine the code branch features corresponding to the test case based on the code branch coverage information and the pre-configured code branch coverage feature mapping rules.
[0038] Among them, the code branch coverage feature mapping rule refers to the feature mapping rule corresponding to the coverage information of each code branch in the test case. This code branch coverage feature mapping rule can be set manually based on experience or customized. This embodiment does not impose any restrictions here.
[0039] In this embodiment, code branch features can be understood as the code branch features that are obtained by quantifying the branch coverage of each test case using the code branch coverage feature mapping rule. They can be in the form of a one-dimensional feature vector, a matrix, or other forms that can define code branch features.
[0040] In this embodiment, the branch coverage information in the code coverage corresponding to each test case can be obtained, and the code branch coverage feature mapping rule can be used to map the code branch coverage information of each test case into a feature vector as a code branch feature. It should be noted that during the execution of each test case, there will be many coverage situations for different branches in the code, which may cover one or more code branches in the code file. It is necessary to first sort the packages, classes, methods and branches involved in all the code in the system hierarchically. On this basis, the binary conversion of 1 and 0 is performed according to the true or false values of the code branch conditions during the execution of the test case. The final generated corresponding binary number string containing only 0 and 1 is thus obtained as the code branch coverage feature mapping rule of the test case.
[0041] S130. Determine the category corresponding to the test case.
[0042] The classification category, also known as the cluster category, can be understood as the classification category determined by the transaction list corresponding to the test case. This classification category can include multiple categories, such as non-linkage constraint category, mandatory linkage constraint category, and non-non-linkage and mandatory linkage constraint categories, etc.
[0043] In this embodiment, based on the coverage of transactions by each test case and the transaction list corresponding to each test case (which is a subset of all transaction sets), the transaction codes corresponding to the test cases can be determined and a transaction code set consisting of all test transactions can be formed. The transaction code subset corresponding to each test case can be selected from the transaction code set for comparison, and the classification category corresponding to the test case can be determined based on the comparison results.
[0044] S140. Select test cases into the core case set based on the preset clustering algorithm, code branch features, and classification categories.
[0045] The preset clustering algorithms can include semi-supervised K-Means machine learning algorithm, DBSCAN density-based spatial clustering algorithm, and MeanShift mean shift algorithm. The core case set can be understood as the final set of selected core cases, which contains multiple selected core cases and can cover the core cases of all transactions.
[0046] In this embodiment, the initial sample selection algorithm is first used to determine the initial set of mean vectors and the number of vectors corresponding to each category. The initial screening results of each feature vector in the feature vector space corresponding to the category are determined. Based on the initial screening results, the feature vectors are divided into different clusters. Based on the different clusters, the preset clustering algorithm and Euclidean distance formula are used again to cluster each feature vector with the similarity of each initial mean vector in the initial mean vector set. The category with the minimum distance to the initial mean vector is selected and incorporated. The initial mean vector set is updated as the new mean vector set, and the clustering process of similarity is iterated and repeated until the mean vector corresponding to each category remains unchanged. The feature vector with the minimum distance is selected from each category, and the test case corresponding to the feature vector is used as the center case of the clustering result and placed into the core case result set. Then, all transactions covered by the center case are removed from the transaction code set, and the feature vectors corresponding to all transaction sets corresponding to the center case that can completely cover the transaction code are selected from the feature vector set. The center case selection operation is repeated until the transaction code set is empty, so as to select the core case set that can cover all transactions.
[0047] The technical solution of this invention, through code branch coverage information and code branch coverage feature mapping rules, determines the code branch features corresponding to the test case, enabling convenient and efficient calculation and laying a data structure foundation for subsequent efficient, intelligent, and accurate calculations. Based on this, by determining the classification category corresponding to the test case and selecting the test case into the core case set according to a preset clustering algorithm, code branch features, and classification category, the most representative and discriminative core cases can be obtained efficiently, quickly, and objectively, avoiding arbitrariness and errors in core case selection, effectively improving the accuracy and efficiency of core case selection, saving manpower and time costs, and simultaneously improving test quality and standardization.
[0048] In one embodiment, determining the code branch coverage feature mapping rule includes:
[0049] Identify the packages, classes, methods, and code branches in the code files corresponding to the test cases;
[0050] Packages, classes, methods, and code branches are sorted hierarchically according to a preset order;
[0051] Based on the hierarchical sorting results and the branch conditions corresponding to the code branches, the condition value sequence is determined, and the condition value sequence is mapped to a binary number string as the code branch coverage feature mapping rule.
[0052] The preset order can be understood as the pre-set hierarchical order of packages, classes, methods, and code branches. This order can be set through experience or customized; this embodiment does not impose any restrictions. The condition value sequence can be understood as the sequence corresponding to the true or false values of branch conditions during the execution of the example. For example, if a branch condition is true, the corresponding sequence is 1; if a branch condition is false, the corresponding sequence is 0.
[0053] In this embodiment, by determining the packages, classes, methods, and code branches in the code files corresponding to the test cases, the packages, classes, methods, and code branches can be sorted according to the first letter of their names. If the first letters are the same, the order of the second letters determines the final order, and so on, to hierarchically sort the packages, classes, methods, and code branches. Specifically, the packages can be sorted by their names. Then, based on the existing package sorting, the class names within each package are also sorted alphabetically. Next, based on the existing class sorting, the method names within each class are sorted alphabetically. Finally, based on the existing method sorting, the methods are sorted according to the order in which the branch conditions appear within each method, thus obtaining the hierarchical sorting order of packages, classes, methods, and code branches.
[0054] In this embodiment, the condition value sequence can be determined based on the hierarchical sorting result and the branch conditions corresponding to the code branches. This condition value sequence is then mapped to a binary number string. This can be understood as follows: due to the hierarchical sorting, all branch conditions are arranged sequentially. Each branch condition is represented by a 0 or 1 depending on its true or false value when executed by different test cases. Therefore, the code branch condition values corresponding to different test cases will be mapped to different feature vectors. Specifically, the binary conversion between 1 and 0 can be performed based on the true or false values of the branch conditions, ultimately generating a binary number string consisting only of 0s and 1s. It should be noted that the length of this binary number string is related to the number of code branches corresponding to the test case. Furthermore, since the feature vectors are ultimately created by sorting according to the hierarchy of packages, classes, methods, etc., the feature vectors also cover the coverage of packages, classes, and methods.
[0055] For example, a code branch in a program involves the logical operation `if(a&&(b||c)){}` with three conditions `a`, `b`, and `c`. `1` indicates the condition is true, and `0` indicates it's false. Using three-bit binary numbers, based on the order of the conditions, `001` represents `a` and `b` being false, and `c` being true. `111` represents all three conditions being true. There are eight three-bit binary numbers, representing eight branches. After sorting all branches hierarchically, each test case is further analyzed based on its coverage of the branches. Coverage is indicated by `1`, and uncovered cases by `0`. Finally, each test case is converted into a fixed-length vector of 0s and 1s.
[0056] In one embodiment, Figure 2 This is a flowchart of another core case determination method provided in an embodiment of the present invention. Based on the above embodiments, this embodiment further refines the steps of obtaining code branch coverage information corresponding to the test case, determining the code branch features corresponding to the test case according to the code branch coverage information and the pre-configured code branch coverage feature mapping rules, and determining the classification category corresponding to the test case.
[0057] like Figure 2 As shown, the core case determination method in this embodiment may specifically include the following steps:
[0058] S210. Determine the code structure and code branch coverage of the test cases based on the code coverage detection tool.
[0059] Code coverage testing tools are used to quantify code test coverage, allowing testers to visually identify uncovered code branches. Code structure can be understood as the structure of the code file; for example, the code structure includes conditional statements such as if, eles, and or. Code branch coverage can be understood as whether a code branch has been covered.
[0060] In this embodiment, test cases that have been executed previously are selected during regression testing. Therefore, when executing each test case before the regression testing phase, code coverage detection tools can be used to determine the code structure and code branch coverage corresponding to each test case.
[0061] S220. Combine the code structure and code branch coverage information to form code branch coverage information.
[0062] In this embodiment, after quantifying the coverage of code tests using a code coverage detection tool, the code structure and code branch coverage of the test case can be combined to form code branch coverage information.
[0063] S230. Extract the code branch coverage information corresponding to the test case.
[0064] In this embodiment, each test case corresponds to one or more code branches with corresponding code branch coverage information. Extracting the code branch coverage information corresponding to each test case can be understood as obtaining the code branch coverage information of each test case.
[0065] S240. Based on the code branch coverage feature mapping rule, map the code branch coverage information corresponding to the test case into a binary number string, and use the binary number string as the feature vector corresponding to the test case. The length of the feature vector is related to the number of code branches corresponding to the test case.
[0066] Here, a binary digit string can be understood as a string of 0s and 1s corresponding to the code branch conditions. A feature vector refers to a fixed-length binary digit vector containing 0s and 1s.
[0067] It should be noted that the length of the feature vector is related to the number of code branches corresponding to the test case. It can be understood that the length of the feature vector is the same as the number of code branches corresponding to the test case. For example, if the number of code branches corresponding to the test case is 8, then the length of the feature vector is 8 bits.
[0068] In this embodiment, for the code branch coverage information in the code coverage corresponding to each test case, the code branch coverage information corresponding to each test case can be mapped to a binary number string according to the code branch coverage feature mapping rule, and the binary number string is used as the feature vector corresponding to the test case. Of course, since each test case corresponds to multiple code branches, and each code branch corresponds to a conditional true or false judgment, we can define that when the code branch condition is true, we use 1 to represent it, and when the code branch condition is false, we use 1 to represent it. The multiple code branches corresponding to each test case are mapped to binary number strings containing multiple 0s and 1s, and the feature vectors corresponding to all test cases are combined to form a feature vector space set. For example, there are 2 test cases. Case 1 corresponds to 6 code branches. Among the 6 code branches, 4 code branches are true and 2 code branches are false. Then the binary number string formed by Case 1 is 111100. Case 2 corresponds to 4 code branches. 2 code branches are true and 2 code branches are false. The binary number string formed by Case 2 is 1100.
[0069] S250. Use the feature vectors as code branch features and form a feature vector space.
[0070] In this embodiment, the feature vector corresponding to each test case is used as a code branch feature to form a feature vector space. For example, there are 4 test cases, and the binary number string corresponding to each test case is stored as a feature vector in the feature vector space.
[0071] S260. Determine the transaction codes corresponding to the test cases and form a set of transaction codes.
[0072] The transaction code can be understood as an 8-bit numeric code corresponding to a transaction. The transaction code set contains the transaction codes corresponding to all test cases.
[0073] In this embodiment, there is a certain correspondence between transactions and test cases. The relationship between transactions and test cases is one-to-many or many-to-many. It can be understood that one test case may cover multiple transactions, and one transaction is often covered by multiple test cases. For example, developers provide transaction codes corresponding to each transaction. To test several transactions that have changed, test cases can be written based on the transactions. When this test case is executed, it may cover not only the transaction in question but also other transactions.
[0074] In this embodiment, each test case can correspond to at least one transaction code. The transaction codes corresponding to each test case are determined to form a transaction code set. It should be noted that the transaction codes can be pre-configured.
[0075] S270. Select the subset of transaction codes corresponding to the test cases from the transaction code set.
[0076] The transaction code subset can be understood as a subset of the transaction codes corresponding to each test case in the transaction code set.
[0077] In this embodiment, the transaction coverage of each test case is known, and each test case has a corresponding transaction code. The transaction code corresponding to a test case is a subset of the transaction code set. In this embodiment, after determining the transaction code set, the subset of transaction codes corresponding to each test case is selected from the transaction code set.
[0078] S280. Compare the subset of transaction codes corresponding to each test case to obtain the comparison result.
[0079] In this embodiment, the transaction code subsets corresponding to each test case are compared separately to determine the classification category of the test case based on the comparison results. It should be noted that when the intersection of the transaction code subsets is empty, the classification category is determined to be a non-joint constraint; when the intersection is completely identical, the classification category is determined to be a mandatory constraint; and when the intersection exists but is not completely identical, the classification category is determined to be neither a non-joint nor a mandatory constraint. For example, when the intersection of transaction code subsets A and B formed by the transaction codes of two cases is empty, a non-joint constraint is formed; when the two sets are completely identical, a mandatory constraint is formed.
[0080] S290. When the comparison result shows that the intersection of the transaction code subsets is an empty set, the classification category is determined as the first category.
[0081] The first category represents the non-association constraint category, which can be understood as determining, based on this supervision information, that samples must not belong to the same cluster during the semi-supervised clustering analysis process.
[0082] In this embodiment, the transaction code subsets corresponding to each test case are compared. When the intersection of the transaction code subsets is an empty set, the classification category corresponding to the test case is determined to be the "Do Not Connect" constraint category.
[0083] S2100. When the comparison results show that the intersection of the corresponding transaction code subsets is completely identical, the classification category is determined to be the second category.
[0084] The second category represents the mandatory constraint category, which can be understood as determining that samples must belong to the same cluster based on this supervision information during the semi-supervised clustering analysis process.
[0085] In this embodiment, the transaction code subsets corresponding to each test case are compared. When the intersection of the transaction code subsets is completely identical, the classification category corresponding to the test case is determined to be the mandatory constraint category.
[0086] S2110. When the comparison result shows that the intersection of the transaction code subsets is intersecting but not completely identical, the classification category is determined to be the third category.
[0087] The third category represents constraints that are neither mandatory nor unmandatory, and can be divided into clusters using distance algorithms and multiple distance calculations based on the Euclidean distance formula. It should be noted that the third category includes multiple subcategories.
[0088] In this embodiment, the transaction code subsets corresponding to each test case are compared. When the comparison result shows that the intersection of the transaction code subsets is present but not completely identical, the classification category is determined to be neither mandatory nor non-mandatory.
[0089] The technical solution described in this embodiment maps the code branch coverage information corresponding to the test case into a binary number string according to the code branch coverage feature mapping rule, and uses the binary number string as the feature vector corresponding to the test case. The feature vector is then used as the code branch feature to form a feature vector space, which further realizes convenient and efficient calculation and lays the data structure foundation for subsequent efficient, intelligent and accurate calculation.
[0090] In one embodiment, Figure 3 This is a flowchart of another core case determination method provided by an embodiment of the present invention. Based on the above embodiments, this embodiment further refines the selection of test cases into the core case set according to a preset clustering algorithm, code branch features and classification categories.
[0091] S310. Determine the initial mean vector set and the number of vectors corresponding to each classification category based on the initial sample selection algorithm.
[0092] The initial mean vector set contains multiple initial mean vectors, which can be determined using an initial sample selection algorithm. The number of vectors can be understood as the number of initial samples.
[0093] In this embodiment, the feature vector with the most covered transactions can be selected from the feature vector set consisting of all test cases. This feature vector is then placed into the initial mean vector set. Then, all transactions covered by the feature vector with the most covered transactions are removed from the transaction code set. At the same time, the feature vectors of test cases that can be completely covered by the set of all transactions corresponding to the feature vector with the most covered transactions are selected. This process is repeated until the transaction code set is empty. In this way, the initial mean vector set is generated, and the number of vectors can also be determined.
[0094] In one embodiment, determining the initial mean vector set and the number of vectors corresponding to each classification category based on an initial sample selection algorithm includes:
[0095] Determine the number of covered transactions corresponding to each feature vector in the feature vector set, and sort the number of covered transactions;
[0096] Select the current feature vector that covers the first number of transactions, and put the current feature vector into the initial mean vector set;
[0097] Remove all transactions covered by the current feature vector from the transaction code set, and select the feature vector corresponding to the case where the transaction set corresponding to the current feature vector completely covers the transaction code from the feature vector set. Repeat the selection operation of the current feature vector until the transaction code set is empty, so as to obtain the initial mean vector set and the corresponding number of vectors.
[0098] Here, the first transaction number refers to the number of transactions that ranks first in the number of covered transactions in the feature vector set for each time.
[0099] In this embodiment, the number of transactions covered by each feature vector in the feature vector set consisting of all test cases can be sorted, either from smallest to largest or largest to smallest. Based on the sorting result, the feature vector covering the most transactions is selected and placed into the initial mean vector set. Then, all transactions covered by the feature vector covering the most transactions are removed from the transaction code set. At the same time, feature vectors of test cases are selected from the test cases whose transaction codes are completely covered by the set of all transactions corresponding to the feature vector covering the most transactions. If the transaction code set is still not empty after the above operations, this process is repeated for the transactions in the transaction code set until it is 0. In this way, the initial mean vector set is generated, and the number of vectors is the value of K.
[0100] S320. Determine the initial screening results of the corresponding classification categories for each feature vector in the feature vector space.
[0101] The initial screening results must include at least the classification category to which the feature vector belongs; the classification category must include at least one of the following: category one, category two, or category three.
[0102] In this embodiment, after obtaining the initial set of mean vectors and the number of vectors, each feature vector in the feature vector space is first screened against each other for its corresponding classification category. This can be understood as the pairwise comparison of mandatory and non-mandatory constraints between each feature vector in the feature vector space to determine the initial screening result. Specifically, the transaction code subset corresponding to each feature vector in the feature vector space is first determined. The transaction code subsets are then compared pairwise between each feature vector. If the intersection of the transaction code subsets is empty, it is determined to be a non-mandatory constraint (first category); if the intersection of the transaction code subsets is completely identical, it is determined to be a mandatory constraint (second category); and if the intersection of the transaction code subsets is neither identical nor identical, it is determined to be a non-mandatory constraint and a non-mandatory constraint (third category).
[0103] S330. If the initial screening result is the second category, then the feature vector is directly placed into the second category.
[0104] In this embodiment, if the initial screening result is a mandatory constraint, the feature vector is directly placed into the cluster of mandatory constraints.
[0105] S340. If the initial screening result is the first category or the third category, then cluster the feature vectors in the initial screening result with each initial mean vector in the initial mean vector set according to the preset clustering algorithm and Euclidean distance formula. Select the categories that reach the first distance from the initial mean vector and merge them into the cluster. Update the initial mean vector set as the new mean vector set and iterate and repeat this step until the mean vector corresponding to each category remains unchanged. Select the feature vectors that reach the second distance from each category and put the test cases corresponding to the feature vectors into the core case result set as the center cases of the clustering results.
[0106] The first distance refers to the distance that minimizes the distance to each initial mean vector. The second distance refers to the distance that minimizes the distance to each cluster after the cluster classification has stabilized.
[0107] In this embodiment, if the initial screening result is a non-linked constraint or a non-mandatory and non-non-linked constraint, then based on the preset clustering algorithm and Euclidean distance formula, the similarity between each feature vector in the initial screening result and each initial mean vector in the initial mean vector set is determined for clustering. The category with the smallest distance from the initial mean vector is selected and incorporated. Then, the initial mean vector set is updated as the new mean vector set, and this step is iteratively repeated until the mean vector corresponding to each category remains unchanged. This can be understood as each category reaching a stable state. Then, the feature vector with the smallest distance is selected from each category, and the test case corresponding to the feature vector is used as the center case of the clustering result and placed into the core case result set. This core case set can cover all transactions.
[0108] In this embodiment, based on the calculation method of the initial sample and the number of samples, the clustering process optimizes and filters the clustering information of the transaction based on the cases. Finally, in order to ensure that all the transactions to be tested are covered, further modifications are made. Through multiple rounds of clustering, it is ensured that the final core case set can completely cover the transaction set to be tested.
[0109] S350. Remove all transactions covered by the central case from the transaction code set, and select the feature vectors corresponding to all transactions corresponding to the central case from the feature vector set that can completely cover the transaction codes. Repeat S340 until the transaction code set is empty, in order to select the core case set that can cover all transactions.
[0110] In this embodiment, all transactions covered by the central case are removed from the transaction code set, and the feature vectors corresponding to all transactions corresponding to the central case are selected from the feature vector set. The central case selection operation is repeated until the transaction code set is empty, so as to select the core case set that can cover all transactions.
[0111] The above-mentioned solution of the present invention determines the initial mean vector set and the number of vectors corresponding to each classification category through an initial sample selection algorithm, and performs clustering multiple times through a semi-supervised K-Means clustering algorithm, thereby intelligently and accurately selecting the test cases with the highest discrimination and the strongest representativeness among the cases to be screened, effectively improving the accuracy and efficiency of transaction-level regression test case selection, and thus improving test quality and standardization.
[0112] In one embodiment, to facilitate a better understanding of the core case determination method, Figure 4This is a flowchart of another core case determination method provided by an embodiment of the present invention. This embodiment can be used as a preferred embodiment to further illustrate the core case determination method. The improved semi-supervised K-Means clustering algorithm in this embodiment is represented by the preset clustering algorithm in the above embodiment, where the k value represents the number of vectors in the above embodiment, i.e., the number of initial samples, and the cluster category represents the classification category in the above embodiment.
[0113] In this embodiment of the invention, based on the coverage of code structure and code branches by each test case, a corresponding feature vector is mapped using code branch coverage feature mapping rules. Semi-supervised clustering analysis is then performed based on the test case's coverage of transactions. Based on the results of multiple clustering analyses, the central case of each cluster is selected as the final core case covering the transactions. This invention, in transaction-level regression testing, considers both the test case's coverage of code structure and branch branches, efficiently and objectively calculating the most representative and discriminative core cases. It effectively improves the accuracy and efficiency of transaction-level regression test case selection, thereby enhancing test quality and standardization.
[0114] like Figure 4 As shown, the specific steps for determining the core case are as follows:
[0115] S410. Use a code coverage detection tool to obtain the code branch coverage information corresponding to the test case.
[0116] S420. Based on the code branch coverage information corresponding to the code branch of each test case, use the code branch coverage feature mapping rule to map each test case to a corresponding feature vector. The feature vectors of all test cases form the feature vector space S.
[0117] In this embodiment, the code branch coverage feature mapping rule is used to map each test case to a feature vector of fixed length consisting of 0s and 1s, and the feature vectors of all test cases form the feature vector space S.
[0118] S430. Determine the transaction code corresponding to the test case, and determine the cluster category corresponding to the test case based on the transaction code.
[0119] In this embodiment, based on the transaction coverage of each test case, each test case has a corresponding transaction code. At least one transaction code corresponding to a test case is a subset of the set of all transaction codes T. The intersection of transaction code subsets A and B formed by the transaction codes corresponding to two test cases is empty. This forms a non-association constraint. When two sets are identical... This forms a mandatory constraint.
[0120] S440. Determine the set corresponding to the core cases based on the semi-supervised K-Means clustering algorithm, the feature vectors in the feature vector space S, and the cluster categories.
[0121] In this embodiment, after obtaining the initial mean vector set and k value based on the initial sample selection algorithm, each feature vector in the feature vector space S is first subjected to mandatory and non-mandatory connection constraints and filtered. Then, based on the preset clustering algorithm and Euclidean distance formula, the similarity between each filtered feature vector and each initial mean vector in the initial mean vector set is determined, and clustering is performed. The category with the smallest distance from the initial mean vector is selected and incorporated, and the initial mean vector set is updated as the new mean vector set. This step is repeated iteratively until the mean vector corresponding to each category remains unchanged, that is, the clusters are stable. After the clusters are stable, the corresponding center cases in each cluster are included as part of the core case result set and placed into the final core case result set. Finally, the feature vectors corresponding to the center cases of the clusters in this round of clustering are removed, and the feature vectors corresponding to cases whose transaction lists can be completely covered by the set of all transactions corresponding to the core cases are also removed. In addition, all transactions corresponding to the core cases need to be removed. If there are still elements in the transaction code set T after removal, the above process is repeated until the transaction code set T is empty, and finally, the core case set that can cover all transactions in the test cases is obtained.
[0122] In one embodiment, Figure 5 This is a structural block diagram of a core case determination device according to an embodiment of the present invention. This device is suitable for determining the set corresponding to core cases and can be implemented in hardware or software. It can be configured in an electronic device to implement a core case determination method according to an embodiment of the present invention. Figure 5 As shown, the device includes: an information acquisition module 510, a feature determination module 520, a category determination module 530, and a core case selection module 540.
[0123] Among them, the information acquisition module 510 is used to acquire the code branch coverage information corresponding to the test case;
[0124] The feature determination module 520 is used to determine the code branch features corresponding to the test case based on the code branch coverage information and the pre-configured code branch coverage feature mapping rules.
[0125] Category determination module 530 is used to determine the classification category corresponding to the test case;
[0126] The core case selection module 540 is used to select the test cases into the core case set based on the preset clustering algorithm, the code branch features and the classification category.
[0127] In this embodiment of the invention, the feature determination module determines the code branch features corresponding to the test case by using code branch coverage information and code branch coverage feature mapping rules. This enables convenient and efficient calculations, laying a data structure foundation for subsequent efficient, intelligent, and accurate calculations. Based on this, the core case selection module determines the classification category corresponding to the test case and selects the test case into the core case set according to a preset clustering algorithm, code branch features, and classification category. This efficiently and objectively obtains the most representative and discriminative core cases, avoiding arbitrariness and errors in core case selection, effectively improving the accuracy and efficiency of core case selection, saving manpower and time costs, and simultaneously improving test quality and standardization.
[0128] In one embodiment, the information acquisition module 510 includes:
[0129] The case determination unit is used to determine the code structure and code branch coverage of the test cases based on the code coverage detection tool.
[0130] An information component unit is used to combine the code structure and the code branch coverage information to form the code branch coverage information.
[0131] In one embodiment, the feature determination module 520 includes:
[0132] The information extraction unit is used to extract the code branch coverage information corresponding to the test case;
[0133] The mapping unit is used to map the code branch coverage information corresponding to the test case into a binary number string according to the code branch coverage feature mapping rule; and to use the binary number string as the feature vector corresponding to the test case, wherein the length of the feature vector is related to the number of code branches corresponding to the test case;
[0134] A spatial composition unit is used to use the feature vectors as the code branch features and form a feature vector space.
[0135] In one embodiment, the category determination module 530 includes:
[0136] A set determination unit is used to determine the transaction code corresponding to the test case and form a transaction code set;
[0137] A subset determination unit is used to select a subset of transaction codes corresponding to each of the test cases from the set of transaction codes;
[0138] The result determination unit is used to compare the subset of transaction codes corresponding to each test case to obtain a comparison result;
[0139] The first category determination unit is used to determine the classification category as the first category when the comparison result is that the intersection of the transaction code subset is an empty set;
[0140] The second category determination unit is used to determine the classification category as the second category when the comparison result shows that the intersection of the corresponding subsets of transaction codes is completely identical;
[0141] The third category determination unit is used to determine the classification category as the third category when the comparison result shows that the intersection of the corresponding subsets of transaction codes has an intersection but is not completely identical.
[0142] In one embodiment, the core case selection module 540 includes:
[0143] An initial vector determination unit is used to determine the set of initial mean vectors and the number of vectors corresponding to each of the classification categories based on an initial sample selection algorithm.
[0144] The initial screening unit is used to determine the initial screening result corresponding to the classification category between each feature vector in the feature vector space; wherein, the initial screening result includes at least the classification category to which the feature vector belongs; the classification category includes at least one of the following: the first category, the second category, and the third category;
[0145] The first determining unit is used to directly put the feature vector into the second category if the initial screening result is the second category;
[0146] The second determining unit is configured to, if the initial screening result is the first category or the third category, determine the similarity between each feature vector in the initial screening result and each initial mean vector in the initial mean vector set according to the preset clustering algorithm and Euclidean distance formula, perform clustering, select the classification category that reaches a first distance from the initial mean vector and incorporate it, update the initial mean vector set as a new mean vector set and iteratively repeat this step until the mean vector corresponding to each classification category remains unchanged, select the feature vector that reaches a second distance from each classification category, and put the test case corresponding to the feature vector as the center case of the clustering result into the core case result set;
[0147] The core case set determination unit is used to remove all transactions covered by the central case from the transaction code set, and select the feature vectors corresponding to cases whose transaction sets corresponding to the central case can completely cover the transaction codes from the feature vector set. The selection operation of the central case is repeated until the transaction code set is empty, so as to select a core case set that can cover all transactions.
[0148] In one embodiment, the initial vector determination unit includes:
[0149] The sorting subunit is used to determine the number of covered transactions corresponding to each feature vector in the feature vector set, and to sort the number of covered transactions.
[0150] Select a sub-unit to select the current feature vector when the number of covered transactions reaches the first number of transactions, and put the current feature vector into the initial mean vector set;
[0151] An initial set determination subunit is used to remove all transactions covered by the current feature vector from the transaction code set, and select the feature vector corresponding to the case where all transaction sets corresponding to the current feature vector completely cover the transaction code from the feature vector set. The selection operation of the current feature vector is repeated until the transaction code set is empty, so as to obtain the initial mean vector set and the corresponding number of vectors.
[0152] In one embodiment, determining the code branch coverage feature mapping rule includes:
[0153] The test cases are identified as corresponding to the packages, classes, methods, and code branches in the code files, respectively.
[0154] The packages, classes, methods, and code branches are sorted hierarchically according to a preset order;
[0155] Based on the result of the hierarchical sorting and the branch conditions corresponding to the code branch, a condition value sequence is determined, and the condition value sequence is mapped to a binary number string as the code branch coverage feature mapping rule.
[0156] The core case determination device provided in the embodiments of the present invention can execute the core case determination method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.
[0157] In one embodiment, Figure 6 This is a schematic diagram of an electronic device provided for an embodiment of the present invention. The electronic device 10 is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (such as helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.
[0158] like Figure 6 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 can also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.
[0159] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0160] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as the core case determination method.
[0161] In some embodiments, the core case determination method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or mounted on electronic device 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the core case determination method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform the core case determination method by any other suitable means (e.g., by means of firmware).
[0162] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0163] Computer programs used to implement the methods of the present invention can be written in any combination of one or more programming languages. These computer programs can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable core case determination device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The computer programs can be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.
[0164] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.
[0165] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).
[0166] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.
[0167] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.
[0168] In implementing the computer program product, computer program code for performing the operations of this invention can be written in one or more programming languages or a combination thereof. Programming languages include object-oriented programming languages such as Java, Smalltalk, and C++, as well as conventional procedural programming languages such as C or similar languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0169] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.
[0170] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.
Claims
1. A method for determining core cases, characterized in that, include: Obtain the code branch coverage information corresponding to the test case; The code branch features corresponding to the test case are determined based on the code branch coverage information and the pre-configured code branch coverage feature mapping rules. Determine the classification category corresponding to the test case; The test cases are selected into the core case set based on the preset clustering algorithm, the code branch features, and the classification category; Determining the classification category corresponding to the test case includes: Determine the transaction codes corresponding to the test cases and form a transaction code set; Select a subset of transaction codes corresponding to each of the test cases from the set of transaction codes; The subset of transaction codes corresponding to each test case is compared to obtain the comparison results; When the comparison result shows that the intersection of the subsets of transaction codes is an empty set, the classification category is determined to be the first category; When the comparison result shows that the intersection of the transaction code subsets is completely identical, the classification category is determined to be the second category; When the comparison result shows that the intersection of the transaction code subsets is present but not completely identical, the classification category is determined to be the third category.
2. The method according to claim 1, characterized in that, The process of obtaining the code branch coverage information corresponding to the test case includes: The code structure and branch coverage of the test cases are determined using code coverage detection tools. The code structure and the code branch coverage information are combined to form the code branch coverage information.
3. The method according to claim 1, characterized in that, The step of determining the code branch features corresponding to the test case based on the code branch coverage information and pre-configured code branch coverage feature mapping rules includes: Extract the code branch coverage information corresponding to the test case; Based on the code branch coverage feature mapping rule, the code branch coverage information corresponding to the test case is mapped into a binary number string, and the binary number string is used as the feature vector corresponding to the test case. The length of the feature vector is related to the number of code branches corresponding to the test case. The feature vectors are used as the code branch features and form a feature vector space.
4. The method according to claim 3, characterized in that, The step of selecting the test cases into the core case set based on the preset clustering algorithm, the code branch features, and the classification category includes: The initial set of mean vectors and the number of vectors corresponding to each of the classification categories are determined based on the initial sample selection algorithm. Determine the initial screening result corresponding to the classification category for each feature vector in the feature vector space; wherein the initial screening result includes at least the classification category to which the feature vector belongs; the classification category includes at least one of the following: the first category, the second category, and the third category; If the initial screening result is the second category, then the feature vector is directly placed into the second category; If the initial screening result is the first category or the third category, then clustering is performed based on the similarity between each feature vector in the initial screening result and each initial mean vector in the initial mean vector set, according to the preset clustering algorithm and Euclidean distance formula. The category that reaches the first distance from the initial mean vector is selected and incorporated. The initial mean vector set is updated as a new mean vector set and this step is repeated iteratively until the mean vector corresponding to each category remains unchanged. The feature vector that reaches the second distance from each category is selected, and the test case corresponding to the feature vector is placed into the core case result set as the center case of the clustering result. Remove all transactions covered by the central case from the transaction code set, and select the feature vectors corresponding to all transactions that can completely cover the transaction codes from the feature vector set. Repeat the selection operation of the central case until the transaction code set is empty, so as to select the core case set that can cover all transactions.
5. The method according to claim 4, characterized in that, The step of determining the initial mean vector set and the number of vectors corresponding to each classification category based on the initial sample selection algorithm includes: Determine the number of covered transactions corresponding to each feature vector in the feature vector set, and sort the number of covered transactions; Select the current feature vector whose number of covered transactions reaches the first number of transactions, and put the current feature vector into the initial mean vector set; Remove all transactions covered by the current feature vector from the transaction code set, and select the feature vector corresponding to the case where all transaction sets corresponding to the current feature vector completely cover the transaction code from the feature vector set. Repeat the selection operation of the current feature vector until the transaction code set is empty, so as to obtain the initial mean vector set and the corresponding number of vectors.
6. The method according to claim 1, characterized in that, The determination of the code branch coverage feature mapping rules includes: The test cases are identified as corresponding to the packages, classes, methods, and code branches in the code files, respectively. The packages, classes, methods, and code branches are sorted hierarchically according to a preset order; Based on the result of the hierarchical sorting and the branch conditions corresponding to the code branch, a condition value sequence is determined, and the condition value sequence is mapped to a binary number string as the code branch coverage feature mapping rule.
7. A core case determination device, characterized in that, include: The information acquisition module is used to acquire the code branch coverage information corresponding to the test case; The feature determination module is used to determine the code branch features corresponding to the test case based on the code branch coverage information and the pre-configured code branch coverage feature mapping rules. The category determination module is used to determine the classification category corresponding to the test case; The core case selection module is used to select the test cases into the core case set based on the preset clustering algorithm, the code branch features and the classification category; The category determination module includes: A set determination unit is used to determine the transaction code corresponding to the test case and form a transaction code set; A subset determination unit is used to select a subset of transaction codes corresponding to each of the test cases from the set of transaction codes; The result determination unit is used to compare the subset of transaction codes corresponding to each test case to obtain a comparison result; The first category determination unit is used to determine the classification category as the first category when the comparison result is that the intersection of the transaction code subset is an empty set; The second category determination unit is used to determine the classification category as the second category when the comparison result shows that the intersection of the corresponding subsets of transaction codes is completely identical; The third category determination unit is used to determine the classification category as the third category when the comparison result shows that the intersection of the corresponding subsets of transaction codes has an intersection but is not completely identical.
8. An electronic device, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the core case determination method according to any one of claims 1-6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that cause a processor to execute the core case determination method according to any one of claims 1-6.
Citation Information
Patent Citations
Test sample reduction method based on runtime path features and test scene clustering
CN111061635A