| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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('dart:uri'); | 5 #import('dart:uri'); |
| 6 #import('parser_helper.dart'); | 6 #import('parser_helper.dart'); |
| 7 #import('mock_compiler.dart'); | 7 #import('mock_compiler.dart'); |
| 8 #import("../../../lib/compiler/compiler.dart"); | 8 #import("../../../lib/compiler/compiler.dart"); |
| 9 #import("../../../lib/compiler/implementation/leg.dart", prefix:'leg'); | 9 #import("../../../lib/compiler/implementation/leg.dart", prefix:'leg'); |
| 10 #import("../../../lib/compiler/implementation/dart_backend/dart_backend.dart"); | 10 #import("../../../lib/compiler/implementation/dart_backend/dart_backend.dart"); |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 } | 80 } |
| 81 | 81 |
| 82 handler(uri, begin, end, message, kind) { | 82 handler(uri, begin, end, message, kind) { |
| 83 if (kind === Diagnostic.ERROR || kind === Diagnostic.CRASH) { | 83 if (kind === Diagnostic.ERROR || kind === Diagnostic.CRASH) { |
| 84 Expect.fail('$uri: $begin-$end: $message [$kind]'); | 84 Expect.fail('$uri: $begin-$end: $message [$kind]'); |
| 85 } | 85 } |
| 86 } | 86 } |
| 87 | 87 |
| 88 final options = <String>['--output-type=dart']; | 88 final options = <String>['--output-type=dart']; |
| 89 if (minify) options.add('--minify'); | 89 if (minify) options.add('--minify'); |
| 90 if (cutDeclarationTypes) options.add('--cut-declaration-types'); | 90 if (cutDeclarationTypes) options.add('--force-cut-declaration-types'); |
| 91 | 91 |
| 92 compile( | 92 compile( |
| 93 scriptUri, | 93 scriptUri, |
| 94 fileUri('libraryRoot'), | 94 fileUri('libraryRoot'), |
| 95 fileUri('packageRoot'), | 95 fileUri('packageRoot'), |
| 96 provider, | 96 provider, |
| 97 handler, | 97 handler, |
| 98 options).then(continuation); | 98 options).then(continuation); |
| 99 } | 99 } |
| 100 | 100 |
| (...skipping 747 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 848 testDoubleMains(); | 848 testDoubleMains(); |
| 849 testInterfaceDefaultAnotherLib(); | 849 testInterfaceDefaultAnotherLib(); |
| 850 testStaticAccessIoLib(); | 850 testStaticAccessIoLib(); |
| 851 testLocalFunctionPlaceholder(); | 851 testLocalFunctionPlaceholder(); |
| 852 testMinification(); | 852 testMinification(); |
| 853 testClosureLocalsMinified(); | 853 testClosureLocalsMinified(); |
| 854 testParametersMinified(); | 854 testParametersMinified(); |
| 855 testTypeVariablesInDifferentLibraries(); | 855 testTypeVariablesInDifferentLibraries(); |
| 856 testDeclarationTypePlaceholders(); | 856 testDeclarationTypePlaceholders(); |
| 857 } | 857 } |
| OLD | NEW |