| OLD | NEW |
| 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, 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 // Partial test that the closed world computed from [WorldImpact]s derived from | 5 // Partial test that the closed world computed from [WorldImpact]s derived from |
| 6 // kernel is equivalent to the original computed from resolution. | 6 // kernel is equivalent to the original computed from resolution. |
| 7 library dart2js.kernel.compile_from_dill_test; | 7 library dart2js.kernel.compile_from_dill_test; |
| 8 | 8 |
| 9 import 'dart:async'; | 9 import 'dart:async'; |
| 10 import 'dart:io'; | 10 import 'dart:io'; |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 import '../memory_compiler.dart'; | 26 import '../memory_compiler.dart'; |
| 27 import '../equivalence/check_functions.dart'; | 27 import '../equivalence/check_functions.dart'; |
| 28 import '../equivalence/check_helpers.dart'; | 28 import '../equivalence/check_helpers.dart'; |
| 29 import '../serialization/helper.dart'; | 29 import '../serialization/helper.dart'; |
| 30 import 'test_helpers.dart'; | 30 import 'test_helpers.dart'; |
| 31 | 31 |
| 32 import 'compiler_helper.dart'; | 32 import 'compiler_helper.dart'; |
| 33 | 33 |
| 34 const SOURCE = const { | 34 const SOURCE = const { |
| 35 'main.dart': ''' | 35 'main.dart': ''' |
| 36 foo() {} | 36 foo() => 1; |
| 37 main() { | 37 main() { |
| 38 foo(); | 38 foo(); |
| 39 return null; | 39 return null; |
| 40 } | 40 } |
| 41 ''' | 41 ''' |
| 42 }; | 42 }; |
| 43 | 43 |
| 44 main(List<String> args) { | 44 main(List<String> args) { |
| 45 asyncTest(() async { | 45 asyncTest(() async { |
| 46 await mainInternal(args); | 46 await mainInternal(args); |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 160 } | 160 } |
| 161 Map<String, BufferedOutputSink> map2 = collector2.outputMap[outputType]; | 161 Map<String, BufferedOutputSink> map2 = collector2.outputMap[outputType]; |
| 162 checkSets(map1.keys, map2.keys, 'output', equality); | 162 checkSets(map1.keys, map2.keys, 'output', equality); |
| 163 map1.forEach((String name, BufferedOutputSink output1) { | 163 map1.forEach((String name, BufferedOutputSink output1) { |
| 164 BufferedOutputSink output2 = map2[name]; | 164 BufferedOutputSink output2 = map2[name]; |
| 165 Expect.stringEquals(output1.text, output2.text); | 165 Expect.stringEquals(output1.text, output2.text); |
| 166 }); | 166 }); |
| 167 }); | 167 }); |
| 168 return ResultKind.success; | 168 return ResultKind.success; |
| 169 } | 169 } |
| OLD | NEW |