|
| 1 | +<?xml version="1.0" encoding="ISO-8859-1" ?> |
| 2 | + |
| 3 | +<scenario name="Send Call"> |
| 4 | + |
| 5 | + <send retrans="500"> |
| 6 | + <![CDATA[ |
| 7 | +
|
| 8 | + INVITE sip:[service]@[remote_ip]:[remote_port] SIP/2.0 |
| 9 | + Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch] |
| 10 | + From: <sip:alice@[local_ip]:[local_port]>;tag=[pid]SIPpTag[call_number] |
| 11 | + To: <sip:[service]@[remote_ip]:[remote_port]> |
| 12 | + Call-ID: [call_id] |
| 13 | + CSeq: [cseq] INVITE |
| 14 | + Contact: <sip:alice@[local_ip]:[local_port];transport=[transport]> |
| 15 | + Max-Forwards: 70 |
| 16 | + Content-Type: application/sdp |
| 17 | + Content-Length: [len] |
| 18 | +
|
| 19 | + v=0 |
| 20 | + o=- 53655765 2353687637 IN IP[local_ip_type] [local_ip] |
| 21 | + s=- |
| 22 | + c=IN IP[media_ip_type] [media_ip] |
| 23 | + t=0 0 |
| 24 | + m=audio [custom_media_port] RTP/AVP 107 9 8 0 |
| 25 | + a=rtpmap:107 opus/48000/2 |
| 26 | + a=fmtp:107 maxaveragebitrate=64000;sprop-stereo=1 |
| 27 | + a=rtpmap:9 G722/8000 |
| 28 | + a=rtpmap:8 PCMA/8000 |
| 29 | + a=rtpmap:0 PCMU/8000 |
| 30 | + a=ptime:20 |
| 31 | + a=maxptime:20 |
| 32 | + a=sendrecv |
| 33 | + a=rtcp-mux |
| 34 | + ]]> |
| 35 | + </send> |
| 36 | + |
| 37 | + <recv response="100" optional="true" /> |
| 38 | + <recv response="180" /> |
| 39 | + |
| 40 | + <recv response="200" rtd="true"> |
| 41 | + <!-- Save the To tag. --> |
| 42 | + <action> |
| 43 | + <ereg regexp="(;tag=.*)" |
| 44 | + header="To:" |
| 45 | + search_in="hdr" |
| 46 | + check_it="true" |
| 47 | + assign_to="remote_tag"/> |
| 48 | + <ereg regexp="m=audio [0-9]{1,5} RTP/AVP 9 8 0" |
| 49 | + search_in="body" check_it="true" assign_to="1"/> |
| 50 | + <test assign_to="1" variable="1" compare="equal" value=""/> |
| 51 | + <ereg regexp="G722" |
| 52 | + search_in="body" check_it_inverse="false" assign_to="2"/> |
| 53 | + <test assign_to="2" variable="2" compare="equal" value=""/> |
| 54 | + <ereg regexp="PCMA" |
| 55 | + search_in="body" check_it_inverse="false" assign_to="3"/> |
| 56 | + <test assign_to="3" variable="3" compare="equal" value=""/> |
| 57 | + <ereg regexp="OPUS" |
| 58 | + search_in="body" check_it_inverse="true" assign_to="4"/> |
| 59 | + <test assign_to="4" variable="4" compare="equal" value=""/> |
| 60 | + </action> |
| 61 | + </recv> |
| 62 | + |
| 63 | + <send> |
| 64 | + <![CDATA[ |
| 65 | +
|
| 66 | + ACK sip:[service]@[remote_ip]:[remote_port] SIP/2.0 |
| 67 | + [last_Via:] |
| 68 | + [last_From:] |
| 69 | + [last_To:] |
| 70 | + Call-ID: [call_id] |
| 71 | + CSeq: [cseq] ACK |
| 72 | + Contact: <sip:alice@[local_ip]:[local_port];transport=[transport]> |
| 73 | + Max-Forwards: 70 |
| 74 | + Content-Length: 0 |
| 75 | +
|
| 76 | + ]]> |
| 77 | + </send> |
| 78 | + |
| 79 | + <pause milliseconds="1000" /> |
| 80 | + |
| 81 | + <send retrans="500"> |
| 82 | + <![CDATA[ |
| 83 | +
|
| 84 | + BYE sip:[service]@[remote_ip]:[remote_port] SIP/2.0 |
| 85 | + [last_Via:]4 |
| 86 | + From: <sip:alice@[local_ip]:[local_port]>;tag=[pid]SIPpTag[call_number] |
| 87 | + To: <sip:[service]@[remote_ip]:[remote_port]>[$remote_tag] |
| 88 | + Call-ID: [call_id] |
| 89 | + CSeq: [cseq] BYE |
| 90 | + Contact: sip:alice@[local_ip]:[local_port] |
| 91 | + Max-Forwards: 70 |
| 92 | + Subject: Codec Negotiation Test |
| 93 | + Content-Length: 0 |
| 94 | +
|
| 95 | + ]]> |
| 96 | + </send> |
| 97 | + |
| 98 | + <recv response="200" crlf="true"> |
| 99 | + </recv> |
| 100 | + |
| 101 | +</scenario> |
0 commit comments