You can use the Request-Reply messaging pattern in your tests.
IBM® DevOps Test Integrations and APIs (Test Integrations and APIs) sends a request message that you create by using the email address configured for the
sender in your project to an email address configured as the recipient. When a response from
the recipient is received for the sent email message in the email account, the message that
is received is displayed for you in Test Integrations and APIs.
-
Create a test that uses MEP by right-clicking the operation and selecting .
-
Enter a name for the test and then click
OK.
For example, the test name can be
Test_Request-Reply.
The test is created in the operation. Because the MEP for the
Request-Reply action was configured, the test is
created with the settings configured in the MEP tab for an operation for the
Request-Reply action. The transport that was set in
the MEP tab for the operation is selected.
For example, the
Request-Reply action is displayed in the
Test Factory for the email resource that shows
the schema as text and the email resource as the transport resource.

-
Select your action from the following
options:
- You can run the test with the
parameters configured for the MEP. Go to Step
5.
- You can modify any of the parameters in
the test before you run it or if you have duplicated the
operation and want to run a different test by modifying the
parameters copied, go to Step
4.
-
Modify any of the settings that you want to specify
in the test by completing the following steps:
The MEP settings that you configured in the MEP tab for the operation are
displayed.
-
Double-click the Send Request test step.
The
Send Request window is displayed with the
settings configured in the MEP tab for the operation.

-
- The email transport.
- The text in the Subject field.
- The email address of the recipients in the
To field.
- The email address of the sender in the
From field.
- The email address of the recipients to whom a reply message
is to be sent in the Reply To
field.
- Add or change the email address of recipients to whom a copy
of the message is to be delivered in the
CC field.
- Add or change the text to be included in the body of the
message.
-
Double-click the Receive Reply test step.
The
Receive Reply window is displayed with the
settings configured in the MEP tab for the operation.

-
Modify any of the following parameters:
- Add or change the text you want to be used to validate the
message received.
- Depending on the email service you are testing, you might
have to increase the time until a reply is received.
-
Run the test.
You have created and run a test that uses the
Request-Reply messaging pattern.