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

Unified Diff: tests/html/element_test.dart

Issue 12262048: Renaming Element.dataAttributes to Element.dataset. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 10 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/html/element_test.dart
diff --git a/tests/html/element_test.dart b/tests/html/element_test.dart
index d838efa73356f80a69645732711864d29fafad24..680face391c428c9fa974ac088c8f2b44ddfc8f9 100644
--- a/tests/html/element_test.dart
+++ b/tests/html/element_test.dart
@@ -298,23 +298,23 @@ main() {
expect(attributes['data-foo'], 'bar');
expect(attributes['data-foo2'], 'bar2');
expect(attributes.length, 5);
- expect(element.dataAttributes.length, 2);
- element.dataAttributes['foo'] = 'baz';
- expect(element.dataAttributes['foo'], 'baz');
+ expect(element.dataset.length, 2);
+ element.dataset['foo'] = 'baz';
+ expect(element.dataset['foo'], 'baz');
expect(attributes['data-foo'], 'baz');
attributes['data-foo2'] = 'baz2';
expect(attributes['data-foo2'], 'baz2');
- expect(element.dataAttributes['foo2'], 'baz2');
+ expect(element.dataset['foo2'], 'baz2');
expect(attributes['dir'], 'rtl');
- final dataAttributes = element.dataAttributes;
- dataAttributes.remove('foo2');
+ final dataset = element.dataset;
+ dataset.remove('foo2');
expect(attributes.length, 4);
- expect(dataAttributes.length, 1);
+ expect(dataset.length, 1);
attributes.remove('style');
expect(attributes.length, 3);
- dataAttributes['foo3'] = 'baz3';
- expect(dataAttributes.length, 2);
+ dataset['foo3'] = 'baz3';
+ expect(dataset.length, 2);
expect(attributes.length, 4);
attributes['style'] = 'width: 300px;';
expect(attributes.length, 5);

Powered by Google App Engine
This is Rietveld 408576698