IP Library Granted Patent US 12,455,812
Granted Patent B2
US 12,455,812 · App. 18/501,599 · Granted Oct 28, 2025

Automated conversion between behavioral tests and integration tests for software testing

Inventor: Benjamin Christopher Churchill (Tucson, AZ)
Assignee: Raytheon Company
G06F11/3688G06F11/3684G06F11/3696
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 12,455,812
App. No.
18/501,599
Granted
Oct 28, 2025
Kind
B2
Abstract

A method includes performing one or more behavioral tests of software code. The method also includes, during the one or more behavioral tests, recording interactions associated with the software code. The interactions include simulated incoming interactions to the software code and actual outgoing interactions from the software code. The method further includes converting the interactions into contracts, where each contract includes information defining how at least one interaction involving the software code occurs. In addition, the method includes generating one or more integration tests for the software code based on the contracts. The one or more behavioral tests are configured to test functional behaviors of the software code. The one or more integration tests are configured to test integration of the software code with at least one external component.

Claims (59)

1 . A method comprising:

performing one or more behavioral tests of software code;

during the one or more behavioral tests, recording interactions associated with the software code, the interactions including simulated incoming interactions to the software code and actual outgoing interactions from the software code;

converting the interactions into contracts, each contract comprising information defining how at least one interaction involving the software code occurs; and

generating one or more integration tests for the software code based on the contracts;

wherein the one or more behavioral tests are configured to test functional behaviors of the software code; and

wherein the one or more integration tests are configured to test integration of the software code with at least one external component.

2 . The method of claim 1 , wherein generating the one or more integration tests comprises:

generating one or more test doubles configured to replay one or more interactions based on one or more of the contracts; and

packaging the one or more test doubles and the one or more contracts as one or more artifacts.

3 . The method of claim 2 , wherein:

the one or more behavioral tests comprise multiple behavioral tests; and

the one or more test doubles are generated for a subset of the behavioral tests during generation of the integration tests, at least one of the behavioral tests marked as not being used to generate the one or more test doubles.

4 . The method of claim 1 , wherein:

during the one or more behavioral tests, the functional behaviors of the software code are tested in isolation from the at least one external component; and

the interactions associated with the software code are recorded using at least one spy proxy, the at least one spy proxy recording interactions between at least one controller associated with the software code and at least one simulated external component.

5 . The method of claim 1 , wherein each contract defines how the at least one external component is able to make a request to the software code and what to expect in response to that request.

6 . The method of claim 1 , further comprising:

storing the one or more behavioral tests and the one or more integration tests in a database.

7 . The method of claim 6 , wherein integration testing of the at least one external component is performed using the one or more integration tests stored in the database.

8 . An apparatus comprising:

at least one processing device configured to:

perform one or more behavioral tests of software code;

during the one or more behavioral tests, record interactions associated with the software code, the interactions including simulated incoming interactions to the software code and actual outgoing interactions from the software code;

convert the interactions into contracts, each contract comprising information defining how at least one interaction involving the software code occurs; and

generate one or more integration tests for the software code based on the contracts;

wherein the one or more behavioral tests are configured to test functional behaviors of the software code; and

wherein the one or more integration tests are configured to test integration of the software code with at least one external component.

9 . The apparatus of claim 8 , wherein, to generate the one or more integration tests, the at least one processing device is configured to:

generate one or more test doubles configured to replay one or more interactions based on one or more of the contracts; and

package the one or more test doubles and the one or more contracts as one or more artifacts.

10 . The apparatus of claim 9 , wherein:

the one or more behavioral tests comprise multiple behavioral tests; and

the one or more test doubles are generated for a subset of the behavioral tests during generation of the integration tests, at least one of the behavioral tests marked as not being used to generate the one or more test doubles.

11 . The apparatus of claim 8 , wherein:

during the one or more behavioral tests, the at least one processing device is configured to test the functional behaviors of the software code in isolation from the at least one external component; and

the at least one processing device is configured to record the interactions associated with the software code using at least one spy proxy, the at least one spy proxy configured to record interactions between at least one controller associated with the software code and at least one simulated external component.

12 . The apparatus of claim 8 , wherein each contract defines how the at least one external component is able to make a request to the software code and what to expect in response to that request.

13 . The apparatus of claim 8 , wherein the at least one processing device is further configured to store the one or more behavioral tests and the one or more integration tests in a database.

14 . The apparatus of claim 13 , wherein the at least one processing device is configured to convert a suite of behavioral tests into a suite of integration tests and to store the suite of behavioral tests and the suite of integration tests in the database.

15 . A non-transitory machine readable medium containing instructions that when executed cause at least one processor to:

perform one or more behavioral tests of software code;

during the one or more behavioral tests, record interactions associated with the software code, the interactions including simulated incoming interactions to the software code and actual outgoing interactions from the software code;

convert the interactions into contracts, each contract comprising information defining how at least one interaction involving the software code occurs; and

generate one or more integration tests for the software code based on the contracts;

wherein the one or more behavioral tests are configured to test functional behaviors of the software code; and

wherein the one or more integration tests are configured to test integration of the software code with at least one external component.

16 . The non-transitory machine readable medium of claim 15 , wherein the instructions that when executed cause the at least one processor to generate the one or more integration tests comprise:

instructions that when executed cause the at least one processor to:

generate one or more test doubles configured to replay one or more interactions based on one or more of the contracts; and

package the one or more test doubles and the one or more contracts as one or more artifacts.

17 . The non-transitory machine readable medium of claim 16 , wherein:

the one or more behavioral tests comprise multiple behavioral tests; and

the one or more test doubles are generated for a subset of the behavioral tests during generation of the integration tests, at least one of the behavioral tests marked as not being used to generate the one or more test doubles.

18 . The non-transitory machine readable medium of claim 15 , wherein:

the instructions when executed cause the at least one processor, during the one or more behavioral tests, to test the functional behaviors of the software code in isolation; and

the instructions when executed cause the at least one processor to record the interactions associated with the software code using at least one spy proxy, the at least one spy proxy configured to record interactions between at least one controller associated with the software code and at least one simulated external component.

19 . The non-transitory machine readable medium of claim 15 , wherein each contract defines how the at least one external component is able to make a request to the software code and what to expect in response to that request.

20 . The non-transitory machine readable medium of claim 15 , further containing instructions that when executed cause the at least one processor to store the one or more behavioral tests and the one or more integration tests in a database.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 3, 2023
From: CHURCHILL, BENJAMIN CHRISTOPHER
To: RAYTHEON COMPANY
Reel/Frame 065454/0967 →
Continuity (1)
Related Publication 20250147867A1 · May 8, 2025
References Cited (12)
US 9135147B2 · Artzi et al. · 2015 [cited by applicant]
US 10289535B2 · Yadav · 2019 [cited by examiner]
US 10361944B2 · Chavda et al. · 2019 [cited by applicant]
US 10437712B1 · Tyler et al. · 2019 [cited by applicant]
US 10713365B2 · Biswas et al. · 2020 [cited by applicant]
US 10838848B2 · Fong · 2020 [cited by applicant]
US 11354226B2 · Allweil · 2022 [cited by examiner]
US 20230359746A1 · Wang · 2023 [cited by examiner]
US 20240256428A1 · Huang · 2024 [cited by examiner]
International Search Report and Written Opinion of the International Searching Authority dated Feb. 12, 2025 in connection with International Patent Application No. PCT/US2024/054400, 9 pages. [cited by applicant]
Pactflow, “[Introduction to contract testing—Part 2] Contract testing and how Pact works”, YouTube Video, Mar. 2021, 2 pages. [cited by applicant]
Pactflow, “[Introduction to contract testing—Part 3] Demo—Contract testing with Pact JS”, YouTube Video, Mar. 2021, 2 pages. [cited by applicant]