Skip to content

Commit

Permalink
Add @System and @safe to std.socket unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
atilaneves committed Jul 4, 2016
1 parent 085f214 commit 5ba5c83
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions std/socket.d
Expand Up @@ -475,7 +475,7 @@ class Protocol
// Skip this test on Android because getprotobyname/number are
// unimplemented in bionic.
version(CRuntime_Bionic) {} else
unittest
@safe unittest
{
softUnittest({
Protocol proto = new Protocol;
Expand Down Expand Up @@ -576,7 +576,7 @@ class Service
}


unittest
@safe unittest
{
softUnittest({
Service serv = new Service;
Expand Down Expand Up @@ -825,7 +825,7 @@ class InternetHost
}


unittest
@safe unittest
{
InternetHost ih = new InternetHost;

Expand Down Expand Up @@ -1147,7 +1147,7 @@ Address[] getAddress(in char[] hostname, ushort port)
}


unittest
@safe unittest
{
softUnittest({
auto addresses = getAddress("63.105.9.61");
Expand Down Expand Up @@ -1227,7 +1227,7 @@ Address parseAddress(in char[] hostaddr, ushort port)
}


unittest
@safe unittest
{
softUnittest({
auto address = parseAddress("63.105.9.61");
Expand Down Expand Up @@ -1694,7 +1694,7 @@ public:
}


unittest
@safe unittest
{
softUnittest({
const InternetAddress ia = new InternetAddress("63.105.9.61", 80);
Expand Down Expand Up @@ -1901,7 +1901,7 @@ public:
}


unittest
@safe unittest
{
softUnittest({
const Internet6Address ia = new Internet6Address("::1", 80);
Expand Down Expand Up @@ -2024,7 +2024,7 @@ static if (is(sockaddr_un))
}
}

unittest
@safe unittest
{
import core.stdc.stdio : remove;
import std.file : deleteme;
Expand Down Expand Up @@ -2380,7 +2380,7 @@ public:
}
}

unittest
@safe unittest
{
auto fds = cast(socket_t[])
[cast(socket_t)1, 2, 0, 1024, 17, 42, 1234, 77, 77+32, 77+64];
Expand All @@ -2402,7 +2402,7 @@ unittest
}
}

unittest
@safe unittest
{
softUnittest({
enum PAIRS = 768;
Expand Down Expand Up @@ -2477,7 +2477,7 @@ unittest
});
}

unittest // Issue 14012, 14013
@safe unittest // Issue 14012, 14013
{
auto set = new SocketSet(1);
assert(set.max >= 0);
Expand Down Expand Up @@ -2578,7 +2578,7 @@ private:
// behavior.
enum WINSOCK_TIMEOUT_SKEW = 500;

unittest
@safe unittest
{
version(SlowTests)
softUnittest({
Expand Down Expand Up @@ -3550,7 +3550,7 @@ Socket[2] socketPair() @trusted
}

///
unittest
@safe unittest
{
immutable ubyte[] data = [1, 2, 3, 4];
auto pair = socketPair();
Expand Down

0 comments on commit 5ba5c83

Please sign in to comment.