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

Side by Side Diff: dart/tests/compiler/dart2js/message_kind_test.dart

Issue 233233002: Copy types object when using a cached compiler. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Found issue during test, added comment. Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « dart/tests/compiler/dart2js/memory_compiler.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 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. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 import 'package:expect/expect.dart'; 5 import 'package:expect/expect.dart';
6 import 'dart:async'; 6 import 'dart:async';
7 import "package:async_helper/async_helper.dart"; 7 import "package:async_helper/async_helper.dart";
8 import '../../../sdk/lib/_internal/compiler/implementation/dart2jslib.dart' show 8 import '../../../sdk/lib/_internal/compiler/implementation/dart2jslib.dart' show
9 DualKind, 9 DualKind,
10 MessageKind; 10 MessageKind;
(...skipping 30 matching lines...) Expand all
41 if (kind.examples != null) { 41 if (kind.examples != null) {
42 examples.add(name); 42 examples.add(name);
43 } else { 43 } else {
44 print("No example in '$name'"); 44 print("No example in '$name'");
45 } 45 }
46 }; 46 };
47 var cachedCompiler; 47 var cachedCompiler;
48 asyncTest(() => Future.forEach(examples, (String name) { 48 asyncTest(() => Future.forEach(examples, (String name) {
49 print("Checking '$name'."); 49 print("Checking '$name'.");
50 Stopwatch sw = new Stopwatch()..start(); 50 Stopwatch sw = new Stopwatch()..start();
51 bool useCachedCompiler = true; 51 return check(kinds[name], cachedCompiler).then((var compiler) {
52 if (name == 'MISSING_LIBRARY_NAME') { 52 cachedCompiler = compiler;
53 // TODO(johnniwinther): Found out why we cannot use the cached compiler 53 sw.stop();
54 // for this message kind. 54 print("Checked '$name' in ${sw.elapsedMilliseconds}ms.");
55 cachedCompiler = null; 55 });
56 } 56 }));
57 return check(kinds[name], cachedCompiler).
58 then((var compiler) {
59 cachedCompiler = compiler;
60 sw.stop();
61 print("Checked '$name' in ${sw.elapsedMilliseconds}ms.");
62 });
63 }
64 ));
65 } 57 }
OLDNEW
« no previous file with comments | « dart/tests/compiler/dart2js/memory_compiler.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698