• Henrik Boström's avatar
    WPT tests for setRemoteDescription for adding and removing tracks. · 7224091b
    Henrik Boström authored
    These are behavior-driven tests, each test testing a specific behavior:
    - addTrack() with a track and no stream should fire ontrack with a
      remote track with the same ID and no streams.
    - addTrack() with a track and a stream should fire ontrack with a
      remote track and stream with matching IDs.
    - addTrack() with two tracks and a shared stream should fire ontrack
      twice with remote tracks and a shared remote stream, with matching
      IDs.
    - addTrack() with a track and two streams should fire ontrack with a
      track and two streams with matching IDs.
    - ontrack should fire before setRemoteDescription()'s promise resolves.
    - ontrack's receiver should match getReceivers().
    - removeTrack() should not result in a receiver being removed.
    
    Unlike RTCPeerConnection-ontrack.https.html, these tests do not rely on
    transceiver support. When testing a behavior like "fires an event with
    a track" the test does not test unrelated things like the event being a
    complete implementation of RTCTrackEvent with transceivers and all.
    
    In a follow-up, I will add tests for other behavior associated with the
    removal of a track, including onmute events firing and the track being
    removed from the remote streams.
    
    Bug: 774303
    Change-Id: I87d8a79d9e2e385610f749a9146b740cc649cf3f
    Reviewed-on: https://chromium-review.googlesource.com/719615
    Commit-Queue: Henrik Boström <hbos@chromium.org>
    Reviewed-by: default avatarTaylor Brandstetter <deadbeef@chromium.org>
    Reviewed-by: default avatarPhilip Jägenstedt <foolip@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#510241}
    7224091b
RTCPeerConnection-setRemoteDescription-tracks.https-expected.txt 989 Bytes