Set up a LeanFT grid node
To run tests on applications in different environments or distribute your application testing among multiple machines, set each machine up as a LeanFT grid node.
What is a LeanFT grid node?
A LeanFT grid node is a machine connected to a LeanFT grid, providing an environment for running LeanFT test operations.
When running a test using a grid, the test requests an environment that provides certain capabilities. The grid finds a node machine with the requested capabilities, and uses that node for the test's LeanFT operations. For details, see LeanFT Grid.
To satisfy this role, a node must have the following:
- The application you are testing
- The LeanFT runtime engine, running as a node.
- Any capabilities required for your test to run.
- A connection to the grid, configured in the node's runtime engine settings. For details, see Grid Connection Settings.
Capabilities describe the environment on your node machine, as related to testing applications. These can be conditions that the test needs in order to run, as well as environment conditions in which you want to test your application. Capabilities can include operating systems, browser types and versions, memory requirements, available frameworks, and so on.
When running a test using a grid, the test includes a description of the environment to use. The description consists of capabilities, described in name-value pairs. The grid checks the capabilities provided by its nodes and selects one that matches the tests requirements.
A node's capabilities are made up of:
Operating system type and version, which LeanFT detects automatically.
Available browsers and versions, configured in the node settings. For details, see Add-ins.
The add-ins loaded on the node, configured in the node settings. For details, see Add-ins.
Additional capabilities provided by the node, that you describe in name-value pairs similar to the ones in a test's environment description. Describe these capabilities in the node settings. For details, see Custom Capabilities.
- The node's name.
You have two nodes, set up as follows:
|Capabilities||Node A||Node B|
Internet Explorer 11
The grid handles the following test runs:
|Test's environment description||Node used by grid|
|Windows OS and Internet Explorer||
|Linux machine with Java 7||B|
|Firefox browser (no other capabilities specified)||
A or B, depending on availability
Set up a LeanFT grid node machine
On each node machine, perform the following steps:
Prepare your testing environment and the application you want to test.
Run the LeanFT installation and install the LeanFT runtime engine only. For details, see LeanFT installation guide.
LeanFT > LeanFT Grid > LeanFT Runtime (Grid Node)
./leanft start --role=node
(by default, /opt/leanft/bin)
./leanft start --role=node
LeanFT installation directory
(by default, /Applications/LeanFT)
Note: At this point it does not matter if your LeanFT grid is running or not. The nodes connect to the grid when they and it are up and running.
Configure the node's runtime engine settings. See Configure a LeanFT node's runtime engine settings, below.
If the grid's connection mode is remote secured, make sure you have a trusted copy of the grid's encryption certificate set up on the node machine.
Optional setup steps:
If you plan to... ...you need to How? Test Web-based applications
Make sure the Functional Testing Agent extension is enabled in your browser.
For details, see Set up web browsers and controls.
Test desktop applications Configure your node to enable LeanFT tests to launch desktop applications.
For details, see Run desktop applications using LeanFT SDK.
This section explains how to configure the connection to the grid machine, the capabilities provided by this node, the technology add-ins to load and more.
- Prerequisite: Run the LeanFT run-time engine as a node.
Open the LeanFT settings dialog box:
Right-click the LeanFT runtime engine icon in the task bar and select Settings.
Note: On Linux machines, if the icon is not available in the task bar, run the following command to open the dialog box:
Modify the Engine settings as needed.Add-ins
Select the add-ins needed for the technologies in the application you are testing. Leaving unnecessary add-ins selected can slow performance, or in some cases, cause conflicts with object identification.
If the Web add-in is selected, select the browsers available for testing on this node.
For Chrome and Firefox you can specify multiple available browser versions. Click the Edit button for the relevant browser to enter the available versions.
For each version, specify the browser's installation location, and optionally, the folder where LeanFT can find the browser's Profile.
PhantomJS does not have a default installation location. You must specify the browser version and where it is installed.
- If you do not enter specific browser versions, LeanFT uses this browser from the default browser installation location and does not know the browser version. The grid will not use this node for tests that request a specific browser version.
- If you specify browser versions and want the default version to be used for testing as well, specifically list that version as one of the available ones.
- If a tests requests a specific browser type and does not specify a version, the grid uses either nodes with Default browser version selected, or nodes where you specified browser versions. In this case, any of the available browsers may be used by the test.
You have three nodes, configured as follows:
Node Browser Type Browser Version A
The grid handles the following test runs:
Test's browser specification Node used by grid Firefox (no version specified)
B or C, depending on availability
Chrome version 66.0.3 B Chrome version 67.0.3
There grid finds no relevant node, even if the default Chrome version on node A is 67.0.3.
In this situation, you would need to specifically define Chrome 67.0.3 as an available browser version on node A.
Internet Explorer (no version specified) C Internet Explorer 11 There grid finds no relevant node, even if the default version is 11.
In this situation, you would have to define the browser version as a custom capability. For details, see Custom Capabilities.Runtime Settings
Object synchronization timeout. Default = 20 seconds.
This setting controls the maximum time (in seconds) that the runtime engine waits for an object to load before trying to run a step on it. When debugging tests, you may want to shorten this timeout.
Allow LeanFT to run tests on a disconnected RDP computer.
Select this check box if you are working with LeanFT on a remote desktop client and the RDP connection is disconnected. The LeanFT runtime engine supplies the credentials required to keep the remote machine active.
Enter your credentials and click Verify. The password you enter is stored in an encrypted format that is relevant only on the current computer.Grid Connection Settings
Node name. Provide a unique name for the grid to use for this node. By default, LeanFT suggests a name based on the machine's computer name. Modify this name if it is not unique among all nodes that connect to the same grid.
Note: In a test run's environment description, you can list the node's name as a capability to select a specific node. Use name as the capability name and the configured node name as the value.
Grid address. Enter the data needed for the node to connect to the LeanFT grid machine.
Use the following format:
ws, depending on the grid's Connection mode.
wssfor remote secured,
wsfor remote unsecured.
server-address. The address of the grid machine.
port number. The Engine port number defined by the grid (default=5095).
Passphrase. The grid's Passphrase (case-sensitive).
To obtain the information required for the settings in this section, see the Node Connection Settings in the grid's runtime engine settings. For details, see Configure the grid's runtime engine settings.
Click Verify to test the connection. The Passphrase you enter is stored in an encrypted format that is relevant only on the current computer.
Maximum locks. (Default = 4)
The maximum number of simultaneous times the grid can choose this node for running a test. For details, see Locking node machines .Custom Capabilities
Create a list describing the additional test environment capabilities this node provides. For each capability, provide a name and value (not case-sensitive).
Do not specify the operating system type or version, which are detected automatically, or the web browser versions, which you specified in the Add-ins section.
Modify the Object Identification settings as needed.
When you save your changes, the LeanFT runtime engine automatically closes and restarts with your new settings loaded.