Applies to ReadyAPI 2.2, last modified on November 17, 2017

What Is ReadyAPI TestServer?

ReadyAPI TestServer is a REST-based web service running in your network. It receives and runs special JSON requests – test recipes – that specify the test actions to be executed.

TestServer is based on the ReadyAPI engine. However, it does not require a ReadyAPI instance on the computer, where it is running. The TestServer version number – 2.2.0 – corresponds to the version of the ReadyAPI engine, which TestServer uses.

ReadyAPI TestServer recipes are compatible with ReadyAPI.

Why to Use TestServer

  • You can use it as an online 24x7-available runner for your API tests.

  • It gives you the possibility of running API tests from the command line, as well as from regular Windows, Linux or Mac applications. This makes TestServer extremely useful for developers, who would like to create API tests in their IDEs, without using the ReadyAPI graphic UI.

  • With TestServer, you can run ReadyAPI test projects without buying extra ReadyAPI instances for your team. Anyone who sends a correct request (test recipe) can run a test.

  • TestServer recipes can be opened with ReadyAPI. So, a developer can use TestServer to do basic testing of a service, and then pass recipes to the QA team for further testing. You can do this for both text-based and code-based recipes.

Test Recipes

A test recipe is a JSON-format piece of text:

{ "testSteps": [
  {
    "type" : "REST Request",
    "method": "GET",
    "URI" : "http://my-server-url.com",
    "parameters": [
      {"name" : "q", "value": "Boston"},
      ...
    ]
  }
]
}

You can create test recipes in the following ways:

  • Text-Based Recipes

    You can create a test recipe by writing JSON code in any text editor. We call these recipes text-based recipes.

    To execute them, you send your text files to TestServer through a command-line tool like cURL. cURL is preinstalled on macOS and on many Linux systems. Windows users can download it from http://curl.haxx.se/download.html.

  • Code-Based Recipes

    You can create test recipes by writing program code that will generate test recipe text and send it to TestServer. We call these recipes code-based recipes. To execute them, tools like cURL are not needed.

    To create code-based recipes, you need to use a special TestServer Client library. See below.

How TestServer Works

You can send test recipes to TestServer running on your computer or on any other machine in your network.

How test recipes work

Click the image to enlarge it.

By default, TestServer works via HTTPS on port 8443 and HTTP on port 8080. The port numbers are configurable.

TestServer uses basic authentication. To run test recipes, you need to create a user on the service and specify this user authentication data when running a recipe. The actual steps to perform are described as part of the test recipe creation procedure.

Licensing

ReadyAPI TestServer licenses specify the maximum number of test recipes that TestServer can process per day. If you or your team exceeds this limit, you will have to wait for the next day to continue. For information on license activation steps and on specifics of the test recipe calculation, see Licensing ReadyAPI TestServer.

TestServer JSON Format Definition

You can find the Swagger definition for test recipes and TestServer at:

Note: server is the name or IP address of your TestServer instance (for instance, localhost); port is the port number that TestServer uses. By default, it is 8080 for HTTP and 8443 for HTTPS. The port number is configurable.

TestServer Library

To create code-based recipes, you need to use a special TestServer Client library. Currently, Java and .NET libraries are available.

You can use Maven or NuGet to quickly get the package. You can also get the library source code from the GitHub repository:

The library is open-source and distributed under the Apache license. Feel free to raise issues and contribute to the repository.

What Test Steps a Recipe Supports

How to Create Test Recipes

Online TestServer Demo

SmartBear provides a free online TestServer demo. You can find it at the following address:

TestServer requires Basic authentication to work with the recipes you send. Use the following credentials:

  • Username: demoUser

  • Password: demoPassword

This demo only supports REST requests and property transfers. To use other TestServer features, download and install the local copy of TestServer.

Importing Test Recipes Into ReadyAPI

You can import your test recipes to ReadyAPI to get the following benefits:

  • ReadyAPI interface that represents the test visually and helps you manage it.

  • Test recipes created by developers serving as a basis for tests of QA engineers.

  • Additional ways to expand the test, such as virtual services to send requests to, or the ability to run several test cases at the same time.

You can import both text-based and code-based recipes to ReadyAPI.

See Also

TestServer Tutorials
Typical Tasks
TestServer – How to
Introducing TestServer