168
|
1 |
#ifndef TEST_IRC_CONN_H
|
|
2 |
#define TEST_IRC_CONN_H
|
|
3 |
|
|
4 |
/**
|
|
5 |
* @file
|
|
6 |
*
|
|
7 |
* Utility test functions for irc_conn related tests
|
|
8 |
*/
|
|
9 |
#include "../irc_conn.h"
|
|
10 |
#include "transport.h"
|
|
11 |
|
|
12 |
/**
|
|
13 |
* Callback flags
|
|
14 |
*/
|
|
15 |
struct test_conn_ctx {
|
|
16 |
/** Callback flags */
|
|
17 |
bool on_registered, on_TEST, on_error, on_quit;
|
|
18 |
};
|
|
19 |
|
|
20 |
/**
|
|
21 |
* Create and return a new irc_conn with the given ctx (will be initialized to zero).
|
|
22 |
*
|
|
23 |
* The returned irc_conn will be in the registered state.
|
|
24 |
*
|
|
25 |
* Use irc_conn_destroy to clean up the returned irc_conn.
|
|
26 |
*/
|
|
27 |
struct irc_conn* setup_irc_conn (struct transport_test *tp, bool noisy, struct test_conn_ctx *ctx);
|
|
28 |
|
|
29 |
#endif /* TEST_IRC_CONN_H */
|