## 2 Installation

### 2.1 Unix

Copy the Common Test and Test Server application directories, common_test-<vsn> and test_server-<vsn>, to a location of your choice. They do not have to be placed among the Erlang applications under the OTP lib directory, nor do they need to have a particular path relative to your test suite modules. In the Common Test directory you find the shell script install.sh. Execute this script to generate the Common Test start script run_test in the sub directory common_test-<vsn>/priv/bin.

install.sh takes one input parameter which specifies the absolute path to the top directory of Common Test and Test Server. (This path is inserted in the run_test script so that when the script starts Erlang, the Erlang code server will be able to load the Common Test and Test Server application modules). Example (assuming Common Test and Test Server have been placed in /usr/local/test_tools):

$ install.sh /usr/local/test_tools

Note that the common_test-<vsn> and test_server-<vsn> directories must be located under the same top directory for the installation to work properly. Note also that the install script does not e.g. copy files or update environment variables. It only generates the run_test script.

If the directories are later moved, make sure to run install.sh again or edit the run_test script (Bourne shell) manually.

For more information on the run_test script, please see the reference manual.

### 2.2 Windows

On Windows it is very convenient to use Cygwin (www.cygwin.com) for running Common Test and Erlang, since it enables you to use the run_test script for starting Common Test. If you are a Cygwin user, simply follow the instructions for installing Common Test on Unix above.

If you do not use Cygwin, you have to rely on the API functions in the ct module (instead of run_test) for running Common Test. In this case you do not need to install Common Test (i.e. no need to generate the run_test script). Simply copy the common_test-<vsn> and test_server-<vsn> directories to a location of your choice. They do not have to be placed among the Erlang applications under the OTP lib directory, nor do they need to have a particular path relative to your test suite modules.

When you start the Erlang node on which you will be running Common Test, make sure the Common Test and Test Server ebin directories are included in the Erlang code server path (so the application modules can be loaded). If you do copy the application directories to the OTP lib directory, there is no need to explicitly update the code server path as the code server will be able to locate the modules automatically.

common_test 1.3.1
Copyright © 1991-2008 Ericsson AB