Layout Test webrtc/addICECandidate-closed.html is a flaky failure
authoryouenn@apple.com <youenn@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 11 May 2018 17:29:42 +0000 (17:29 +0000)
committeryouenn@apple.com <youenn@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 11 May 2018 17:29:42 +0000 (17:29 +0000)
https://bugs.webkit.org/show_bug.cgi?id=185384
<rdar://problem/40035167>

Reviewed by Eric Carlson.

* webrtc/addICECandidate-closed.html: Move more pc calls inside the try/catch.
This ensures that the test will be consistent as the pc might be closed sooner for some runs.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@231706 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/webrtc/addICECandidate-closed.html

index 2fc3609..50aaf21 100644 (file)
@@ -1,3 +1,14 @@
+2018-05-11  Youenn Fablet  <youenn@apple.com>
+
+        Layout Test webrtc/addICECandidate-closed.html is a flaky failure
+        https://bugs.webkit.org/show_bug.cgi?id=185384
+        <rdar://problem/40035167>
+
+        Reviewed by Eric Carlson.
+
+        * webrtc/addICECandidate-closed.html: Move more pc calls inside the try/catch.
+        This ensures that the test will be consistent as the pc might be closed sooner for some runs.
+
 2018-05-11  Claudio Saavedra  <csaavedra@igalia.com>
 
         [GTK][a11y] Newly added accessibility/scroll-to-make-visible-iframe-offscreen.html fails
index d4bfc77..39eef03 100644 (file)
@@ -25,15 +25,15 @@ promise_test(async (test) => {
         localTracks.forEach(track => sender.addTrack(track, stream));
         receiver.addTransceiver('audio');
         receiver.addTransceiver('video');
-        const offer1 = await sender.createOffer();
-        await sender.setLocalDescription(offer1);
-        await receiver.setRemoteDescription(offer1);
-        const answer1 = await receiver.createAnswer();
-        await receiver.setLocalDescription(answer1);
         await new Promise (async (resolve) => {
             // RTCPeerConnection does not resolve promises when it gets closed, hence the timeout here to make sure we execute some if not all these operations.
             test.step_timeout(resolve, 100);
             try {
+                const offer1 = await sender.createOffer();
+                await sender.setLocalDescription(offer1);
+                await receiver.setRemoteDescription(offer1);
+                const answer1 = await receiver.createAnswer();
+                await receiver.setLocalDescription(answer1);
                 await sender.setRemoteDescription(answer1);
                 const offer2 = await sender.createOffer();
                 await sender.setLocalDescription(offer2);