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

Unified Diff: third_party/WebKit/LayoutTests/fast/dom/TreeWalker/resources/TreeWalker-currentNode.js

Issue 1481983002: Drop [LegacyInterfaceTypeChecking] where trivial in core/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more tests Created 5 years, 1 month 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/fast/dom/TreeWalker/resources/TreeWalker-currentNode.js
diff --git a/third_party/WebKit/LayoutTests/fast/dom/TreeWalker/resources/TreeWalker-currentNode.js b/third_party/WebKit/LayoutTests/fast/dom/TreeWalker/resources/TreeWalker-currentNode.js
index 2fe0fa679ce2036fc1d23a7b4d0feeee67de2417..d87ec7b52ec57cc2bc35beea7013580ad2adf930 100644
--- a/third_party/WebKit/LayoutTests/fast/dom/TreeWalker/resources/TreeWalker-currentNode.js
+++ b/third_party/WebKit/LayoutTests/fast/dom/TreeWalker/resources/TreeWalker-currentNode.js
@@ -15,6 +15,14 @@ shouldBeNull("w.parentNode()");
shouldBe("w.currentNode", "subTree");
debug("");
+debug("Test that setting the currentNode to non-Node values throws.");
+debug("");
+
+shouldThrow("w.currentNode = null");
+shouldThrow("w.currentNode = {}");
+shouldThrow("w.currentNode = window");
+
+debug("");
debug("Test that we handle setting the currentNode to arbitrary nodes not under the root element.");
debug("");

Powered by Google App Engine
This is Rietveld 408576698