Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(681)

Unified Diff: utils/tests/pub/test_pub.dart

Issue 11412086: Make 'where' lazy. (Closed) Base URL: https://dart.googlecode.com/svn/experimental/lib_v2/dart
Patch Set: FilteredIterable/Iterator -> WhereIterable/Iterator. Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« runtime/lib/growable_array.dart ('K') | « tests/html/xmlelement_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/tests/pub/test_pub.dart
diff --git a/utils/tests/pub/test_pub.dart b/utils/tests/pub/test_pub.dart
index e5d994356a8ce0368341d5bb7440d15e45d5e3a8..6b3adb16673dce6d2efd2fc534a7ba39e7990f3f 100644
--- a/utils/tests/pub/test_pub.dart
+++ b/utils/tests/pub/test_pub.dart
@@ -783,8 +783,8 @@ abstract class Descriptor {
}
return listDir(dir).chain((files) {
- var matches = files.where((file) => endsWithPattern(file, name));
- if (matches.length == 0) {
+ var matches = files.where((file) => endsWithPattern(file, name)).toList();
+ if (matches.isEmpty) {
Expect.fail('No files in $dir match pattern $name.');
}
if (matches.length == 1) return validate(matches[0]);
« runtime/lib/growable_array.dart ('K') | « tests/html/xmlelement_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698