IP Library Granted Patent US 8,108,826
Granted Patent B2
US 8,108,826 · App. 10/953,849 · Granted Jan 31, 2012

Code-coverage guided prioritized test generation

View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 8,108,826
App. No.
10/953,849
Granted
Jan 31, 2012
Kind
B2
Abstract

A method for generating test cases for a program is disclosed. The method combines features of path-oriented and goal-oriented software testing. The illustrative embodiment constructs a control-flow graph with nodes that correspond to invocations of subroutines, and constructs control-flow graphs for the source code of such nodes as well. A metric that is based on the topology of the control-flow graph is evaluated recursively for nodes of the graph and for control-flow graphs that correspond to invoked subroutines. In the illustrative embodiment, the metric employed is the length of a shortest path from the starting node to a particular node. A node n with the highest metric value is then selected as a goal, and a path from the starting node to the ending node that passes through node n is generated via backtracking.

Claims (42)

1. A method comprising:

(a) generating a first path from the starting node of a control-flow graph to a goal node of said control-flow graph based on the values of a metric for one or more other nodes of said control-flow graph;

(b) generating a second path from said goal node to an ending node of said control-flow graph; and

(c) generating, based on the concatenation of said first path and said second path, a first test case for the program from which said control-flow graph is derived.

2. The method of claim 1 wherein the value of said metric for said goal node is at least as great as for any other node in said control-flow graph.

3. The method of claim 1 wherein said metric is based on the topology of said control-flow graph.

4. The method of claim 3 wherein each node of said control-flow graph is associated with a corresponding weight; and wherein the value of said metric for at least one node of said control-flow graph is based on a weight associated with another node of said control-flow graph.

5. The method of claim 4 wherein the weight associated with a node of said control-flow graph equals the number of lines of code of said program represented by said node.

6. The method of claim 4 wherein said metric for a node of said control-flow graph is the length of a shortest path from the starting node of said control-flow graph to said node; and wherein the length of a path equals the sum of the weights of nodes on said path.

7. The method of claim 1 further comprising:

(d) generating, based on said first path and said second path, updated values of said metric for nodes of said control-flow graph;

(e) generating a third path from the starting node of said control-flow graph to an ending node of said control-flow graph, wherein said third path includes a node having the largest updated value; and

(f) generating, based on said third path, a second test case for said program.

8. The method of claim 7 wherein each node of said control-flow graph is associated with a corresponding weight; and wherein said metric for a node n is the length of a shortest path to n from any node of a previously-generated path; and wherein the length of a path equals the sum of the weights of nodes on said path.

9. A method comprising:

(a) generating a first control-flow graph that is based on a program, wherein said first control-flow graph comprises a node that represents a single line of code of said program that invokes a subroutine, and wherein said node has one or both of a single incoming arc and a single outgoing arc;

(b) generating a first path from the starting node of said first control-flow graph to an ending node of said first control-flow graph; and

(c) generating a first test case for said program based on said path.

10. The method of claim 9 wherein generating said first path is based on the values of a metric for nodes of said first control-flow graph.

11. The method of claim 10 wherein said metric is based on the topology of said first control-flow graph.

12. The method of claim 10 wherein each node of said first control-flow graph is associated with a corresponding weight; and

wherein the weight associated with a node that lacks a subroutine invocation equals the number of lines of code of said program represented by said node; and

wherein the weight associated with a node that invokes a subroutine equals the largest value of said metric among nodes of a second control-flow graph that is derived from said subroutine; and

wherein the value of said metric for at least one node of said first control-flow graph is based on a weight associated with another node of said first control-flow graph.

13. The method of claim 12 wherein each node of a control-flow graph is associated with a corresponding weight; and wherein said metric for a node of a control-flow graph is the length of a shortest path from the starting node of said control-flow graph to said node; and wherein the length of a path equals the sum of the weights of nodes on said path.

14. The method of claim 12 wherein each node of said first control-flow graph is associated with a corresponding weight, said method further comprising:

(d) generating updated values of said metric for nodes of said second control-flow graph;

(e) generating, based on at least one of said updated values of said second control-flow graph, an updated weight for the node of said first control-flow graph that corresponds to said second control-flow graph;

(f) generating updated values of said metric for nodes of said first control-flow graph based on said first path and on said updated weight;

(g) generating a second path from the starting node of said first control-flow graph to an ending node of said first control-flow graph, wherein said second path includes a node of said first control-flow graph having the largest updated value; and

(h) generating, based on said second path, a second test case for said program.

15. The method of claim 14 wherein said metric for a node n of said first control-flow graph is the length of a shortest path to n from any node of a previously-generated path; and wherein the length of a path equals the sum of the weights of nodes on said path.

16. A method comprising:

(a) generating a first control-flow graph that is based on a subroutine of a program;

(b) generating a second control-flow graph that is based on said program, wherein said second control-flow graph comprises a node n that represents a single line of code of said program that invokes said subroutine, and wherein node n has one or both of a single incoming arc and a single outgoing arc;

(c) generating a first path from the starting node of said first control-flow graph to an ending node of said first control-flow graph;

(d) generating a second path from the starting node of said second control-flow graph to an ending node of said second control-flow graph that includes node n; and

(e) generating a first test case for said program based on said first path and on said second path.

17. The method of claim 16 wherein generating said first path is based on the values of a metric for nodes of said first control-flow graph; and wherein generating said second path is based on the values of said metric for nodes of said second control-flow graph.

18. The method of claim 17 wherein said metric for a node of a control-flow graph is based on the topology of said control-flow graph.

19. The method of claim 17 wherein said metric for a node of a control-flow graph is the length of a shortest path from the starting node of said control-flow graph to said node; and wherein each node of said control-flow graph is associated with a corresponding weight; and wherein the length of a path equals the sum of the weights of nodes on said path.

20. The method of claim 17 wherein each node of said second control-flow graph is associated with a corresponding weight; and wherein the weight of a first node of said second control-flow graph equals the largest value of said metric among nodes of said first control-flow graph; and wherein the weight of a second node of said second control-flow graph equals the number of lines of code of said program represented by second node; and wherein said metric for a node of said second control-flow graph is based on at least one weight associated with another node of said second control-flow graph.

Assignments (20)
(SECURITY INTEREST) GRANTOR'S NAME CHANGE Recorded Sep 21, 2023
From: AVAYA INC.
To: AVAYA LLC
Reel/Frame 065019/0231 →
RELEASE OF SECURITY INTEREST IN PATENTS (REEL/FRAME 61087/0386) Recorded May 18, 2023
From: WILMINGTON TRUST, NATIONAL ASSOCIATION, AS NOTES COLLATERAL AGENT
To: AVAYA MANAGEMENT L.P.; AVAYA INC.; INTELLISIST, INC.; AVAYA INTEGRATED CABINET SOLUTIONS LLC
Reel/Frame 063690/0359 →
RELEASE OF SECURITY INTEREST IN PATENTS (REEL/FRAME 53955/0436) Recorded May 18, 2023
From: WILMINGTON TRUST, NATIONAL ASSOCIATION, AS NOTES COLLATERAL AGENT
To: AVAYA MANAGEMENT L.P.; AVAYA INC.; INTELLISIST, INC.; AVAYA INTEGRATED CABINET SOLUTIONS LLC
Reel/Frame 063705/0023 →
RELEASE OF SECURITY INTEREST IN PATENTS (REEL/FRAME 045034/0001) Recorded May 18, 2023
From: GOLDMAN SACHS BANK USA., AS COLLATERAL AGENT
To: ZANG, INC. (FORMER NAME OF AVAYA CLOUD INC.); AVAYA INC.; INTELLISIST, INC.; AVAYA INTEGRATED CABINET SOLUTIONS LLC; OCTEL COMMUNICATIONS LLC; VPNET TECHNOLOGIES, INC.; HYPERQUALITY, INC.; HYPERQUALITY II, LLC; CAAS TECHNOLOGIES, LLC; AVAYA MANAGEMENT L.P.
Reel/Frame 063779/0622 →
INTELLECTUAL PROPERTY SECURITY AGREEMENT Recorded May 4, 2023
From: AVAYA INC.; AVAYA MANAGEMENT L.P.; INTELLISIST, INC.
To: CITIBANK, N.A., AS COLLATERAL AGENT
Reel/Frame 063542/0662 →
INTELLECTUAL PROPERTY SECURITY AGREEMENT Recorded May 3, 2023
From: AVAYA MANAGEMENT L.P.; AVAYA INC.; INTELLISIST, INC.; KNOAHSOFT INC.
To: WILMINGTON SAVINGS FUND SOCIETY, FSB [COLLATERAL AGENT]
Reel/Frame 063742/0001 →
RELEASE OF SECURITY INTEREST IN PATENTS AT REEL 45124/FRAME 0026 Recorded Apr 26, 2023
From: CITIBANK, N.A., AS COLLATERAL AGENT
To: AVAYA HOLDINGS CORP.; AVAYA INC.; AVAYA MANAGEMENT L.P.; AVAYA INTEGRATED CABINET SOLUTIONS LLC
Reel/Frame 063457/0001 →
INTELLECTUAL PROPERTY SECURITY AGREEMENT Recorded Aug 5, 2022
From: AVAYA INC.; INTELLISIST, INC.; AVAYA MANAGEMENT L.P.; AVAYA CABINET SOLUTIONS LLC
To: WILMINGTON TRUST, NATIONAL ASSOCIATION, AS COLLATERAL AGENT
Reel/Frame 061087/0386 →
BANKRUPTCY COURT ORDER RELEASING THE SECURITY INTEREST RECORDED AT REEL/FRAME 020156/0149 Recorded Jul 25, 2022
From: CITIBANK, N.A., AS ADMINISTRATIVE AGENT
To: AVAYA, INC.; AVAYA TECHNOLOGY LLC; OCTEL COMMUNICATIONS LLC; VPNET TECHNOLOGIES
Reel/Frame 060953/0412 →
SECURITY INTEREST Recorded Sep 25, 2020
From: AVAYA INC.; AVAYA MANAGEMENT L.P.; INTELLISIST, INC.; AVAYA INTEGRATED CABINET SOLUTIONS LLC
To: WILMINGTON TRUST, NATIONAL ASSOCIATION
Reel/Frame 053955/0436 →
SECURITY INTEREST Recorded Jan 23, 2018
From: AVAYA INC.; AVAYA INTEGRATED CABINET SOLUTIONS LLC; OCTEL COMMUNICATIONS LLC; VPNET TECHNOLOGIES, INC.; ZANG, INC.
To: CITIBANK, N.A., AS COLLATERAL AGENT
Reel/Frame 045124/0026 →
SECURITY INTEREST Recorded Jan 10, 2018
From: AVAYA INC.; AVAYA INTEGRATED CABINET SOLUTIONS LLC; OCTEL COMMUNICATIONS LLC; VPNET TECHNOLOGIES, INC.; ZANG, INC.
To: GOLDMAN SACHS BANK USA, AS COLLATERAL AGENT
Reel/Frame 045034/0001 →
RELEASE OF SECURITY INTEREST Recorded Jan 9, 2018
From: CITICORP USA, INC.
To: AVAYA, INC.; SIERRA HOLDINGS CORP.; AVAYA TECHNOLOGY, LLC; OCTEL COMMUNICATIONS LLC; VPNET TECHNOLOGIES, INC.
Reel/Frame 045032/0213 →
BANKRUPTCY COURT ORDER RELEASING ALL LIENS INCLUDING THE SECURITY INTEREST RECORDED AT REEL/FRAME 025863/0535 Recorded Dec 15, 2017
From: THE BANK OF NEW YORK MELLON TRUST, NA
To: AVAYA INC.
Reel/Frame 044892/0001 →
BANKRUPTCY COURT ORDER RELEASING ALL LIENS INCLUDING THE SECURITY INTEREST RECORDED AT REEL/FRAME 041576/0001 Recorded Dec 15, 2017
From: CITIBANK, N.A.
To: AVAYA INC.; AVAYA INTEGRATED CABINET SOLUTIONS INC.; OCTEL COMMUNICATIONS LLC (FORMERLY KNOWN AS OCTEL COMMUNICATIONS CORPORATION); VPNET TECHNOLOGIES, INC.
Reel/Frame 044893/0531 →
BANKRUPTCY COURT ORDER RELEASING ALL LIENS INCLUDING THE SECURITY INTEREST RECORDED AT REEL/FRAME 030083/0639 Recorded Dec 15, 2017
From: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A.
To: AVAYA INC.
Reel/Frame 045012/0666 →
SECURITY INTEREST Recorded Jan 27, 2017
From: AVAYA INC.; AVAYA INTEGRATED CABINET SOLUTIONS INC.; OCTEL COMMUNICATIONS CORPORATION; VPNET TECHNOLOGIES, INC.
To: CITIBANK, N.A., AS ADMINISTRATIVE AGENT
Reel/Frame 041576/0001 →
SECURITY AGREEMENT Recorded Mar 13, 2013
From: AVAYA, INC.
To: BANK OF NEW YORK MELLON TRUST COMPANY, N.A., THE
Reel/Frame 030083/0639 →
SECURITY AGREEMENT Recorded Feb 22, 2011
From: AVAYA INC., A DELAWARE CORPORATION
To: BANK OF NEW YORK MELLON TRUST, NA, AS NOTES COLLATERAL AGENT, THE
Reel/Frame 025863/0535 →
CONVERSION FROM CORP TO LLC Recorded May 12, 2009
From: AVAYA TECHNOLOGY CORP.
To: AVAYA TECHNOLOGY LLC
Reel/Frame 022677/0550 →