1 /*
2  * ProFTPD - FTP server API testsuite
3  * Copyright (c) 2008-2017 The ProFTPD Project team
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA.
18  *
19  * As a special exemption, The ProFTPD Project team and other respective
20  * copyright holders give permission to link this program with OpenSSL, and
21  * distribute the resulting executable, without including the source code for
22  * OpenSSL in the source distribution.
23  */
24 
25 /* Testsuite management */
26 
27 #ifndef PR_TESTS_H
28 #define PR_TESTS_H
29 
30 #include "conf.h"
31 #include "privs.h"
32 
33 #ifdef HAVE_CHECK_H
34 # include <check.h>
35 #else
36 # error "Missing Check installation; necessary for ProFTPD testsuite"
37 #endif
38 
39 int tests_stubs_set_main_server(server_rec *);
40 int tests_stubs_set_next_cmd(cmd_rec *);
41 
42 Suite *tests_get_pool_suite(void);
43 Suite *tests_get_array_suite(void);
44 Suite *tests_get_str_suite(void);
45 Suite *tests_get_sets_suite(void);
46 Suite *tests_get_timers_suite(void);
47 Suite *tests_get_table_suite(void);
48 Suite *tests_get_var_suite(void);
49 Suite *tests_get_event_suite(void);
50 Suite *tests_get_env_suite(void);
51 Suite *tests_get_random_suite(void);
52 Suite *tests_get_version_suite(void);
53 Suite *tests_get_feat_suite(void);
54 Suite *tests_get_netaddr_suite(void);
55 Suite *tests_get_netacl_suite(void);
56 Suite *tests_get_class_suite(void);
57 Suite *tests_get_regexp_suite(void);
58 Suite *tests_get_expr_suite(void);
59 Suite *tests_get_scoreboard_suite(void);
60 Suite *tests_get_stash_suite(void);
61 Suite *tests_get_modules_suite(void);
62 Suite *tests_get_cmd_suite(void);
63 Suite *tests_get_response_suite(void);
64 Suite *tests_get_fsio_suite(void);
65 Suite *tests_get_netio_suite(void);
66 Suite *tests_get_trace_suite(void);
67 Suite *tests_get_parser_suite(void);
68 Suite *tests_get_pidfile_suite(void);
69 Suite *tests_get_config_suite(void);
70 Suite *tests_get_auth_suite(void);
71 Suite *tests_get_filter_suite(void);
72 Suite *tests_get_inet_suite(void);
73 Suite *tests_get_data_suite(void);
74 Suite *tests_get_ascii_suite(void);
75 Suite *tests_get_help_suite(void);
76 Suite *tests_get_rlimit_suite(void);
77 Suite *tests_get_encode_suite(void);
78 Suite *tests_get_privs_suite(void);
79 Suite *tests_get_display_suite(void);
80 Suite *tests_get_misc_suite(void);
81 Suite *tests_get_json_suite(void);
82 Suite *tests_get_jot_suite(void);
83 Suite *tests_get_redis_suite(void);
84 Suite *tests_get_error_suite(void);
85 
86 /* Temporary hack/placement (in stubs.c) for this variable,
87  * until we get to testing the Signals API.
88  */
89 extern volatile unsigned int recvd_signal_flags;
90 
91 extern char ServerType;
92 extern int ServerUseReverseDNS;
93 extern server_rec *main_server;
94 extern pid_t mpid;
95 extern module *loaded_modules;
96 extern module *static_modules[];
97 
98 #endif /* PR_TESTS_H */
99