Step-by-Step guide on using Traffic Parrot, a tool for application virtualization:
Traffic Parrot significantly reduces software testing costs and speeds up the product release process by taking advantage of API imitation or simulation, which is a part of application virtualization.
Recommended IPTV Service Providers
- IPTVGREAT – Rating 4.8/5 ( 600+ Reviews )
- IPTVRESALE – Rating 5/5 ( 200+ Reviews )
- IPTVGANG – Rating 4.7/5 ( 1200+ Reviews )
- IPTVUNLOCK – Rating 5/5 ( 65 Reviews )
- IPTVFOLLOW -Rating 5/5 ( 48 Reviews )
- IPTVTOPS – Rating 5/5 ( 43 Reviews )
Imitation and simulation are key techniques that contribute to application testing isolation.
Application testing isolation means moving from complicated test scenarios involving multiple applications to those specifically focusing on the application of interest.
The terms Imitation and Simulation basically refer to replacing a real service with a mocked one, enabling direct control over its functions.
In this Traffic Parrot review, we dive into how to use Traffic Parrot, an application virtualization tool that opens new doors for JMS teams looking into imitation or simulation.
Here’s What You’ll Learn:
Why Adopt Service virtualization
- Begin automation suites as early as possible
- Concisely simulate experiment conditions to reduce dependencies and cut costs
- Implement shift-left testing and work alongside the development team
- Function within a genuine Agile environment
These strategies enable you to:
- Test your application even when its dependencies are not available.
- Test scenarios that are typically hard to reproduce.
- Decrease the time required for setting up test data.
Traffic Parrot simplifies JMS testing by allowing you to set up JMS test scenarios without the need for intricate test data configurations across several systems.
It supports both IBM® WebSphere MQ and Apache ActiveMQ, adding more depth to the JMS testing toolkit.
The Problem Traffic Parrot Helps Solve
Firstly, let’s take a look at different situations where we might want to imitate and simulate JMS messages.
A typical communication pattern involves an IBM® WebSphere MQ broker with a request queue and a response queue:
- System A sends a request message to the request queue.
- The request message is consumed by System B.
- After undertaking internal processing, System B replies by delivering a response message to the response queue.
- Then, System A consumes the response message.
During the testing of System B in this situation, several obstacles might come in the way such as:
- API or the complete system might not exist yet.
- The system might currently be in use by another tester.
- There might be technical issues with the test environment.
- Setting up test data might present difficulties or be impossible.
- Simulating error responses might be impossible.
In such cases, we can use Traffic Parrot to impersonate System B, facilitating isolated testing of System A. Traffic Parrot accomplishes this by mimicking System B and consuming request messages and producing appropriate response messages.
How to Use Traffic Parrot to Send JMS Response Messages
Let’s now discuss a standard workflow that involves Traffic Parrot for replicating and mimicking a system that receives and sends JMS messages.
As a tester of System A, I want Traffic Parrot to act as System B by delivering response messages to System A. This is achieved by configuring Traffic Parrot to respond with a specific message on a specific queue. This configuration is facilitated by the browser-based user interface of Traffic Parrot.
Afterwards, we activate the replay mode in Traffic Parrot to provide instructions on how to respond to request messages.
And there you have it! It’s that simple – we now have a fully operational JMS imitation. We can test System A while adjusting Traffic Parrot’s response (acting as System B) to suit our testing scenario.
This can include regular response messages as well as error responses that may be tough to recreate using real data (for example, an item going out of stock).
Advanced Features
Traffic Parrot comes with a host of advanced features that allow for the simulation of complex behaviours with relative ease.
Let’s delve into some of these advanced features.
It’s common for response messages to retain some information from the request message.
For example, suppose System B responds to a list of requested items and each item must be mentioned in the response. In Traffic Parrot, we can avail the dynamic responses feature for this purpose. The example below demonstrates how this can be fulfilled for an XML message. Similarly, this also works for JSON messages and raw text messages.
(Note: Click on the image for a larger view)
With the templating approach, you can:
- Include request data in the response.
- Include the current date/time in the response.
- Generate random numbers in the response.
- Loop over certain parts of the request in the response.
Testing Existing Systems with Traffic Parrot
When you are testing an existing system that was previously only subjected to end-to-end testing with all its dependencies, you typically have numerous message types that need to be configured for isolated testing using service virtualization.
Traffic Parrot provides features like record and replay that help in capturing existing messages. These can later be edited to suit testing needs. Traffic Parrot does this by intercepting request and response messages, pairing them, creating mappings, and then forwarding them to the correct destinations.
This method is a great way to quickly set up tests on an existing system without having to manually define mappings individually, which can take a lot of time. Instead, we can record traffic in a test environment and adjust the gathered mappings to meet our needs.
To understand this process better, take a look at this JMS IBM MQ record and replay tutorial.
Conclusion
Traffic Parrot empowers us to test an application without needing developer intervention.
We can customize JMS behavior through the user-friendly, browser-based UI of Traffic Parrot, making it fast and easy to test our system under a variety of scenarios.
We also looked at how Traffic Parrot can record and replay traffic from existing systems, which can be extremely useful when initially setting up JMS response messages for testing. This is particularly beneficial when dealing with legacy systems that were not designed with testability as a key consideration.
What’s next? – Download Traffic Parrot service virtualization and give it a try. Check out this step-by-step getting started guide to quickly get acquainted with the tool.
If you have any questions about this tool, feel free to contact us.