2 | 2 |
Forwarded: not-needed
|
3 | 3 |
--- a/test/framework.c
|
4 | 4 |
+++ b/test/framework.c
|
5 | |
@@ -25,6 +25,10 @@
|
|
5 |
@@ -26,12 +26,14 @@
|
6 | 6 |
#include <check.h>
|
7 | 7 |
#include <ulfius.h>
|
8 | 8 |
|
9 | |
+#define BODY_NOT_REDIRECTED "This is the blue pill"
|
10 | |
+#define BODY_REDIRECTED "Welcome to the Matrix, Neo!"
|
11 | |
+
|
12 | 9 |
+#if 0
|
13 | 10 |
#define SMTP_FROM "sender@localhost"
|
14 | 11 |
#define SMTP_TO "recipient@localhost"
|
15 | 12 |
#define SMTP_HOST "localhost"
|
16 | |
@@ -36,9 +40,6 @@
|
|
13 |
#define SMTP_PORT 2525
|
|
14 |
#define SMTP_SUBJECT "E-mail subject for the test"
|
|
15 |
#define SMTP_BODY "E-mail body for the test as well"
|
|
16 |
+#endif
|
|
17 |
|
|
18 |
#define BACKLOG_MAX (10)
|
17 | 19 |
#define BUF_SIZE 4096
|
18 | |
#define STREQU(a,b) (strcmp(a, b) == 0)
|
|
20 |
@@ -40,6 +42,7 @@
|
|
21 |
#define BODY_NOT_REDIRECTED "This is the blue pill"
|
|
22 |
#define BODY_REDIRECTED "Welcome to the Matrix, Neo!"
|
19 | 23 |
|
20 | |
-#define BODY_NOT_REDIRECTED "This is the blue pill"
|
21 | |
-#define BODY_REDIRECTED "Welcome to the Matrix, Neo!"
|
22 | |
-
|
|
24 |
+#if 0
|
23 | 25 |
#define PORT_PLAIN 2525
|
24 | 26 |
#define PORT_RICH 2526
|
25 | 27 |
#define FROM "from"
|
26 | |
@@ -240,6 +241,7 @@
|
|
28 |
@@ -49,6 +52,7 @@
|
|
29 |
#define CONTENT_TYPE "text/ulfius; charset=utf-42"
|
|
30 |
#define SUBJECT "subject"
|
|
31 |
#define BODY "mail body"
|
|
32 |
+#endif
|
|
33 |
|
|
34 |
#define KEY1 "key1"
|
|
35 |
#define KEY2 "kéy2"
|
|
36 |
@@ -66,6 +70,7 @@
|
|
37 |
int sockfd;
|
|
38 |
};
|
|
39 |
|
|
40 |
+#if 0
|
|
41 |
/**
|
|
42 |
*
|
|
43 |
* Function that emulates a very simple SMTP server
|
|
44 |
@@ -251,6 +256,7 @@
|
27 | 45 |
|
28 | 46 |
pthread_exit(NULL);
|
29 | 47 |
}
|
|
31 | 49 |
|
32 | 50 |
static char * get_file_content(const char * file_path) {
|
33 | 51 |
char * buffer = NULL;
|
34 | |
@@ -1270,6 +1272,7 @@
|
|
52 |
@@ -1303,6 +1309,7 @@
|
35 | 53 |
}
|
36 | 54 |
END_TEST
|
37 | 55 |
|
|
39 | 57 |
START_TEST(test_ulfius_send_smtp)
|
40 | 58 |
{
|
41 | 59 |
pthread_t thread;
|
42 | |
@@ -1324,6 +1327,7 @@
|
|
60 |
@@ -1357,6 +1364,7 @@
|
43 | 61 |
manager.mail_data = NULL;
|
44 | 62 |
}
|
45 | 63 |
END_TEST
|
|
47 | 65 |
|
48 | 66 |
START_TEST(test_ulfius_follow_redirect)
|
49 | 67 |
{
|
50 | |
@@ -1564,8 +1568,10 @@
|
|
68 |
@@ -1634,8 +1642,10 @@
|
51 | 69 |
tcase_add_test(tc_core, test_ulfius_utf8_ignored);
|
52 | 70 |
tcase_add_test(tc_core, test_ulfius_endpoint_callback_position);
|
53 | 71 |
tcase_add_test(tc_core, test_ulfius_MHD_set_response_with_other_free);
|