Permalink
Browse files

Added a basic sockets sanity test case

  • Loading branch information...
1 parent cf8c2bc commit 07c7fb7aa50f0f1972d77f890495ef6c8122cc7a @cosimo committed Mar 6, 2011
Showing with 16 additions and 0 deletions.
  1. +16 −0 t/socket-sanity.t
View
@@ -0,0 +1,16 @@
+use v6;
+use Test;
+
+plan 2;
+
+my $s = IO::Socket::INET.new;
+ok($s, 'Socket object created');
+
+#my $opened = $s.open('www.rakudo.org', 80);
+my $opened = $s.open('72.14.176.61', 80);
+ok($opened, 'Socket to www.rakudo.org:80 opened');
+
+if ! $opened {
+ diag("Failed opening the socket: $opened");
+}
+

0 comments on commit 07c7fb7

Please sign in to comment.