| 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 // Test that parameters keep their names in the output. | 4 // Test that parameters keep their names in the output. |
| 5 | 5 |
| 6 import "package:expect/expect.dart"; |
| 7 import "package:async_helper/async_helper.dart"; |
| 8 import 'memory_compiler.dart'; |
| 9 import 'package:compiler/src/dump_info.dart'; |
| 6 import 'dart:convert'; | 10 import 'dart:convert'; |
| 7 import 'package:expect/expect.dart'; | |
| 8 import 'package:async_helper/async_helper.dart'; | |
| 9 import 'memory_compiler.dart'; | |
| 10 | 11 |
| 11 const String TEST_BASIC= r""" | 12 const String TEST_BASIC= r""" |
| 12 library main; | 13 library main; |
| 13 | 14 |
| 14 int a = 2; | 15 int a = 2; |
| 15 | 16 |
| 16 class c { | 17 class c { |
| 17 final int m; | 18 final int m; |
| 18 c(this.m) { | 19 c(this.m) { |
| 19 () {} (); // TODO (sigurdm): Empty closure, hack to avoid inlining. | 20 () {} (); // TODO (sigurdm): Empty closure, hack to avoid inlining. |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 177 Expect.isTrue(main_ != null); | 178 Expect.isTrue(main_ != null); |
| 178 Expect.isTrue(fn1 != null); | 179 Expect.isTrue(fn1 != null); |
| 179 Expect.isTrue(fn2 != null); | 180 Expect.isTrue(fn2 != null); |
| 180 Expect.isTrue(deps.containsKey(main_['id'])); | 181 Expect.isTrue(deps.containsKey(main_['id'])); |
| 181 Expect.isTrue(deps.containsKey(fn1['id'])); | 182 Expect.isTrue(deps.containsKey(fn1['id'])); |
| 182 Expect.isTrue(deps.containsKey(fn2['id'])); | 183 Expect.isTrue(deps.containsKey(fn2['id'])); |
| 183 Expect.isTrue(deps[main_['id']].any((dep) => dep['id'] == fn1['id'])); | 184 Expect.isTrue(deps[main_['id']].any((dep) => dep['id'] == fn1['id'])); |
| 184 Expect.isTrue(deps[fn1['id']].any((dep) => dep['id'] == fn2['id'])); | 185 Expect.isTrue(deps[fn1['id']].any((dep) => dep['id'] == fn2['id'])); |
| 185 }); | 186 }); |
| 186 } | 187 } |
| OLD | NEW |