=== Usage ===

./conformance.sh [-d] [-a] [-t tag] suites...

"-d" turns on debug mode. The script normally continues until everything is done. But in debug mode, it will stop whenever a test returns FAIL/UNKNOWN.

"-t" prepends the result directory with a tag. The results will be put in <tag>-<date>.

"-a" runs the script in automatic mode. That is, it won't ask the user any questions if a lock is encountered on the remote CSN server. It will wait for an hour and stop if it can't obtain the lock then.

The remaining parameter will be treated as tests/directories to execute. For example,

./conformance.sh tests/regression tests/simring/SIMRING05.txt

will execute everything in regression and SIMRING05.txt. Specifying "all" will run everything under the tests directory.



=== Script Migration ===

Every test case will require a corresponding txt file in tests directory. The txt file will contain which UAS and UAC to execute. If a line begins with "#SIPp" it will treat it as SIPp parameters. Otherwise execute the line as shell script. For example, if test.txt contains

>>>>>>
#SIPp uas_SIPFUNC01.xml mydata.csv
#SIPp uas_SIPFUNC02.xml mydata.csv 5081
echo sleeping for 12 seconds
sleep 12
#SIPp uac_SIPFUNC01.xml mydata.csv

<<<<<<

Runs uas_SIPFUNC01.xml on default port 5080, then uas_SIPFUNC02.xml on port 5081. Echo a message then sleep for 12 seconds. Finally runs uac_SIPFUNC01.xml. NOTE due to a script deficiency, a blank line at the end of the file is required.

The special line is as follows:

#SIPp_[options] (uac|uas)_<testCase>.xml callInfo.csv [port]

The port has different meanings depending on whether it's UAS or UAC. For UAS, specifying a port will tell SIPp to listen on that port. Otherwise it listens on the default port (configurable in script). For UAC, specifying a port tells SIPp to send SIP messages to that port. Putting "orig" will send the message to the origination port. If missing, it will send the message to the default termination port.

[options] trigger different parameters for the SIPp instance. You can select from any of the following options:

1) 3pcc - The SIPp script will execute in 3rd party call-control mode with the same parameters supplied as a normal SIPp script. Please make sure you always start the receiver script first (the XML script that contains <recvCmd>) before starting the sender script.

2) 11 - By default, the sipp version is 1.0, using this option will enable version 1.1 scripts.

3) ip2 - This only applies to UAC and changes the remote IP to the secondary IP address in the configuration.

The above options can be combined in any way, as long as the option keywords are delimited by the underscore '_' character. For exmaple, #SIPp_11_ip2 uses version 1.1 and the secondary IP address for remote IP.

=== Directory Structure ===
conformance.sh - this file

configuration.txt - contains configuration parameters for the test run

csv - contains all csv files here; no change from before; it will be up to the user to change all IP addresses and port numbers when we move from one CSN to another

xml - contains all xml files here; no change from before

proxy - contains JAIN-SIP proxy for test purposes

tests - contains the test cases .txt files; each subdirectory is a test suite and the test cases are executed in alphabetical order

results - contains the list of all test runs 
 \-> the subdirectories will be of each test run, with the tag included as part of the directory name if included
   \-> summary.txt - contains the summary of all test results
   \-> each subdirectory contains subdirectories of each test suite 
     \-> summary.txt - contains the summary of test results in this test suite
     \-> each subdirectory contains the log files of each test case

=== How to use the proxy ===

To use the proxy for your test suite, all you need to do is to create 2 test cases, one for initialization and the other for cleaning up:

AASTARTUP.txt - this script gets executed before the test cases and it will start the proxy
zzSHUTDOWN.txt - this script gets executed at the end of the test cases and it will stop the proxy

Please see tests/BELL for an example. Just copy them into your test suite directory is you need it.
