| 135 | | * Client and Server should be setup on a separate machine. |
| 136 | | |
| 137 | | * The Client runs Static and Dynamic Tests. The Static tests involve rendering the homepage of Eden. |
| 138 | | |
| 139 | | * The Dynamic Tests will have users follow the sequence - |
| 140 | | 1. Log into the system |
| 141 | | 2. Create an organisation |
| 142 | | 3. Create a staff member in the above organisation |
| 143 | | 4. Update the staff record. |
| 144 | | 5. Logout |
| | 135 | * Client and Server should ideally be setup on separate machines. |
| | 136 | |
| | 137 | ===== Design of the Test Suite ===== |
| | 138 | |
| | 139 | * The tests are located in {{{modules/tests/load}}} |
| | 140 | * There are group of requests which will be common to many tests. Eg - login requests will be common to all tests which require login. |
| | 141 | * Such requests are stored in {{{modules/tests/load/helpers}}} |
| | 142 | * These helpers can be included in the tests for maximum code reuse. |
| | 143 | * Using the helpers, different range of tests can be written, as per the usecase. |
| | 144 | * Eg - A test has - |
| | 145 | * 20% users creating staff |
| | 146 | * 40% users searching for staff |
| | 147 | * 40% users visiting the homepage |
| | 148 | * This can be written by defining 3 sessions, with probabilities 20%, 40% and 40%. |
| | 149 | * The content(requests) in these individual sessions can be imported from the helper xml files. |
| | 150 | * See {{{modules/tests/load/search_staff.xml}}} for an example of one such session. |
| | 151 | |
| | 152 | ===== Running the tests ===== |
| | 153 | * Setup your machine - [http://eden.sahanafoundation.org/wiki/DeveloperGuidelines/Testing/Load/Setup Load/Setup] |
| | 154 | * Change the path of tsung-1.0.dtd in the DOCTYPE if you have changed the the tsung installation directory to {{{<tsung_directory>/share/tsung/tsung-1.0.dtd}}} |
| | 155 | * Run tsung -f <path_to_test_file> start |
| | 156 | * To generate the report, go to the log directory and run - {{{/opt/tsung-1.4.2/lib/tsung/bin/tsung_stats.pl}}} |
| | 157 | * Note : Installation directory for tsung is opt/tsung-1.4.2 as per the Setup instructions on wiki. If you have changed that, then run {{{<tsung_directory>/lib/tsung/bin/tsung_stats.pl}}} to generate the report. |
| | 158 | |