aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2011-05-21 13:22:11 +0200
committerYang Tse <yangsita@gmail.com>2011-05-21 13:22:11 +0200
commit02f3ff3b0a8fc000270e274d540b65648ef81201 (patch)
tree9352c91e0dbad271d018f5c40a3387a207fd9064
parent3f6ffcd26d9b489e8f6248aa3a3d3d882c8502f0 (diff)
unit tests: adjust header inclusion order
Additionally, prevent multiple inclusions of curl_config.h
-rw-r--r--tests/unit/unit1300.c5
-rw-r--r--tests/unit/unit1301.c5
-rw-r--r--tests/unit/unit1302.c5
-rw-r--r--tests/unit/unit1303.c5
-rw-r--r--tests/unit/unit1304.c5
-rw-r--r--tests/unit/unit1305.c6
-rw-r--r--tests/unit/unit1307.c3
7 files changed, 8 insertions, 26 deletions
diff --git a/tests/unit/unit1300.c b/tests/unit/unit1300.c
index f4f5f2a54..0589c920a 100644
--- a/tests/unit/unit1300.c
+++ b/tests/unit/unit1300.c
@@ -19,12 +19,9 @@
* KIND, either express or implied.
*
***************************************************************************/
-#include <stdlib.h>
-#include "curl_config.h"
-#include "setup.h"
+#include "curlcheck.h"
#include "llist.h"
-#include "curlcheck.h"
struct curl_llist *llist;
diff --git a/tests/unit/unit1301.c b/tests/unit/unit1301.c
index 95f4b6aab..47df481a8 100644
--- a/tests/unit/unit1301.c
+++ b/tests/unit/unit1301.c
@@ -19,12 +19,9 @@
* KIND, either express or implied.
*
***************************************************************************/
-#include <stdlib.h>
-#include "curl_config.h"
-#include "setup.h"
+#include "curlcheck.h"
#include "strequal.h"
-#include "curlcheck.h"
static CURLcode unit_setup( void ) {return CURLE_OK;}
static void unit_stop( void ) {}
diff --git a/tests/unit/unit1302.c b/tests/unit/unit1302.c
index bc3651627..7a61ec062 100644
--- a/tests/unit/unit1302.c
+++ b/tests/unit/unit1302.c
@@ -19,14 +19,11 @@
* KIND, either express or implied.
*
***************************************************************************/
-#include <stdlib.h>
-#include "curl_config.h"
-#include "setup.h"
+#include "curlcheck.h"
#include "urldata.h"
#include "url.h" /* for Curl_safefree */
#include "curl_base64.h"
-#include "curlcheck.h"
#include "memdebug.h" /* LAST include file */
static struct SessionHandle *data;
diff --git a/tests/unit/unit1303.c b/tests/unit/unit1303.c
index 2b5669d28..f94daf7a6 100644
--- a/tests/unit/unit1303.c
+++ b/tests/unit/unit1303.c
@@ -19,13 +19,10 @@
* KIND, either express or implied.
*
***************************************************************************/
-#include <stdlib.h>
-#include "curl_config.h"
-#include "setup.h"
+#include "curlcheck.h"
#include "urldata.h"
#include "connect.h"
-#include "curlcheck.h"
#include "memdebug.h" /* LAST include file */
static struct SessionHandle *data;
diff --git a/tests/unit/unit1304.c b/tests/unit/unit1304.c
index 8b3132edc..3efbe0b82 100644
--- a/tests/unit/unit1304.c
+++ b/tests/unit/unit1304.c
@@ -19,12 +19,9 @@
* KIND, either express or implied.
*
***************************************************************************/
-#include <stdlib.h>
-#include "curl_config.h"
-#include "setup.h"
+#include "curlcheck.h"
#include "netrc.h"
-#include "curlcheck.h"
char login[LOGINSIZE];
char password[PASSWORDSIZE];
diff --git a/tests/unit/unit1305.c b/tests/unit/unit1305.c
index 68c76ceae..5900c6dd5 100644
--- a/tests/unit/unit1305.c
+++ b/tests/unit/unit1305.c
@@ -19,11 +19,8 @@
* KIND, either express or implied.
*
***************************************************************************/
-#include "test.h"
+#include "curlcheck.h"
-#ifdef HAVE_SYS_SOCKET_H
-# include <sys/socket.h>
-#endif
#ifdef HAVE_NETINET_IN_H
# include <netinet/in.h>
#endif
@@ -39,7 +36,6 @@
#include "hash.h"
#include "hostip.h"
-#include "curlcheck.h"
#include "curl_memory.h"
#include "memdebug.h" /* LAST include file */
diff --git a/tests/unit/unit1307.c b/tests/unit/unit1307.c
index 983237e48..c26e80cd0 100644
--- a/tests/unit/unit1307.c
+++ b/tests/unit/unit1307.c
@@ -19,9 +19,10 @@
* KIND, either express or implied.
*
***************************************************************************/
-#include "curl_fnmatch.h"
#include "curlcheck.h"
+#include "curl_fnmatch.h"
+
#define MATCH CURL_FNMATCH_MATCH
#define NOMATCH CURL_FNMATCH_NOMATCH
#define RE_ERR CURL_FNMATCH_FAIL