summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2013-12-12 21:24:07 +0100
committerAndreas Schneider <asn@samba.org>2013-12-12 21:24:07 +0100
commit17c7a05f564d7349503b6effed3e4ddb6eb1e87e (patch)
tree7d54979b43da2b23cc87a51584d9480038a89756 /tests
parent25d0e92c8c4ca13b5275448a67e5f6c5690a1d0e (diff)
downloadsocket_wrapper-17c7a05f564d7349503b6effed3e4ddb6eb1e87e.tar.gz
socket_wrapper-17c7a05f564d7349503b6effed3e4ddb6eb1e87e.tar.xz
socket_wrapper-17c7a05f564d7349503b6effed3e4ddb6eb1e87e.zip
tests: Remove FIONBIO cause it doesn't work on x86.
Diffstat (limited to 'tests')
-rw-r--r--tests/testsuite.c43
1 files changed, 19 insertions, 24 deletions
diff --git a/tests/testsuite.c b/tests/testsuite.c
index 70ffe8e..8f18097 100644
--- a/tests/testsuite.c
+++ b/tests/testsuite.c
@@ -63,30 +63,6 @@ static void test_socket_wrapper_dir(void **state)
}
#endif
-static void test_swrap_ioctl_sock(void **state)
-{
- int fd;
- int rc;
- int grp = -127;
-
- (void) state; /* unused */
-
- fd = socket(AF_INET, SOCK_DGRAM, 0);
- assert_int_not_equal(fd, -1);
-
-#ifdef FIONBIO
- rc = ioctl(fd, FIONBIO);
- assert_int_equal(rc, 0);
-#endif
-
-#ifdef SIOCGPGRP
- rc = ioctl(fd, SIOCGPGRP, &grp);
- assert_int_equal(rc, 0);
-
- assert_int_not_equal(grp, -127);
-#endif
-}
-
static void test_swrap_socket(void **state)
{
int rc;
@@ -106,6 +82,25 @@ static void test_swrap_socket(void **state)
assert_int_equal(errno, EPROTONOSUPPORT);
}
+static void test_swrap_ioctl_sock(void **state)
+{
+ int fd;
+ int rc;
+ int grp = -127;
+
+ (void) state; /* unused */
+
+ fd = socket(AF_INET, SOCK_DGRAM, 0);
+ assert_int_not_equal(fd, -1);
+
+#ifdef SIOCGPGRP
+ rc = ioctl(fd, SIOCGPGRP, &grp);
+ assert_int_equal(rc, 0);
+
+ assert_int_not_equal(grp, -127);
+#endif
+}
+
#if 0
unsigned int socket_wrapper_default_iface(void);
static bool test_socket_wrapper_default_iface(struct torture_context *tctx)