mediastream.ended seems to be now readonly, so using stop() method on track to trigger onended event (although spec currently says it shouldn't, spec isn't very clear on this in the first place http://dev.w3.org/2011/webrtc/editor/getusermedia.html#dfn-finished )
--- a/submitted/W3C/stream-ended.html Thu May 30 15:57:20 2013 +0200
+++ b/submitted/W3C/stream-ended.html Thu May 30 16:06:16 2013 +0200
@@ -26,6 +26,8 @@
t.done();
}), false);
stream.ended = true;
+ assert_true(!stream.ended, "stream.ended should remain false");
+ stream.getVideoTracks()[0].stop();
}), function (error) {});
});
</script>