diff options
author | Nanang Izzuddin <nanang@teluu.com> | 2010-06-03 03:06:03 +0000 |
---|---|---|
committer | Nanang Izzuddin <nanang@teluu.com> | 2010-06-03 03:06:03 +0000 |
commit | f5a2d53060169500258cdc3bdebd76fe1481ebaf (patch) | |
tree | d677a997aaa038b3f6583338582f560d283eb94f /tests/pjsua | |
parent | d80a5b1cbe89a082e1ba88795257c9a83cc4e159 (diff) |
Fix #1073:
- Fixed SDP negotiation in processing answer: when the answer has less media count, generate disabled-media to match the media count.
- Added python test.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@3195 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'tests/pjsua')
-rw-r--r-- | tests/pjsua/scripts-recvfrom/400_inv_answered_with_less_media.py | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/tests/pjsua/scripts-recvfrom/400_inv_answered_with_less_media.py b/tests/pjsua/scripts-recvfrom/400_inv_answered_with_less_media.py new file mode 100644 index 00000000..61b32fc6 --- /dev/null +++ b/tests/pjsua/scripts-recvfrom/400_inv_answered_with_less_media.py @@ -0,0 +1,32 @@ +# $Id$ +import inc_sip as sip +import inc_sdp as sdp + +# Offer with 2 media lines answered with only 1 media line + +pjsua = "--null-audio sip:127.0.0.1:$PORT --use-srtp=3 --srtp-secure=0" + +sdp = \ +""" +v=0 +o=- 0 0 IN IP4 127.0.0.1 +s=pjmedia +c=IN IP4 127.0.0.1 +t=0 0 +m=audio 4000 RTP/AVP 0 101 +a=rtpmap:0 PCMU/8000 +a=sendrecv +a=rtpmap:101 telephone-event/8000 +a=fmtp:101 0-15 +""" + +req = sip.RecvfromTransaction("Receiving 2 media lines, answer with 1 media line", 200, + include=["m=audio \d+ RTP/SAVP", "m=audio \d+ RTP/AVP"], + exclude=[], + resp_hdr=["Content-type: application/sdp"], + resp_body=sdp, + ) + +recvfrom_cfg = sip.RecvfromCfg("Receiving answer with less media lines", + pjsua, [req]) + |