VirtRunner Command Line
About VirtRunner
You use VirtRunner to run virtual APIs (virtual services) from a command line. You can find the file in the <ReadyAPI directory>\bin
folder. The file name is virtrunner.bat
on Windows, and virtrunner.sh
on Linux and Mac.
Important
To use VirtRunner, you need the ReadyAPI Virtualization license.
General Syntax
The runner’s command line has the following format:
virtrunner.bat [optional-arguments] <test-project>
Running Multiple Virtual Services
If you are going to run multiple virtual services, make sure they have different ports or paths. You can specify a port and path for your virtual service in its properties. Also, use the -m command-line argument to specify the port and path your virtual service will use during the run.
Required arguments
Optional arguments
Example
The following command runs all the virtual services in the specified project:
virtrunner.bat "C:\Projects\Sample-REST-project.xml"
The following command runs two virtual services from the specified project:
The The First Service virtual service that uses the 8081 port and the /service-a path.
The SecondService virtual service that uses the 8082 port and the /service-b path.
virtrunner.bat -m"The First Service":8081:/service-a,SecondService:8082:/service-b "C:\Projects\my-project.xml"