Automated software deployment and testing based on code coverage correlation
US-2019294536-A1 · Sep 26, 2019 · US
US11487645B2 · US · B2
| Field | Value |
|---|---|
| Publication number | US-11487645-B2 |
| Application number | US-202017121665-A |
| Country | US |
| Kind code | B2 |
| Filing date | Dec 14, 2020 |
| Priority date | Dec 14, 2020 |
| Publication date | Nov 1, 2022 |
| Grant date | Nov 1, 2022 |
A practical reading order for non-experts. Skip the full description unless you need deep technical detail.
What the patent document calls the invention.
A short plain-language summary of the technical disclosure.
Who owns or filed the patent and who is credited as inventor.
Filing, priority, publication, and grant dates set the timeline.
The legal scope of protection — read this for what is actually claimed.
Technology tags used to group this patent with similar filings.
Prior art links and similar publications in this corpus.
Official abstract text for this publication.
A code base is parsed to identify methods having changes in a code base since a last code commit. Thereafter, a call graph is traversed to identify test cases implicated by the identified methods having changes in the code base. The call graph can be a directed call graph comprising a plurality of connected nodes in which a first subset of the connected nodes are method nodes representing each method in the code base in which unidirectional edges connecting method nodes correspond to invocations by a calling method to a callee method, and in which a second subset of the connected nodes are test case nodes representing each of a plurality of available test cases to test the code base. The test case nodes are each coupled to one or more method nodes by unidirectional edges that correspond to the test case coverage of the method.
Opening claim text (preview).
What is claimed is: 1. A computer-implemented method comprising: parsing a code base to identify methods having changes in a code base since a last code commit; traversing a single call graph of connected nodes representing control flow relationships amongst each of the methods in the code base to identify a minimum number of test cases, wherein the minimum number of test cases are only those test cases that are implicated by the identified methods having changes in the code base; causing data characterizing the identified minimum number of test cases to be displayed in a graphical user interface; and executing the identified minimum number of test cases; wherein: the single call graph is a directed call graph comprising a plurality of connected nodes; a first subset of the connected nodes are method nodes representing each method in the code base in which unidirectional edges connecting method nodes correspond to invocations by a calling method to a callee method; a second subset of the connected nodes are test case nodes representing each of a plurality of available test cases to test the code base, the test case nodes are each coupled to one or more method nodes, of the first subset, by unidirectional edges that correspond to coverage of the method by the test case corresponding to the connected test case node; the single call graph is traversed from each method node corresponding to the identified methods changed in the code base to identify test cases covering such methods. 2. The method of claim 1 , further comprising: providing data characterizing the identified minimum number of test cases, wherein the providing data characterizing the identified minimum number of test cases comprises: loading the data characterizing the identified minimum number of test cases into memory, storing data characterizing the identified minimum number of test cases in physical persistence, or transmitting the data characterizing the identified minimum number of test cases to a remote computing device. 3. The method of claim 1 , wherein the single call graph is stored in a graph database, and the method further comprises: polling the graph database to obtain the single call graph prior to the traversing. 4. The method of claim 1 further comprising: accessing a code repository storing the code base prior to the parsing. 5. The method of claim 1 , wherein the parsing comprises: generating a first abstract syntax tree representation of the code base at the time of the last code commit; generating a second abstract syntax tree representation of the code base including the changes since the last code commit; and comparing the first abstract syntax tree representation of the code to the second abstract syntax tree representation of the code. 6. The method of claim 1 , wherein the parsing comprising: comparing source code of the code base at the time of the commit to the source code of the code base after the changes. 7. The method of claim 1 , wherein the parsing comprises: analyzing a subsequent commit sent to the code repository characterizing changes to the code base since the last commit. 8. The method of claim 7 , wherein the subsequent commit comprises which methods were changed since the last commit. 9. The method of claim 1 , wherein the identified minimum number of test cases are displayed in the graphical user interface as recommended test cases to be executed. 10. The method of claim 1 , wherein identifying the minimum number of test cases comprises identifying that a first test case, of the plurality of available test cases, and a second test case, of the plurality of available test cases, are implicated by the identified methods having changes in the code base, and wherein executing the identified minimum number of test cases comprises executing the identified first test case and the identified second test case. 11. A system comprising: at least one data processor; and memory storing instructions which, when executed by the at least one data processor, result in operations comprising: parsing a code base to identify methods having changes in a code base since a last code commit; traversing a single call graph of connected nodes representing control flow relationships amongst each of the methods in the code base to identify a minimum number of test cases, wherein the minimum number of test cases are only those test cases that are implicated by the identified methods having changes in the code base; causing data characterizing the identified minimum number of test cases to be displayed in a graphical user interface; and executing the identified minimum number of test cases; wherein: the single call graph is a directed call graph comprising a plurality of connected nodes; a first subset of the connected nodes are method nodes representing each method in the code base in which unidirectional edges connecting method nodes correspond to invocations by a calling method to a callee method; a second subset of the connected nodes are test case nodes representing each of a plurality of available test cases to test the code base, the test case nodes are each coupled to one or more method nodes, of the first subset, by unidirectional edges that correspond to coverage of the method by the test case corresponding to the connected test case node; the single call graph is traversed from each method node corresponding to the identified methods changed in the code base to identify test cases covering such methods. 12. The system of claim 11 , the operations further comprising: providing data characterizing the identified minimum number of test cases, wherein the providing data characterizing the identified minimum number of test cases comprises: loading the data characterizing the identified minimum number of test cases into memory, storing data characterizing the identified minimum number of test cases in physical persistence, or transmitting the data characterizing the identified minimum number of test cases to a remote computing device. 13. The system of claim 11 , wherein the single call graph is stored in a graph database, and the operations further comprise: polling the graph database to obtain the single call graph prior to the traversing. 14. The system of claim 11 , wherein the parsing comprises: generating a first abstract syntax tree representation of the code base at the time of the last code commit; generating a second abstract syntax tree representation of the code base including the changes since the last code commit; and comparing the first abstract syntax tree representation of the code to the second abstract syntax tree representation of the code. 15. The system of claim 11 , wherein the parsing comprising: comparing source code of the code base at the time of the commit to the source code of the code base after the changes. 16. The system of claim 11 , wherein the parsing comprises: analyzing a subsequent commit sent to the code repository characterizing changes to the code base since the last commit. 17. The system of claim 16 , wherein the subsequent commit comprises which methods were changed since the last commit. 18. The system of claim 11 , wherein the identified minimum number of test cases are displayed in the graphical user interface as recommended test cases to be executed. 19. A non-transitory computer program product storing instructions which, when executed by the at least one computing device, result in operations comprising: parsing a code base to identify methods having c
Structural analysis for program understanding · CPC title
for test version control, e.g. updating test cases to a new software version · CPC title
for test execution, e.g. scheduling of test suites · CPC title
Version control (security arrangements therefor G06F21/57); Configuration management · CPC title
Internal representations for queries · CPC title
Related publications grouped by family.
Answers are generated from the same data shown on this page.