Benny Prijono | 4b4adb3 | 2008-06-12 15:37:22 +0000 | [diff] [blame] | 1 |
|
| 2 | PJSUA TEST FRAMEWORK
|
| 3 | =========================
|
| 4 |
|
| 5 | 0. What is this
|
| 6 | ---------------
|
Benny Prijono | 7d578a7 | 2008-06-20 00:25:55 +0000 | [diff] [blame] | 7 | This is the automated testing scripts for pjsua. It can do many things (just don't ask
|
| 8 | it to write good documentation :) ).
|
Benny Prijono | 4b4adb3 | 2008-06-12 15:37:22 +0000 | [diff] [blame] | 9 |
|
| 10 |
|
| 11 | 1. Requirements
|
| 12 | ---------------
|
| 13 | To run the tests you need:
|
| 14 | - Python (tested with Python 2.5.2)
|
| 15 | - pjsua application, built and placed in pjsip-apps/bin directory
|
| 16 | - the pjsua must be built with:
|
Benny Prijono | 7d578a7 | 2008-06-20 00:25:55 +0000 | [diff] [blame] | 17 | - SRTP enabled (the default)
|
Benny Prijono | 4b4adb3 | 2008-06-12 15:37:22 +0000 | [diff] [blame] | 18 |
|
| 19 |
|
| 20 | 2. Using
|
| 21 | --------
|
| 22 | To run all the tests:
|
| 23 | $ python runall.py
|
| 24 |
|
| 25 | To run individual test:
|
| 26 | $ python run.py MODULE CONFIG
|
| 27 |
|
Benny Prijono | 7d578a7 | 2008-06-20 00:25:55 +0000 | [diff] [blame] | 28 | The run.py is the main entry for the test. It imports the various inc_xxx.py files, and
|
| 29 | it will load the MODULE. The MODULE contains specific test flows, and we have few of
|
| 30 | them:
|
| 31 |
|
| 32 | - mod_run.py:
|
| 33 | a simple test which just run pjsua with the configuration from CONFIG file
|
| 34 | and checks if pjsua can start properly.
|
| 35 |
|
| 36 | - mod_call.py:
|
| 37 | call testing where it spawns two pjsua instances each with configurations as
|
| 38 | specified in CONFIG file, makes one pjsua call the other, and checks if the call
|
| 39 | can be established.
|
| 40 |
|
| 41 | - mod_pres.py:
|
| 42 | presence testing
|
| 43 |
|
| 44 | - mod_sendto.py:
|
| 45 | Simple UAC to send arbitrary SIP message
|
| 46 |
|
| 47 | - mod_media_playrec.py:
|
| 48 | Media testing
|
Benny Prijono | 4b4adb3 | 2008-06-12 15:37:22 +0000 | [diff] [blame] | 49 |
|
| 50 | Example:
|
| 51 | $ python run.py mod_run.py scripts-run/100_simple.py
|
| 52 | $ python run.py mod_call.py scripts-call/100_simple.py
|
Benny Prijono | 7d578a7 | 2008-06-20 00:25:55 +0000 | [diff] [blame] | 53 |
|
| 54 |
|