Changes between Version 30 and Version 31 of BluePrint/Testing/TestSuite

07/25/13 21:01:47 (11 years ago)



  • BluePrint/Testing/TestSuite

    v30 v31  
    133133* The load tests will test the amount of load Eden can take under normal and peak conditions. So, the load tests should be divided into phases, with each phase incrementally increasing the number of users and requests. Features of Tsung can be used to do this effectively.
    135 * Client and Server should be setup on a separate machine.
    137 * The Client runs Static and Dynamic Tests. The Static tests involve rendering the homepage of Eden.
    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.
     137===== Design of the Test Suite =====
     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.
     152===== Running the tests =====
     153* Setup your machine - [ 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/}}}
     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/}}} to generate the report.