| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 library dart2js.serialization_model_test; | 5 library dart2js.serialization_model_test; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 import 'dart:io'; | 8 import 'dart:io'; |
| 9 import 'package:async_helper/async_helper.dart'; | 9 import 'package:async_helper/async_helper.dart'; |
| 10 import 'package:expect/expect.dart'; | 10 import 'package:expect/expect.dart'; |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 main(List<String> args) { | 33 main(List<String> args) { |
| 34 asyncTest(() async { | 34 asyncTest(() async { |
| 35 Arguments arguments = new Arguments.from(args); | 35 Arguments arguments = new Arguments.from(args); |
| 36 String serializedData = await serializeDartCore(arguments: arguments); | 36 String serializedData = await serializeDartCore(arguments: arguments); |
| 37 if (arguments.filename != null) { | 37 if (arguments.filename != null) { |
| 38 Uri entryPoint = Uri.base.resolve(nativeToUriPath(arguments.filename)); | 38 Uri entryPoint = Uri.base.resolve(nativeToUriPath(arguments.filename)); |
| 39 await check(serializedData, entryPoint); | 39 await check(serializedData, entryPoint); |
| 40 } else { | 40 } else { |
| 41 Uri entryPoint = Uri.parse('memory:main.dart'); | 41 Uri entryPoint = Uri.parse('memory:main.dart'); |
| 42 for (Test test in TESTS) { | 42 for (Test test in TESTS) { |
| 43 if (test.sourceFiles['main.dart'] | |
| 44 .contains('main(List<String> arguments)')) { | |
| 45 // TODO(johnniwinther): Check this test. | |
| 46 continue; | |
| 47 } | |
| 48 print('=============================================================='); | 43 print('=============================================================='); |
| 49 print(test.sourceFiles); | 44 print(test.sourceFiles); |
| 50 await check( | 45 await check( |
| 51 serializedData, | 46 serializedData, |
| 52 entryPoint, | 47 entryPoint, |
| 53 sourceFiles: test.sourceFiles, | 48 sourceFiles: test.sourceFiles, |
| 54 verbose: arguments.verbose); | 49 verbose: arguments.verbose); |
| 55 } | 50 } |
| 56 } | 51 } |
| 57 }); | 52 }); |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 190 | 185 |
| 191 if (failOnUnfound || remaining.isNotEmpty) { | 186 if (failOnUnfound || remaining.isNotEmpty) { |
| 192 Expect.fail(message); | 187 Expect.fail(message); |
| 193 } else { | 188 } else { |
| 194 print(message); | 189 print(message); |
| 195 } | 190 } |
| 196 } else if (verbose) { | 191 } else if (verbose) { |
| 197 print(message); | 192 print(message); |
| 198 } | 193 } |
| 199 } | 194 } |
| OLD | NEW |