To run tests, TestLeft uses the TestComplete test engine. The test engine is an essential part of TestLeft, TestExecute or TestComplete. All these products use the same test engine. Tests created with TestLeft can work on any computer where TestLeft, TestExecute or TestComplete is installed.
In your TestLeft tests, you connect to the test engine and specify test commands the engine will execute (for example, launching the tested application, simulating user actions or posting data to the test log).
Initially, you may want to create and debug your TestLeft tests locally. In this case, you need to connect to the test engine on a local computer. To do this, use the
The code below illustrates how to connect to a local test engine:
IDriver driver = new LocalDriver();
Visual Basic .NET
Dim driver As New LocalDriver()
Driver driver = new LocalDriver();
Afterwards, you may want to run TestLeft tests on remote computers. In this case, you will have to connect to the test engine on the remote computers. To do this, use the
The code below shows how to connect to a remote test engine:
IDriver driver = new RemoteDriver("myHost", "user1", "pass1");
Visual Basic .NET
Dim driver As New RemoteDriver("myHost", "user1", "pass1")
Driver driver = new RemoteDriver("myHost", "user1", "pass1");
To learn how to create and use the
RemoteDriver objects, see About Driver Objects.
If you created your project using the TestLeft MSTest Project, TestLeft NUnit Project, or TestLeft xUnit Project template, then you already have one instance of
The TestLeft RESTful service must be running on the local and remote computers.
When you run tests, the TestLeft RESTful service starts automatically. However, when you are creating tests, you may need the service to be running so that you can explore the object hierarchy from TestLeft UI Spy:
Launch the TestLeft test runner (<TestLeft>\Bin\TestExecute.exe).
– or –
Start the TestLeft UI Spy (<TestLeft>\Bin\SmartBear.TestLeft.UI.Spy.exe) and click Refresh Object Tree.
It will start the service automatically.
As an alternative, you can use the TestComplete service if it is installed on your computer. To start the service, launch TestComplete with the REST API plugin enabled:
In TestComplete, select File | Install Extensions from its main menu.
TestComplete will open the Install Extensions dialog. Make sure the REST API plugin is installed and enabled.
You cannot have several services running at the same time on the same computer. Make sure that only one service is currently running. Otherwise, an error will occur.
- Windows Firewall should be configured to allow communication between TestLeft and the test engine on the local or remote computer. See Configuring Windows Firewall.