diff options
author | Andreas Schneider <asn@cryptomilk.org> | 2013-12-10 11:03:12 +0100 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2013-12-10 14:23:26 +0100 |
commit | 1e12eb0b3e4f974c33a2b628d0857e137fce8cfa (patch) | |
tree | 3ebe5ec1939f831479e684b2c75bec8d142c1b09 /tests/torture.h | |
parent | 78cc4fb76d14d4df313e412bf148312eea2c706b (diff) | |
download | socket_wrapper-1e12eb0b3e4f974c33a2b628d0857e137fce8cfa.tar.gz socket_wrapper-1e12eb0b3e4f974c33a2b628d0857e137fce8cfa.tar.xz socket_wrapper-1e12eb0b3e4f974c33a2b628d0857e137fce8cfa.zip |
tests: Add a torture library with helpers.
Diffstat (limited to 'tests/torture.h')
-rw-r--r-- | tests/torture.h | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/tests/torture.h b/tests/torture.h index 2af5aca..2bc0cf7 100644 --- a/tests/torture.h +++ b/tests/torture.h @@ -31,15 +31,30 @@ * SUCH DAMAGE. */ -#include "config.h" - #ifndef _TORTURE_H #define _TORTURE_H +#include "config.h" + +#include <stdarg.h> +#include <stddef.h> +#include <setjmp.h> +#include <cmocka.h> + #include <string.h> +#define TORTURE_ECHO_SRV_PORT 7 + +struct torture_state { + char *socket_dir; + char *srv_pidfile; +}; + #ifndef ZERO_STRUCT #define ZERO_STRUCT(x) memset((char *)&(x), 0, sizeof(x)) #endif +void torture_setup_socket_dir(void **state); +void torture_setup_echo_srv_udp_ipv4(void **state); + #endif /* _TORTURE_H */ |