Bug 1437672 - Wait for the promise to resolve in order to declare test complete. r?pehrsons
MozReview-Commit-ID: 8CidLiehCag
--- a/dom/media/tests/crashtests/799419.html
+++ b/dom/media/tests/crashtests/799419.html
@@ -11,22 +11,22 @@ https://bugzilla.mozilla.org/show_bug.cg
document.documentElement.removeAttribute("class");
}
function boom() {
var v0 = new RTCPeerConnection();
var v1 = new RTCPeerConnection();
var v2 = document.getElementById("pc1video");
var v3 = document.getElementById("pc2video");
- navigator.mozGetUserMedia({video:true, fake: true},
- function(stream) {}, function() {});
+
+ navigator.mediaDevices.getUserMedia({video: true, fake: true})
+ .then((s) => {finish()});
+
v0.close();
v1.close();
-
- finish();
}
</script>
</head>
<body onload="setTimeout(boom, 100)">
<video id="pc1video" width="100" height="100" controls></video>
<video id="pc2video" width="100" height="100" controls></video>
</body>
</html>