Remote Desktop Protocol (RDP) is a proprietary protocol
developed by Microsoft. RDP servers are built into Windows operating
systems. This technology is in MS Windows also known as Terminal
Services and the server is also called Terminal Server.
There are RDP server implementations also for Unix and OS X. Testing
over the RDP protocol was introduced by T-Plan Robot Enterprise
- The host running Robot must be MS Windows Vista or
newer. Future releases will also deliver support of OS X.
- The server (the System Under Test, SUT) may be any OS running
an RDP server
RDP on Windows
MS Windows supports the RDP connection as follows:
- Windows Professional and Ultimate editions
support RDP out of the box. The server is off by default and
must be enabled.
The Network Level Authentication security (NLA) is
supported since Robot 4.4.4. For older versions or in case of
connection failures it must be disabled.
- Windows Home editions do not support RDP officially.
They do contain the functionality but it is hidden. It may be
enabled there using 3rd party tools such as RDPWrap.
- Windows Server systems must have the media codecs
installed or the connection crashes Robot. To fix this you must
install the Desktop Experience feature. The steps for Windows
Server 2012 R2:
- Go to Start -> Administrative Tools -> Server
- Click on Add roles and features in the Dashboard
screen. This will start the Add Roles and Features
- Select the Desktop Experience feature under
the User Interfaces and Infrastructure category
of the Features screen.
- Click Install. Restart the server when done.
RDP on other systems
On other systems you have to install and start an RDP server. Known
There are several 3rd party solutions supporting the RDP connection
for non-Windows implementations. For non-Windows environments the
RDP functionality that Robot support may vary from Windows based
For example, Oracle VirtualBox supports RDP connection
to its virtual machines (VM). Robot can connect to such a VM and
automate it, however the clipboard transfer and drive redirection
support is limited. Also some systems running in VM don't set the
correct screen size, and you may have to force the correct screen
size, through the connection parameters on the Robot side.
Robot 4.4.4 introduced support of clipboard transfer between
the local and the remote systems. It is based on synchronization of
the local and remote clipboards. If you plan having multiple RDP
connections on a single Robot machine you have to implement some
kind of lock to avoid parallel clipboard updates from two competing
- The clipboard synchronization is on by default and it doesn't
have to be activated. File transfer over the clipboard is not
- To get the clipboard content in a script retrieve the
// Save the clip contents as text to the CLIP
- To set the clipboard content populate the
// Set the clipboard content to "Hello world"
Var _SERVER_CLIPBOARD_CONTENT="Hello world!"
Robot 4.4.4 also accepts most of the FreeRDP
CLI options which allow to modify the connection parameters
and set on additional features. Examples:
- To copy/paste objects from/to the remote desktop press the
Ctrl+C/Ctrl+V keys using the Press command or use other
system/application means (context/edit menu, etc.). All
clipboard objects will be exposed to the script as text.
- Use the
+auto-reconnect option to reconnect
automatically when the connection crashes due to intermittent
- To map (redirect) a local directory to the remote machine use
This is useful to enable transfer of files between the local and
remote systems. For example, the option below will make the
remote system see the local directory of
Drive redirection is subject to the support from the remote system
and it doesn't have to work on all environments. It is recommended
to use a file path with maximum permissions.
The CLI options may be defined:
- Through the user preferences in the RDP Server
screen of the Edit→Preferences window. These
options will be applied to all connections.
- Test scripts may populate the
variable prior to establishing the RDP connection. The variable
content will be appended to the option specified in the
preferences without any efforts to eliminate the conflicting
ones. For example, the following code will apply the redirected
drive to the RDP connection:
To connect to the RDP from a test script use the Connect
command (TPR scripts) or the connect()
method (Java test scripts). The argument URL must be in form
For example, the following command/method call will connect you to
the remote desktop using the RDP connection:
TPR test scripts:
The URL may be also used together with the -c/--connect CLI
option to establish the connection on the Robot start up.
The RDP system must use the US English keyboard layout.
Other layouts are currently not supported and test scripts
employing the Type and Press command will type wrong
characters. This limitation will be addressed in a future