diff options
Diffstat (limited to 'dom/media/webrtc/tests')
-rw-r--r-- | dom/media/webrtc/tests/mochitests/test_peerConnection_toJSON.html | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/dom/media/webrtc/tests/mochitests/test_peerConnection_toJSON.html b/dom/media/webrtc/tests/mochitests/test_peerConnection_toJSON.html index 96c2c42b78..1f3662d9fc 100644 --- a/dom/media/webrtc/tests/mochitests/test_peerConnection_toJSON.html +++ b/dom/media/webrtc/tests/mochitests/test_peerConnection_toJSON.html @@ -28,10 +28,11 @@ sdpMid: "test", sdpMLineIndex: 3 }); jsonCopy = JSON.parse(JSON.stringify(rtcIceCandidate)); - for (key in rtcIceCandidate) { - if (typeof(rtcIceCandidate[key]) == "function") continue; - is(rtcIceCandidate[key], jsonCopy[key], "key " + key + " should match."); - } + is(jsonCopy.candidate, "dummy"); + is(jsonCopy.sdpMid, "test"); + is(jsonCopy.sdpMLineIndex, 3); + is(jsonCopy.usernameFragment, rtcIceCandidate.usernameFragment); + is(Object.keys(jsonCopy).length, 4, "JSON limited to those four members."); }); </script> </pre> |