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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/intersection-observer/resources/helper-functions.js

Issue 1983383002: Convert IntersectionObserver tests to use testRunner.runIdleTasks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: rebase Created 4 years, 7 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: third_party/WebKit/LayoutTests/http/tests/intersection-observer/resources/helper-functions.js
diff --git a/third_party/WebKit/LayoutTests/http/tests/intersection-observer/resources/helper-functions.js b/third_party/WebKit/LayoutTests/http/tests/intersection-observer/resources/helper-functions.js
deleted file mode 100644
index 733a01dd0ba88ed341427f93a1a8760a3384ab83..0000000000000000000000000000000000000000
--- a/third_party/WebKit/LayoutTests/http/tests/intersection-observer/resources/helper-functions.js
+++ /dev/null
@@ -1,33 +0,0 @@
-function clientRectToJson(rect) {
- if (!rect)
- return null;
- return {
- top: rect.top,
- right: rect.right,
- bottom: rect.bottom,
- left: rect.left,
- width: rect.width,
- height: rect.height
- };
-}
-
-function coordinatesToClientRectJson(top, right, bottom, left) {
- return {
- top: top,
- right: right,
- bottom: bottom,
- left: left,
- width: right - left,
- height: bottom - top
- };
-}
-
-function entryToJson(entry) {
- return {
- boundingClientRect: clientRectToJson(entry.boundingClientRect),
- intersectionRect: clientRectToJson(entry.intersectionRect),
- rootBounds: clientRectToJson(entry.rootBounds),
- time: entry.time,
- target: entry.target.id
- };
-}

Powered by Google App Engine
This is Rietveld 408576698