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

Unified Diff: tests/standalone/src/io/HttpServerSocketTest.dart

Issue 10173024: Change the error handling in dart:io (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 8 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
« no previous file with comments | « tests/standalone/src/io/FileTest.dart ('k') | tests/standalone/src/io/HttpShutdownTest.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/src/io/HttpServerSocketTest.dart
diff --git a/tests/standalone/src/io/HttpServerSocketTest.dart b/tests/standalone/src/io/HttpServerSocketTest.dart
index 346a48929a549be781e9e524ffcac58bd1b4f151..67d5722f7fc74b60256f29d996ae73b36016729a 100644
--- a/tests/standalone/src/io/HttpServerSocketTest.dart
+++ b/tests/standalone/src/io/HttpServerSocketTest.dart
@@ -15,6 +15,10 @@ class ExpectedDataOutputStream implements OutputStream {
_onNoPendingWrites = callback;
}
+ void set onError(void callback(e)) {
+ _onError = callback;
+ }
+
bool write(List data, [bool copyBuffer = true]) {
_onData(data);
return true;
@@ -45,6 +49,7 @@ class ExpectedDataOutputStream implements OutputStream {
}
Function _onNoPendingWrites;
+ Function _onError;
List<int> _data;
int _written = 0;
int _cutoff;
@@ -97,7 +102,7 @@ class SocketMock implements Socket {
_onClosed = callback;
}
- void set onError(void callback(Exception error)) {
+ void set onError(void callback(e)) {
_onError = callback;
}
@@ -147,7 +152,7 @@ class ServerSocketMock implements ServerSocket {
_onConnection = callback;
}
- void set onError(void callback(Exception)) {
+ void set onError(void callback(e)) {
_onError = callback;
}
« no previous file with comments | « tests/standalone/src/io/FileTest.dart ('k') | tests/standalone/src/io/HttpShutdownTest.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698