| 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 30 matching lines...) Expand all Loading... |
| 41 } | 41 } |
| 42 main() { | 42 main() { |
| 43 foo(); | 43 foo(); |
| 44 bar(true); | 44 bar(true); |
| 45 []; | 45 []; |
| 46 {}; | 46 {}; |
| 47 new Object(); | 47 new Object(); |
| 48 new Class(''); | 48 new Class(''); |
| 49 Class.staticField; | 49 Class.staticField; |
| 50 var x = null; | 50 var x = null; |
| 51 for (int i = 0; i < 10; i++) { |
| 52 x = i; |
| 53 if (i == 5) break; |
| 54 } |
| 51 return x; | 55 return x; |
| 52 } | 56 } |
| 53 ''' | 57 ''' |
| 54 }; | 58 }; |
| 55 | 59 |
| 56 main(List<String> args) { | 60 main(List<String> args) { |
| 57 asyncTest(() async { | 61 asyncTest(() async { |
| 58 await mainInternal(args); | 62 await mainInternal(args); |
| 59 }); | 63 }); |
| 60 } | 64 } |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 180 } | 184 } |
| 181 Map<String, BufferedOutputSink> map2 = collector2.outputMap[outputType]; | 185 Map<String, BufferedOutputSink> map2 = collector2.outputMap[outputType]; |
| 182 checkSets(map1.keys, map2.keys, 'output', equality); | 186 checkSets(map1.keys, map2.keys, 'output', equality); |
| 183 map1.forEach((String name, BufferedOutputSink output1) { | 187 map1.forEach((String name, BufferedOutputSink output1) { |
| 184 BufferedOutputSink output2 = map2[name]; | 188 BufferedOutputSink output2 = map2[name]; |
| 185 Expect.stringEquals(output1.text, output2.text); | 189 Expect.stringEquals(output1.text, output2.text); |
| 186 }); | 190 }); |
| 187 }); | 191 }); |
| 188 return ResultKind.success; | 192 return ResultKind.success; |
| 189 } | 193 } |
| OLD | NEW |