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

Unified Diff: tests/html/node_test.dart

Issue 13685021: Properly exposing NodeIterator and TreeWalker. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 8 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 | « sdk/lib/svg/dartium/svg_dartium.dart ('k') | tools/dom/scripts/htmlrenamer.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/html/node_test.dart
diff --git a/tests/html/node_test.dart b/tests/html/node_test.dart
index ad4911e250bf742aa6323cfe27db485c2a382b25..c8a009cdc3a535be01311d3d97aa03830ca7ba99 100644
--- a/tests/html/node_test.dart
+++ b/tests/html/node_test.dart
@@ -347,4 +347,20 @@ main() {
expect(range[1], isComment);
});
});
+
+ group('iterating', () {
+ test('NodeIterator', () {
+ var root = makeNodeWithChildren();
+ var nodeIterator = new NodeIterator(root, NodeFilter.SHOW_COMMENT);
+ expect(nodeIterator.nextNode(), isComment);
+ expect(nodeIterator.nextNode(), isNull);
+ });
+
+ test('TreeWalker', () {
+ var root = makeNodeWithChildren();
+ var treeWalker = new TreeWalker(root, NodeFilter.SHOW_COMMENT);
+ expect(treeWalker.nextNode(), isComment);
+ expect(treeWalker.nextNode(), isNull);
+ });
+ });
}
« no previous file with comments | « sdk/lib/svg/dartium/svg_dartium.dart ('k') | tools/dom/scripts/htmlrenamer.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698