| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // BSD-style license that can be found in the LICENSE file. | |
| 4 | |
| 5 library barback.test.transformer.emit_nothing; | |
| 6 | |
| 7 import 'package:barback/barback.dart'; | |
| 8 | |
| 9 import 'mock.dart'; | |
| 10 | |
| 11 /// A transformer that emits no assets. | |
| 12 class EmitNothingTransformer extends MockTransformer { | |
| 13 final String extension; | |
| 14 | |
| 15 EmitNothingTransformer(this.extension); | |
| 16 | |
| 17 bool doIsPrimary(AssetId id) => id.extension == ".$extension"; | |
| 18 | |
| 19 void doApply(Transform transform) { | |
| 20 // Emit nothing. | |
| 21 } | |
| 22 | |
| 23 String toString() => "$extension->nothing"; | |
| 24 } | |
| OLD | NEW |