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

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

Issue 10917064: Throw an error if the ServerSocket host argument is invalid. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Use in_addr_t as s_addr type. Created 8 years, 3 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 | « runtime/bin/socket_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/io/socket_exception_test.dart
diff --git a/tests/standalone/io/socket_exception_test.dart b/tests/standalone/io/socket_exception_test.dart
index 924822dae3e93571c9dd2fd9ac5515a557d15311..0df0be4eb067a413368d770b3da1a6ceb5736777 100644
--- a/tests/standalone/io/socket_exception_test.dart
+++ b/tests/standalone/io/socket_exception_test.dart
@@ -28,6 +28,9 @@ class SocketExceptionTest {
}
Expect.equals(false, exceptionCaught);
Expect.equals(true, !wrongExceptionCaught);
+
+ // Test invalid host.
+ Expect.throws(() => new ServerSocket("__INVALID_HOST__", PORT, 10));
Søren Gjesse 2012/09/03 13:56:44 Maybe do some checking on the actual exception (is
Anders Johnsen 2012/09/03 14:34:38 Turns out it's a SocketIOException. Check added.
}
static void clientSocketExceptionTest() {
@@ -198,6 +201,7 @@ class SocketExceptionTest {
clientSocketExceptionTest();
indexOutOfRangeExceptionTest();
unknownHostTest();
+
// TODO(sgjesse): This test seems to fail on the buildbot.
//unresponsiveHostTest();
}
« no previous file with comments | « runtime/bin/socket_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698