OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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 library code_transformers.benchmarks; | 4 library code_transformers.benchmarks; |
5 | 5 |
6 import 'dart:async'; | 6 import 'dart:async'; |
7 import 'package:barback/barback.dart'; | 7 import 'package:barback/barback.dart'; |
8 import 'src/async_benchmark_base.dart'; | 8 import 'src/async_benchmark_base.dart'; |
9 | 9 |
10 /// A benchmark for testing the performance of transformer phases. | 10 /// A benchmark for testing the performance of transformer phases. |
(...skipping 56 matching lines...) Loading... |
67 | 67 |
68 /// Tells barback which files have changed, and thus anything that depends on | 68 /// Tells barback which files have changed, and thus anything that depends on |
69 /// it on should be computed. Returns a [Future] that completes once some | 69 /// it on should be computed. Returns a [Future] that completes once some |
70 /// results are received. | 70 /// results are received. |
71 Future run([Iterable<AssetId> assetIds]) { | 71 Future run([Iterable<AssetId> assetIds]) { |
72 if (assetIds == null) assetIds = _files.keys; | 72 if (assetIds == null) assetIds = _files.keys; |
73 _barback.updateSources(assetIds); | 73 _barback.updateSources(assetIds); |
74 return _barback.results.first; | 74 return _barback.results.first; |
75 } | 75 } |
76 } | 76 } |
OLD | NEW |