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

Unified Diff: tests/dom/typing_test.dart

Issue 10222026: Migrate dom tests to dart:html. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebase & address comments. Created 8 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
Index: tests/dom/typing_test.dart
diff --git a/tests/dom/typing_test.dart b/tests/dom/typing_test.dart
index ed8f8f683963f09ffa8038b74341b1b54058948f..e955e90354ecb5294228c1dd8e11c2f6c51471af 100644
--- a/tests/dom/typing_test.dart
+++ b/tests/dom/typing_test.dart
@@ -1,21 +1,21 @@
#library('TypingTest');
#import('../../lib/unittest/unittest.dart');
-#import('../../lib/unittest/dom_config.dart');
-#import('dart:dom');
+#import('../../lib/unittest/html_config.dart');
+#import('dart:html');
main() {
- useDomConfiguration();
+ useHtmlConfiguration();
test('NodeList', () {
- List<Node> asList = window.document.getElementsByTagName('body');
+ List<Node> asList = window.document.queryAll('body');
// Check it's Iterable
int counter = 0;
- for (Node node in window.document.getElementsByTagName('body')) {
+ for (Node node in window.document.queryAll('body')) {
counter++;
}
Expect.equals(1, counter);
counter = 0;
- window.document.getElementsByTagName('body').forEach((e) { counter++; });
+ window.document.queryAll('body').forEach((e) { counter++; });
Expect.equals(1, counter);
});

Powered by Google App Engine
This is Rietveld 408576698