| 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 /// Visualization of source mappings generated and tested in | 5 /// Visualization of source mappings generated and tested in |
| 6 /// 'source_mapping_test.dart'. | 6 /// 'source_mapping_test.dart'. |
| 7 | 7 |
| 8 library source_mapping.test.viewer; | 8 library source_mapping.test.viewer; |
| 9 | 9 |
| 10 import 'dart:async'; | 10 import 'dart:async'; |
| 11 import 'package:compiler/src/filenames.dart'; | 11 import 'package:compiler/src/filenames.dart'; |
| 12 import 'package:compiler/src/util/util.dart'; | 12 import 'package:compiler/src/util/util.dart'; |
| 13 import 'source_mapping_tester.dart'; | 13 import 'source_mapping_tester.dart'; |
| 14 import 'sourcemap_helper.dart'; | |
| 15 import 'sourcemap_html_helper.dart'; | 14 import 'sourcemap_html_helper.dart'; |
| 16 import 'sourcemap_html_templates.dart'; | 15 import 'sourcemap_html_templates.dart'; |
| 17 | 16 |
| 18 const String DEFAULT_OUTPUT_PATH = 'out.js.map.html'; | 17 const String DEFAULT_OUTPUT_PATH = 'out.js.map.html'; |
| 19 | 18 |
| 20 main(List<String> arguments) async { | 19 main(List<String> arguments) async { |
| 21 bool measure = false; | 20 bool measure = false; |
| 22 String outputPath = DEFAULT_OUTPUT_PATH; | 21 String outputPath = DEFAULT_OUTPUT_PATH; |
| 23 Set<String> configurations = new Set<String>(); | 22 Set<String> configurations = new Set<String>(); |
| 24 Set<String> files = new Set<String>(); | 23 Set<String> files = new Set<String>(); |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 final int count; | 148 final int count; |
| 150 | 149 |
| 151 Measurement(this.config, this.filename, this.missing, this.count); | 150 Measurement(this.config, this.filename, this.missing, this.count); |
| 152 | 151 |
| 153 String toString() { | 152 String toString() { |
| 154 double percentage = 100 * missing / count; | 153 double percentage = 100 * missing / count; |
| 155 return "Config '${config}', file: '${filename}': " | 154 return "Config '${config}', file: '${filename}': " |
| 156 "$missing of $count ($percentage%) missing"; | 155 "$missing of $count ($percentage%) missing"; |
| 157 } | 156 } |
| 158 } | 157 } |
| OLD | NEW |