aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-10-08 13:15:15 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-10-08 13:15:15 +0100
commiteb737947eb2afe98f9dac1121fa37d1b746c5657 (patch)
tree02aa7752555cc4a47b1a9b423066bbdc52a7e8c5 /test
parente0bfa35ee937940f20a5675bc7582cfc83c2866b (diff)
downloadrspamd-eb737947eb2afe98f9dac1121fa37d1b746c5657.tar.gz
rspamd-eb737947eb2afe98f9dac1121fa37d1b746c5657.zip
Reorganize includes to reduce namespace pollution.
Diffstat (limited to 'test')
-rw-r--r--test/rspamd_async_test.c4
-rw-r--r--test/rspamd_cryptobox_test.c1
-rw-r--r--test/rspamd_http_test.c6
-rw-r--r--test/rspamd_lua_test.c5
-rw-r--r--test/rspamd_mem_pool_test.c6
-rw-r--r--test/rspamd_shingles_test.c2
-rw-r--r--test/rspamd_test_suite.c2
-rw-r--r--test/rspamd_upstream_test.c2
8 files changed, 21 insertions, 7 deletions
diff --git a/test/rspamd_async_test.c b/test/rspamd_async_test.c
index 71eec712a..fcd76333f 100644
--- a/test/rspamd_async_test.c
+++ b/test/rspamd_async_test.c
@@ -22,11 +22,9 @@
*/
#include "config.h"
-#include "tests.h"
#include "rspamd.h"
#include "aio_event.h"
-#include "mem_pool.h"
-
+#include "unix-std.h"
extern struct event_base *base;
diff --git a/test/rspamd_cryptobox_test.c b/test/rspamd_cryptobox_test.c
index c7ad2921c..d01d99ee3 100644
--- a/test/rspamd_cryptobox_test.c
+++ b/test/rspamd_cryptobox_test.c
@@ -29,6 +29,7 @@
#include "fstring.h"
#include "ottery.h"
#include "cryptobox.h"
+#include "unix-std.h"
static const int mapping_size = 64 * 8192 + 1;
static const int max_seg = 32;
diff --git a/test/rspamd_http_test.c b/test/rspamd_http_test.c
index 429ae5be9..81b598a45 100644
--- a/test/rspamd_http_test.c
+++ b/test/rspamd_http_test.c
@@ -28,6 +28,12 @@
#include "tests.h"
#include "ottery.h"
#include "cryptobox.h"
+#include "unix-std.h"
+#include <math.h>
+
+#ifdef HAVE_SYS_WAIT_H
+#include <sys/wait.h>
+#endif
static const int file_blocks = 1;
static const int pconns = 100;
diff --git a/test/rspamd_lua_test.c b/test/rspamd_lua_test.c
index caeb9814e..8b1b09383 100644
--- a/test/rspamd_lua_test.c
+++ b/test/rspamd_lua_test.c
@@ -25,6 +25,11 @@
#include "rspamd.h"
#include "util.h"
#include "lua/lua_common.h"
+#include "unix-std.h"
+
+#ifdef HAVE_GLOB_H
+#include <glob.h>
+#endif
static const char *lua_src = BUILDROOT "/test/lua/tests.lua";
diff --git a/test/rspamd_mem_pool_test.c b/test/rspamd_mem_pool_test.c
index fe5ba56b8..e8813f574 100644
--- a/test/rspamd_mem_pool_test.c
+++ b/test/rspamd_mem_pool_test.c
@@ -1,6 +1,12 @@
#include "config.h"
#include "mem_pool.h"
#include "tests.h"
+#include "unix-std.h"
+#include <math.h>
+
+#ifdef HAVE_SYS_WAIT_H
+#include <sys/wait.h>
+#endif
#define TEST_BUF "test bufffer"
#define TEST2_BUF "test bufffertest bufffer"
diff --git a/test/rspamd_shingles_test.c b/test/rspamd_shingles_test.c
index 3a1dd8ba2..2b33ad684 100644
--- a/test/rspamd_shingles_test.c
+++ b/test/rspamd_shingles_test.c
@@ -24,8 +24,8 @@
#include "config.h"
#include "rspamd.h"
#include "shingles.h"
-#include "fstring.h"
#include "ottery.h"
+#include <math.h>
static void
generate_random_string (char *begin, size_t len)
diff --git a/test/rspamd_test_suite.c b/test/rspamd_test_suite.c
index e10ebd889..97d0565b8 100644
--- a/test/rspamd_test_suite.c
+++ b/test/rspamd_test_suite.c
@@ -1,7 +1,5 @@
#include "config.h"
#include "rspamd.h"
-#include "cfg_file.h"
-#include "regexp.h"
#include "libstat/stat_api.h"
#include "tests.h"
diff --git a/test/rspamd_upstream_test.c b/test/rspamd_upstream_test.c
index 9e04c4dda..e2f2c17ee 100644
--- a/test/rspamd_upstream_test.c
+++ b/test/rspamd_upstream_test.c
@@ -25,8 +25,8 @@
#include "config.h"
#include "rspamd.h"
-#include "upstream.h"
#include "ottery.h"
+#include <math.h>
const char *test_upstream_list = "microsoft.com:443:1,google.com:80:2,kernel.org:443:3";
const char *new_upstream_list = "freebsd.org:80";