Open
Bug 1045429
Opened 10 years ago
Updated 2 years ago
For test verification we should have a simple JS SDP parser
Categories
(Core :: WebRTC, defect, P5)
Core
WebRTC
Tracking
()
NEW
backlog | webrtc/webaudio+ |
People
(Reporter: drno, Unassigned)
Details
(Whiteboard: [webrtc-mochitest])
To be able to do simple sanity checks (better then just simple string search) we should have a simple SDP parser is JavaScript which allows to inspect the SDP.
Reporter | ||
Comment 1•10 years ago
|
||
This is a candidate to look at: https://github.com/otalk/sdp-jingle-json
Comment 2•10 years ago
|
||
Are abstraction layers of this kind a good idea in a testing framework? Do we have other code that needs this to be in jingle? If not, then translating A to B to me means more code that can go wrong, plus having to learn both A and B ("Law of leaky abstractions"). To test that the SDP is accurate, I think we should test that the SDP is accurate. Why not regular expressions?
Reporter | ||
Comment 3•10 years ago
|
||
BTW this is not meant as choosing sdp-jingle-json. Just one possible alternative. I'm not against regex's, but http://stackoverflow.com/questions/764247/why-are-regular-expressions-so-controversial To verify things like: does the first video m line have recvonly, and the second sendrecv is certainly doable in regex, but will be really hard to read/maintain. Or are you thinking of writing a whole bunch of functions to with regex in them to extract and verify given criteria?
Comment 4•10 years ago
|
||
(In reply to Nils Ohlmeier [:drno] from comment #3) > To verify things like: does the first video m line have recvonly, and the > second sendrecv is certainly doable in regex, but will be really hard to > read/maintain. Here's a fiddle for that fwiw: http://jsfiddle.net/jib1/xv3eL7oa Are we validating the SDP as a whole anywhere else? If not, would this jingle library validate the SDP for us in the process of using it? If so then I can see some value in it.
Reporter | ||
Updated•9 years ago
|
Whiteboard: [webrtc-mochitest]
Updated•9 years ago
|
backlog: --- → webRTC+
Rank: 45
Priority: -- → P4
Comment 5•7 years ago
|
||
Mass change P4->P5 to align with new Mozilla triage process.
Priority: P4 → P5
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•