Automated Testing Framework for Asynchronous Message Validation

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Conventional testing frameworks are inadequate for validating messages in a publisher/subscriber design pattern, especially when microservice applications use asynchronous communication models, as they cannot execute unit tests for messages triggered by events like HTTP requests.

Innovation Solution

An automated testing framework is implemented using a processor to receive electronic resources, identify step definitions, annotate them, execute them with an inversion-of-control container, load a message handler object, transmit messages to a data structure maintaining message queues, and validate messages based on these queues, supporting behavior-driven development and object-oriented programming methods.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Adaptability or versatility

If conventional testing frameworks (e.g., REST API assertion framework) are used, then the frameworks can handle request/response models, but they cannot validate published messages in asynchronous publisher/subscriber patterns

Engineering Contradiction:
Improvecompatibility with communication modelsVSAvoidmessage validation capability
Core Design Contradiction:
Adaptability or versatilityVSReliability

Solution Approach 1:

The patent inverts the conventional testing approach by embedding both publisher and subscriber in the same runtime environment, allowing the subscriber to act as its own test validator. Instead of using external request/response frameworks, the system validates messages internally through the subscriber's perspective, enabling assertion of asynchronous message patterns.

Inventive Principle:
Principle #13The other way round (Inversion)

Solution Approach 2:

The testing framework achieves multi-functionality by combining publisher and subscriber capabilities within a single runtime environment. This unified system can both publish messages and validate them, eliminating the need for separate conventional testing frameworks and enabling comprehensive validation of asynchronous communication patterns.

Inventive Principle:
Principle #6Universality (Multi-functionality)

2Productivity

If microservice applications use asynchronous communication models, then rapid testing of use cases should be enabled, but conventional frameworks cannot execute unit tests for event-triggered messages

Engineering Contradiction:
Improvetesting speedVSAvoidtest execution capability
Core Design Contradiction:
ProductivityVSEase of operation

Solution Approach 1:

The patent performs preliminary action by bootstrapping both publisher and subscriber into the same runtime environment before testing begins. This pre-configuration allows unit tests to execute directly against the message validation logic without requiring external framework setup, enabling rapid testing of event-triggered messages.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system implements self-service by enabling the subscriber to validate its own received messages through embedded validation logic. This self-validating approach eliminates dependency on external conventional frameworks, making test execution straightforward and enabling rapid productivity gains.

Inventive Principle:
Principle #25Self-service

3Reliability

If publisher and subscriber are bootstrapped to the same runtime environment, then continuous testing platform is generated, but device complexity increases

Engineering Contradiction:
Improvecontinuous testing capabilityVSAvoidruntime environment configuration
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The patent merges publisher and subscriber into the same runtime environment, creating an integrated testing platform. This consolidation enables continuous testing capability by allowing both message publishing and validation to occur within a unified system, though it does increase configuration complexity.

Inventive Principle:
Principle #5Merging (Combining)

Data Source

PatentUS11347630B1Method and system for an automated testing framework in design pattern and validating messages
Publication Date: 2022.05.31 JPMORGAN CHASE BANK NA
  • US11347630B1 patent drawing
  • US11347630B1 patent drawing
  • US11347630B1 patent drawing

AI summary

A method for providing an automated testing framework to validate a plurality of messages is disclosed. The method includes receiving, from a developer, an electronic resource that includes a feature file relating to a development of an application; identifying, from the electronic resource, a set of step definitions relating to a payload test assertion; annotating the set of step definitions to include a feature step definition; executing the annotated electronic resource by using an inversion-of-control container based on a configuration step definition; loading a message handler object that manages payload listening; transmitting, by using the message handler object, a message generated from the execution of the annotated electronic resource to a data structure that maintains a plurality of message queues; and validating the message based on the plurality of message queues.