aboutsummaryrefslogtreecommitdiff
path: root/tests/unit
diff options
context:
space:
mode:
authorMarcel Raad <Marcel.Raad@teamviewer.com>2019-02-14 09:35:54 +0100
committerMarcel Raad <Marcel.Raad@teamviewer.com>2019-02-15 09:50:52 +0100
commit208c77713aaab87d77a3b11f83308b7db61aaabc (patch)
tree625f02a6eeb3bcc1148e2c140d1316e926dacbfc /tests/unit
parent9e08b415f4246485a1f5b4c2b9d6d4167cb41b54 (diff)
unit1307: just fail without FTP support
I missed to check this in with commit 71786c0505926aaf7e9b2477b2fb7ee16a915ec6, which only disabled the test. This fixes the actual linker error. Closes https://github.com/curl/curl/pull/3568
Diffstat (limited to 'tests/unit')
-rw-r--r--tests/unit/unit1307.c31
1 files changed, 22 insertions, 9 deletions
diff --git a/tests/unit/unit1307.c b/tests/unit/unit1307.c
index d6664ff69..91e4606b7 100644
--- a/tests/unit/unit1307.c
+++ b/tests/unit/unit1307.c
@@ -23,6 +23,17 @@
#include "curl_fnmatch.h"
+static CURLcode unit_setup(void)
+{
+ return CURLE_OK;
+}
+
+static void unit_stop(void)
+{
+}
+
+#ifndef CURL_DISABLE_FTP
+
/*
CURL_FNMATCH_MATCH 0
CURL_FNMATCH_NOMATCH 1
@@ -239,15 +250,6 @@ static const struct testcase tests[] = {
"a", NOMATCH|LINUX_FAIL}
};
-static CURLcode unit_setup(void)
-{
- return CURLE_OK;
-}
-
-static void unit_stop(void)
-{
-}
-
static const char *ret2name(int i)
{
switch(i) {
@@ -308,3 +310,14 @@ UNITTEST_START
}
}
UNITTEST_STOP
+
+#else
+
+UNITTEST_START
+{
+ /* nothing to do, just fail */
+ return 1;
+}
+UNITTEST_STOP
+
+#endif