Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(111)

Unified Diff: LayoutTests/http/tests/websocket/resources/mac-dropped-wakeup-workaround.js

Issue 913273004: [OBSOLETE] De-flake the websocket/close.html layout test (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Hack around Mac timeouts. Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/http/tests/websocket/resources/mac-dropped-wakeup-workaround.js
diff --git a/LayoutTests/http/tests/websocket/resources/mac-dropped-wakeup-workaround.js b/LayoutTests/http/tests/websocket/resources/mac-dropped-wakeup-workaround.js
new file mode 100644
index 0000000000000000000000000000000000000000..8eb20e24a543f25c294012cc9a9e2766eac1202d
--- /dev/null
+++ b/LayoutTests/http/tests/websocket/resources/mac-dropped-wakeup-workaround.js
@@ -0,0 +1,12 @@
+if (navigator.userAgent.search(/Macintosh.*Chrome/) != -1) {
+ (function() {
+ var ws = new WebSocket("ws://127.0.0.1:8880/echo");
+ var timer;
+ ws.onopen = function() {
+ timer = setInterval(sendMessage, 20);
+ };
+ function sendMessage() {
+ ws.send("");
+ };
+ })();
+}
« no previous file with comments | « LayoutTests/http/tests/websocket/resources/close-common.js ('k') | LayoutTests/http/tests/websocket/workers/close.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698