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

Side by Side Diff: sky/tests/dom/inherit-from-text.sky

Issue 1212163009: Port remaining Sky tests to the new world (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: add Created 5 years, 5 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 unified diff | Download patch
« no previous file with comments | « sky/tests/dom/getChildElements.sky ('k') | sky/tests/dom/inherit-from-text-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <sky>
2 <script>
3 import "../resources/third_party/unittest/unittest.dart";
4 import "../resources/unit.dart";
5
6 import "dart:sky";
7
8 class CustomText extends Text {
9 CustomText() : super("awesome");
10
11 bool get isCustom => true;
12 }
13
14 void main() {
15 initUnit();
16
17 test("should be able to insert in DOM", () {
18 var child = new CustomText();
19 expect(child.isCustom, isTrue);
20 expect(child.parentNode, isNull);
21 expect(child.data, equals("awesome"));
22
23 var parent = document.createElement("div");
24 parent.appendChild(child);
25 expect(child.parentNode, equals(parent));
26 expect(parent.firstChild, equals(child));
27 expect(parent.firstChild.isCustom, isTrue);
28 });
29 }
30 </script>
31 </sky>
OLDNEW
« no previous file with comments | « sky/tests/dom/getChildElements.sky ('k') | sky/tests/dom/inherit-from-text-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698