412_fmtp_amrnb_offer_band_eff2.py 741 B

12345678910111213141516171819202122232425262728293031
  1. import inc_sip as sip
  2. import inc_sdp as sdp
  3. # Answer for codec AMR should not contain fmtp octet-align=1
  4. sdp = \
  5. """
  6. v=0
  7. o=- 3428650655 3428650655 IN IP4 192.168.1.9
  8. s=pjmedia
  9. c=IN IP4 192.168.1.9
  10. t=0 0
  11. a=X-nat:0
  12. m=audio 4000 RTP/AVP 99 101
  13. a=rtcp:4001 IN IP4 192.168.1.9
  14. a=rtpmap:99 AMR/8000
  15. a=fmtp:99 octet-align=0
  16. a=sendrecv
  17. a=rtpmap:101 telephone-event/8000
  18. a=fmtp:101 0-15
  19. """
  20. pjsua_args = "--null-audio --auto-answer 200 --add-codec AMR"
  21. extra_headers = ""
  22. include = [""]
  23. exclude = ["octet-align=1"] # response must not include fmtp 'octet-align=1'
  24. sendto_cfg = sip.SendtoCfg("AMR negotiation should not contain 'octet-align=1'", pjsua_args, sdp, 200,
  25. extra_headers=extra_headers,
  26. resp_inc=include, resp_exc=exclude)