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

Unified Diff: LayoutTests/http/tests/eventsource/eventsource-retry-precision.html

Issue 347043002: Rework EventSource tests for better Worker test coverage. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Move out CORS tests Created 6 years, 6 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/eventsource/eventsource-retry-precision.html
diff --git a/LayoutTests/http/tests/eventsource/eventsource-retry-precision.html b/LayoutTests/http/tests/eventsource/eventsource-retry-precision.html
index 5872cc473ae9f95afd59c0e531aba988391e2df7..6867c405055b7eb1a63405394ddc256b2c9d2689 100644
--- a/LayoutTests/http/tests/eventsource/eventsource-retry-precision.html
+++ b/LayoutTests/http/tests/eventsource/eventsource-retry-precision.html
@@ -1,37 +1,3 @@
-<html>
-<body>
-<p>Test EventSource retry time precision. Should print PASS followed by DONE.</p>
-<script>
-function log(msg) {
- document.body.innerHTML += msg + "<br>";
-}
-
-if (window.testRunner) {
- testRunner.dumpAsText();
- testRunner.waitUntilDone();
-}
-
-var timeoutId = setTimeout(function () {
- log("PASS: did not immediately reconnect");
- end();
-}, 500);
-
-var count = 0;
-var es = new EventSource("resources/precise-retry.asis");
-es.onopen = function () {
- if (count++ != 2)
- return;
- clearTimeout(timeoutId);
- log("FAIL: reconnected too soon");
- end();
-};
-
-function end() {
- es.close();
- log("DONE");
- if (window.testRunner)
- testRunner.notifyDone();
-}
-</script>
-</body>
-</html>
+<!DOCTYPE HTML>
+<script src="/js-test-resources/js-test.js"></script>
+<script src="script-tests/eventsource-retry-precision.js"></script>

Powered by Google App Engine
This is Rietveld 408576698