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

Unified Diff: runtime/observatory/tests/observatory_ui/nav/menu-item/element_test.dart

Issue 2310003004: Removed polymer & mirror from Observatory (Closed)
Patch Set: Fixed crash in heap-map page Created 4 years, 3 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: runtime/observatory/tests/observatory_ui/nav/menu-item/element_test.dart
diff --git a/runtime/observatory/tests/observatory_ui/nav/menu-item/element_test.dart b/runtime/observatory/tests/observatory_ui/nav/menu-item/element_test.dart
index 5ab71f1bd482d2142494afe098c959549e362afd..779cd0a76e29121231d13f6967d365be2a0409e3 100644
--- a/runtime/observatory/tests/observatory_ui/nav/menu-item/element_test.dart
+++ b/runtime/observatory/tests/observatory_ui/nav/menu-item/element_test.dart
@@ -27,14 +27,15 @@ main() {
test('created', () async {
final label = 'custom-label';
final e = new NavMenuItemElement(label);
+ e.content = [document.createElement('content')];
document.body.append(e);
await e.onRendered.first;
- expect(e.shadowRoot.children.length, isNonZero, reason: 'has elements');
- expect(e.shadowRoot.querySelector('content'), isNotNull,
+ expect(e.children.length, isNonZero, reason: 'has elements');
+ expect(e.querySelector('content'), isNotNull,
reason: 'has content elements');
e.remove();
await e.onRendered.first;
- expect(e.shadowRoot.children.length, isZero, reason: 'is empty');
+ expect(e.children.length, isZero, reason: 'is empty');
});
test('react to label change', () async {
final label1 = 'custom-label-1';
@@ -42,12 +43,12 @@ main() {
final e = new NavMenuItemElement(label1);
document.body.append(e);
await e.onRendered.first;
- expect(e.shadowRoot.innerHtml.contains(label1), isTrue);
- expect(e.shadowRoot.innerHtml.contains(label2), isFalse);
+ expect(e.innerHtml.contains(label1), isTrue);
+ expect(e.innerHtml.contains(label2), isFalse);
e.label = label2;
await e.onRendered.first;
- expect(e.shadowRoot.innerHtml.contains(label1), isFalse);
- expect(e.shadowRoot.innerHtml.contains(label2), isTrue);
+ expect(e.innerHtml.contains(label1), isFalse);
+ expect(e.innerHtml.contains(label2), isTrue);
e.remove();
await e.onRendered.first;
});
@@ -58,12 +59,12 @@ main() {
final e = new NavMenuItemElement(label, link: link1);
document.body.append(e);
await e.onRendered.first;
- expect(e.shadowRoot.innerHtml.contains(link1), isTrue);
- expect(e.shadowRoot.innerHtml.contains(link2), isFalse);
+ expect(e.innerHtml.contains(link1), isTrue);
+ expect(e.innerHtml.contains(link2), isFalse);
e.link = link2;
await e.onRendered.first;
- expect(e.shadowRoot.innerHtml.contains(link1), isFalse);
- expect(e.shadowRoot.innerHtml.contains(link2), isTrue);
+ expect(e.innerHtml.contains(link1), isFalse);
+ expect(e.innerHtml.contains(link2), isTrue);
e.remove();
await e.onRendered.first;
});

Powered by Google App Engine
This is Rietveld 408576698