Rational Integration Tester has been built to help test and virtualize modern environments. These environments might present themselves with a simple front end, but may well have a number of heterogeneous components that communicate with each other in the background. While we can test just the surface elements, we do not know what’s going on beneath the surface.
Traditional UI-based testing has very limited capabilities in this area. We can stimulate the system, and while we know that doing this might cause several subsystems to interact in various ways – possibly talking to web services, posting messages on JMS queues, or updating databases, we do not know exactly what’s happening – all we can see is the end result. Either the UI is updated correctly or not.
However, there are a number of situations where this approach is unsatisfactory. For example, entering some data in the UI might spawn messages to different parts of the system. One of these might trigger a database update. If we are not careful, we could end up in a situation where the wrong data is entered into the database. In other situations, we might send incorrect messages to external services. Yet if the UI appears to be correct, a UI-testing tool will allow the test to pass. Rational Integration Tester is designed to go further into the system, and uncover what really happens beneath the surface, allowing us to get the full picture. Did the system actually function correctly during our test? If not, where did things go wrong?
Before we go any further, we need to define a few terms. Some of these are used by different tools to mean different things. For the most part, there is nothing challenging here, but we need to make sure that we are speaking the same language.
Message: The message is whatever information is being sent or received by a component. This could be, for example, an XML message, or a file on a hard disk. The message can later be split into the message header, which includes information such as the destination name, and the message body, which will be the actual payload of the message.
Schema: The schema describes the structure of the message, so for an XML message, this might come from an XSD or WSDL.
Transport: The transport is how the message gets from the publisher to the subscriber. This might be point to point communication – for example, HTTP. It might also be through other methods that require extra infrastructure, such as posting a message to a message queue. (Application level on OSI stack)
- Rational Integration Tester is the main tool used for design and creation of resources. It can also be used to run these resources.
- Rational Test Control Panel is a control panel for the user to view the rest of the components in the system, and acts as a hub for communications between Rational Integration Tester and those components, as well as being able to direct those components in its own right.
- The Rational Integration Tester Agent has two major modes of operation, depending on its license: Rational Test Virtualization Server and Rational Performance Test Server provide virtualization and performance testing capabilities, respectively. These are usually situated on other computers, though in a training scenario, everything will be on one computer. Also note that Rational Test Virtualization Server and Rational Performance Test Server will often be referred to as Agents in the documentation and the rest of this material.
- The Platform Pack provides tools to work with the system under test. The simplest example, and the one we will be using shortly, will be the HTTP proxy.
- Finally, you might have a results database, used for holding historical test results.
So, lets say you want to perform a web service recording using Rational Integration Tester:
- Click the record button in Rational Integration Tester, having set up an event monitor. Rational Integration Tester then creates a proxy rule, that is sent to the server.
- Rational Test Control Panel then passes that rule onto each of the proxies in the system. Note that there might be multiple proxies, one for each client whose traffic you are recording. It’s also important to note that Rational Integration Tester does not have direct control over the proxies; everything is done through the server.
- Each proxy then copies any messages that it receives that are communications between the client application and the web service that you are recording, and sends that copy to Rational Integration Tester. Note that there may be multiple clients and multiple web services, and that no messages are altered at this stage.
- When recording is finished, Rational Integration Tester tells Rational Test Control Panel to remove the proxy rule; the proxies are then provided with updates.