Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 descriptor_test; | 5 library descriptor_test; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 import 'dart:io'; | 8 import 'dart:io'; |
| 9 | 9 |
| 10 import 'package:pathos/path.dart' as path; | 10 import '../../../pkg/pathos/lib/path.dart' as path; |
| 11 import 'package:scheduled_test/descriptor.dart' as d; | 11 import '../lib/descriptor.dart' as d; |
| 12 import 'package:scheduled_test/scheduled_test.dart'; | 12 import '../lib/scheduled_test.dart'; |
|
Bob Nystrom
2013/03/12 22:23:35
These can probably say "package:" since pub won't
nweiz
2013/03/12 22:43:47
I don't think so; the lib files import pathos rela
| |
| 13 | 13 |
| 14 import 'metatest.dart'; | 14 import 'metatest.dart'; |
| 15 import 'utils.dart'; | 15 import 'utils.dart'; |
| 16 | 16 |
| 17 String sandbox; | 17 String sandbox; |
| 18 | 18 |
| 19 void main() { | 19 void main() { |
| 20 expectTestsPass('file().create() creates a file', () { | 20 expectTestsPass('file().create() creates a file', () { |
| 21 test('test', () { | 21 test('test', () { |
| 22 scheduleSandbox(); | 22 scheduleSandbox(); |
| (...skipping 1110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1133 | 1133 |
| 1134 Future<List<int>> byteStreamToList(Stream<List<int>> stream) { | 1134 Future<List<int>> byteStreamToList(Stream<List<int>> stream) { |
| 1135 return stream.reduce(<int>[], (buffer, chunk) { | 1135 return stream.reduce(<int>[], (buffer, chunk) { |
| 1136 buffer.addAll(chunk); | 1136 buffer.addAll(chunk); |
| 1137 return buffer; | 1137 return buffer; |
| 1138 }); | 1138 }); |
| 1139 } | 1139 } |
| 1140 | 1140 |
| 1141 Future<String> byteStreamToString(Stream<List<int>> stream) => | 1141 Future<String> byteStreamToString(Stream<List<int>> stream) => |
| 1142 byteStreamToList(stream).then((bytes) => new String.fromCharCodes(bytes)); | 1142 byteStreamToList(stream).then((bytes) => new String.fromCharCodes(bytes)); |
| OLD | NEW |