In LDTP you can execute the test scripts from a remote location. Say, the ldtp execution engine can run on a remote test server and you can execute the test scripts from your development box.

Steps to follow:

Start LDTP engine (manually) in remote location with the following options

$ ldtp

Default port 4118

$ ldtp -p 4118

or

$ ldtp --port=4118

from remote machine, in shell, you need to set LDTP_SERVER_ADDR with the remote server IP address or resolvable machine name (DNS entry).

export LDTP_SERVER_ADDR=xx.xx.xx.xx

If port number is changed in the ldtp server, then LDTP_SERVER_PORT environment variable has to be set

export LDTP_SERVER_PORT=12345

Now start executing the test scripts using ldtprunner or from a python prompt or from a shell.

  • $ python testscript.py
  • $ python
    • >>> from ldtp import *
    • >>> click ("*-gedit", "btnFind")