diff -r 0d2d8ca879d8 -r a58ad50911fc src/test/irc_net.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/test/irc_net.h Mon May 04 20:55:04 2009 +0300 @@ -0,0 +1,28 @@ +#ifndef TEST_IRC_NET_H +#define TEST_IRC_NET_H + +/** + * @file + * + * Functionality for testing irc_net + */ +#include "../irc_net.h" +#include "transport.h" + +/** + * Setup an irc_net using the given socket, and consume the register request output, but do not push the RPL_WELCOME. + */ +struct irc_net* setup_irc_net_unregistered (struct transport_test *tp); + +/** + * Push the RPL_WELCOME reply. + */ +void test_irc_net_welcome (struct transport_test *tp, struct irc_net *net); + +/** + * Creates an irc_net and puts it into the registered state + */ +struct irc_net* setup_irc_net (struct transport_test *tp); + + +#endif /* TEST_IRC_NET_H */