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

Unified Diff: tests/standalone/io/secure_socket_bad_certificate_test.dart

Issue 13548002: Add Iterable.fold (and Stream.fold) which replace `reduce`. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 9 months 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
Index: tests/standalone/io/secure_socket_bad_certificate_test.dart
diff --git a/tests/standalone/io/secure_socket_bad_certificate_test.dart b/tests/standalone/io/secure_socket_bad_certificate_test.dart
index c2581f82011860c2e2be3650c98fc24dfce3bc0e..5cb414566380895f79884ed949116d66cb044b86 100644
--- a/tests/standalone/io/secure_socket_bad_certificate_test.dart
+++ b/tests/standalone/io/secure_socket_bad_certificate_test.dart
@@ -51,7 +51,7 @@ Future testCertificateCallback({String host, bool acceptCertificate}) {
Expect.isTrue(acceptCertificate);
socket.write("GET / HTTP/1.0\r\nHost: $host\r\n\r\n");
socket.close();
- return socket.reduce(<int>[], (message, data) => message..addAll(data))
+ return socket.fold(<int>[], (message, data) => message..addAll(data))
.then((message) {
String received = new String.fromCharCodes(message);
Expect.isTrue(received.contains('</body></html>'));

Powered by Google App Engine
This is Rietveld 408576698