Skip to main content

Test execution

In order to run your test scenario you will need to ensure your project contains a valid RestQA configuration file .restqa.yml

Then from there you can run the command:

restqa run

The command above will search for *.feature files recursively from the root folder and execute them.

Specify the configuration file

You can also explicitly specify a configuration file to use with the --config CLI option (resolved relative to cwd):

restqa run --config my-config.yml

Or through the environment variable RESTQA_CONFIG

RESTQA_CONFIG=my-config.yml restqa run

Specify the target environemt

You can also specify the environment to use with the --env CLI option:

restqa run --env uat

Or through the environment variable RESTQA_ENV

RESTQA_ENV=uat restqa run

Specify the feature file

Glob patterm

restqa run tests/integration/**/*.feature

Feature directory

restqa run tests/integration/

Specify a feature file

restqa run tests/integration/welcome.feature

Specify the Gherkin Tag

If your feature or your scenario has a tag:

@success
Feature: Customer detail feature

Scenario: Retrieve all the customer information
...

You can run the following command

restqa run -t @success