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

Unified Diff: third_party/WebKit/LayoutTests/intersection-observer/observer-exceptions.html

Issue 2088963002: IntersectionObserver constructor: fail on invalid rootMargin syntax. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Simplify loop condition Created 4 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
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/intersection-observer/observer-exceptions-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/intersection-observer/observer-exceptions.html
diff --git a/third_party/WebKit/LayoutTests/intersection-observer/observer-exceptions.html b/third_party/WebKit/LayoutTests/intersection-observer/observer-exceptions.html
index f811158727c921bb523b0a676b5f06835c16fdef..3bb5e0a6f1b66fe6e6ce2220ac52593864b0b894 100644
--- a/third_party/WebKit/LayoutTests/intersection-observer/observer-exceptions.html
+++ b/third_party/WebKit/LayoutTests/intersection-observer/observer-exceptions.html
@@ -43,6 +43,15 @@
shouldBe("exc.code", "DOMException.SYNTAX_ERR");
}
+ try {
+ new IntersectionObserver(e => {}, {rootMargin: "1px 1px 1px 1px 1px"});
+ testFailed("IntersectionObserver constructor did not throw due to too many rootMargin value.");
+ } catch(e) {
+ exc = e;
+ shouldBeType("exc", "DOMException");
+ shouldBe("exc.code", "DOMException.SYNTAX_ERR");
+ }
+
let observer = new IntersectionObserver(c => {}, {});
try {
observer.observe("foo");
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/intersection-observer/observer-exceptions-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698