Test-case generation procedure
From LDTP
Automatic generation of test cases.
Following are the steps to automatically generate a test case.
1. Update the system with the latest build of the source code.
2. The test cases for some of the components are available at the following location: http://cvs.gnome.org/viewcvs/gnome-test-specs/
3. To export the gnome-test-specs type the command in the terminal export CVSROOT=:pserver:anonymous@anoncvs.gnome.org:/cvs/gnome and press enter key.
4. In the location http://cvs.gnome.org/viewcvs/gnome-test-specs/ there are a number of files ( for example, accessibility/, components/ etc). Select the file you want to download. In the next window there are some more files. Select the application of your choice.
5. Type the following command in the terminal cvs co gnome-test-specs/”file”/”application” and press the enter key. For example if you select file as “components” and select the application as “gedit” type the following command: cvs co gnome-test-specs/components/gedit
6. It took close to about 10 minutes to download all the files on a line which has a downloading speed of 20kbps. So if you are downloading on a slower speed line, it may take some time.
7. Change to the LDTP directory (“cd ldtp”).
8. Change to record directory (“cd record”).
9. Once you are in record directory type the command “make clean; make” and press the enter key.
10. You are now ready to generate the test cases automatically.
11. To generate the test case automatically for any application (for
example: gedit), the application (gedit) must be running (gedit
opened).
12. Type the following command
./record > dump.txt
and press the enter key.
13. dump.txt is an error logging file. Errors, if any, are recorded in
dump.txt.
14. ./record will be running.
15. The first test case in the loaction (for gedit) can be followed to
generate the test case ( Once again Gedit should be running before
./record >dump.txt).
16. Follow the steps in the test case and after finishing with all the
steps, stop the ./record which is still running by pressing “ctrl-c”.
17. The test case is recorded in test.SDD. The records for the test
conducted can be viewed by typing:
vi test.SDD
18. To continue with testing for the second test case, the first test
case (test.SDD) must be moved to another file( this is because the
next time you generate the automated test case, it will be stored
in test.SDD and the previous results will be overwritten).
19. To rename the file, type
mv test.SDD “filename”
Example for this is “mv test.SDD testone.SDD”
20. The second test case can be created in the same manner by following
the steps from step number 8.

