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

Side by Side Diff: test/codegen/lib/html/deferred_multi_app.dart

Issue 1930043002: Add all dart:html tests from the sdk to test/codegen. (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 7 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
OLDNEW
(Empty)
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file.
4
5 import "deferred_multi_app_lib.dart" deferred as lib;
6 import "dart:async";
7 import "dart:html";
8 import "package:expect/expect.dart";
9
10 main() {
11 Element state = querySelector("#state");
12 if (state.text == "1") {
13 lib.loadLibrary().then((_) {
14 var a = lib.one();
15 Expect.equals("one", a);
16 window.postMessage(a, '*');
17 });
18 state.text = "2";
19 } else {
20 new Timer(new Duration(milliseconds: 100), () {
21 lib.loadLibrary().then((_) {
22 var a = lib.two();
23 Expect.equals("two", a);
24 window.postMessage(a, '*');
25 });
26 });
27 }
28 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698