Test Case Editor

Applies to ReadyAPI 3.57, last modified on December 20, 2024

A test case is a collection of test steps that are assembled to test some specific aspect of your service. Test cases provide clearly identifiable units of the functionality that can be tested independently.

The test case can contain any number of test steps. When you run tests, ReadyAPI runs them in sequence. The test case run is successful when none of the test steps fail.

You can arrange any number of test cases in a test suite and even modularize them to call each other for complex testing scenarios.

Use the test case editor to manage test cases: configure their behavior, examine the test run history, debug tests, and so on.

Test case editor

Click the image to enlarge it.

Toolbar

The test case toolbar contains quick access to the most frequently used commands.

Test case editor toolbar

Click the image to enlarge it.

Test Steps Page

The main purpose of the Test Steps page is managing test steps. To learn how to do it, see Managing Test Steps.

Besides that, panels of the page help you modify various test case aspects:

  • Description – Specifies the text description of the test case.

  • Properties – Manages the list of test case properties. See the Test Case Properties section.

  • Setup Script – Specifies a script that is run at the start of a test case run. To learn more, see Setup, TearDown, and Report Scripts.

  • TearDown Script – Specifies a script that is run when the test case run finishes. To learn more, see Setup, TearDown, and Report Scripts.

  • Report Script – Specifies a script that is run when you generate a report. To learn more, see Script Extensions.

  • Report Parameters – Manages the list of parameters used for report creation. To learn more, see Script Extensions.

Other Editor Pages

To learn about See
Transaction Log Transaction Log Page
Compare Compare Page
History Test History Page
Coverage Coverage Testing
Requirements Requirements Compliance
Step-by-Step Run About Debugging Tests
Test On Demand Run Tests On Demand

Test Case Properties

Besides editor panels, you can adjust test case behavior by using its properties in the property tabs in the Navigator.

Name Description
Name

The name of the test case.

Special characters in the name, including (but not limited to) &, -, /, (, and ), may cause issues with reporting.

By using the Custom Test Case Properties tab in the Navigator and the Properties panel in the test case editor, you can create any number of properties. These properties are available to other test cases in your project. To manage the property list, use the toolbar:

Custom test case properties can be stored locally in your workspace file by selecting the checkbox on the right. To learn more about it, see Locally Stored Properties.

Test Case Options

Use test case options to configure test case behavior according to your needs.

The test case options are grouped into three tabs, according to aspects they relate to:

Basic

The Basic Options define general behavior for the test case.

Basic options
Option Description
Search Properties Collect properties from previous test steps. This option provides scripting access to all test step properties.
Session By default, ReadyAPI closes the session after each request. Enable this option to prevent ReadyAPI from closing the session for the entire test case. In this case, ReadyAPI stores cookies received from the server and sends them back in the subsequent requests. This helps you create tests that simulate real user behavior.
Abort on Error Stops the test run when a test step fails.
Fail Test Case on Error Marks the test case as failed if a test step fails.
Note: This option does not stop the test run.
Discard Successful Results Discards all successful results after the test step execution is complete. Enable this option to use less memory in your tests.
Make sure to keep this option disabled if you use the Assertion test step, otherwise, you will not get the expected result.
Tip: This option is identical to the Discard PASS Results within Loop option available for the Data Source Loop test step, though the latter affects only the steps within the loop.
Socket Timeout The duration (ms) of a connection socket. The empty value or 0 sets the timeout to 1 minute.
Default value: 0.
Test Case Timeout The duration (ms) until Test Case times out. The empty value or 0 does not set the timeout.
Default value : 0.
Max Results The maximum number of results to keep. Older results are discarded and cannot be asserted with the Assertion test step.
The empty value or 0 means no results are discarded.
Default value: 5.

WS-RM Options

When running a test case containing many requests, it may need to run all requests in the same WS-RM Sequence instead of creating a new one for each request.

The WS-RM Options tab is used to enable WS-RM (Web Services Reliable Messaging) for requests in the test case.

WS-RM
Option Description
WS-RM Enabled Enables the WS-RM Sequence
WS-RM Version A version of WS-RM used by the target service
WS-RM AcksTo Required. WS-Addressing Endpoint for SequenceAcknowledgement
WS-RM Expires Defines the duration for the Sequence.
Note: If empty never expires = "PT0S"

The authorized WS-RM Sequence is shared among all test steps in the test case. The credentials will be used to connect before the first test step and disconnect after the last test step in the test case.

Enabling WS-RM here will generate a WS-RM Sequence for all requests in the test case instead of one for each.

Zephyr

Use the Zephyr tab to associate a test case with a Zephyr test. To learn more, see Zephyr Squad Integration.

Zephyr options
Option Description
Zephyr Test ID The ID of the Zephyr test to associate a test case with.

Examples

Here are several sample test cases:

Login and Logout Test Case

XML Data Source Test Case

See Also

Project Editor
Test Suite Editor
Running a Test Case
Test Steps

Highlight search results