~noskcaj/ubuntu/saucy/sflphone/merge-1.2.3-2

« back to all changes in this revision

Viewing changes to daemon/libs/pjproject/tests/pjsua/scripts-sendto/125_sdp_with_multi_audio_0.py

  • Committer: Jackson Doak
  • Date: 2013-07-10 21:04:46 UTC
  • mfrom: (20.1.3 sid)
  • Revision ID: noskcaj@ubuntu.com-20130710210446-y8f587vza807icr9
Properly merged from upstream.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# $Id: 125_sdp_with_multi_audio_0.py 2081 2008-06-27 21:59:15Z bennylp $
2
 
import inc_sip as sip
3
 
import inc_sdp as sdp
4
 
 
5
 
# Multiple good m=audio lines! The current algorithm in pjsua-lib will
6
 
# select the last audio (which should be okay, as we're entitled to
7
 
# select any of them)
8
 
sdp = \
9
 
"""
10
 
v=0
11
 
o=- 0 0 IN IP4 127.0.0.1
12
 
s=-
13
 
c=IN IP4 127.0.0.1
14
 
t=0 0
15
 
m=audio 5000 RTP/AVP 0
16
 
m=audio 4000 RTP/AVP 0
17
 
m=audio 3000 RTP/AVP 0
18
 
"""
19
 
 
20
 
pjsua_args = "--null-audio --auto-answer 200"
21
 
extra_headers = ""
22
 
include = ["Content-Type: application/sdp",     # response must include SDP
23
 
           "m=audio 0 RTP/AVP[\\s\\S]+m=audio 0 RTP/AVP[\\s\\S]+m=audio [1-9]+[0-9]* RTP/AVP"
24
 
           ]
25
 
exclude = []
26
 
 
27
 
sendto_cfg = sip.SendtoCfg("Mutiple good m=audio lines", pjsua_args, sdp, 200,
28
 
                           extra_headers=extra_headers,
29
 
                           resp_inc=include, resp_exc=exclude) 
30