diff options
author | Andrea Shepard <andrea@torproject.org> | 2014-07-25 21:41:03 -0700 |
---|---|---|
committer | Andrea Shepard <andrea@torproject.org> | 2014-07-25 21:41:03 -0700 |
commit | b8b46e8ef847c0683fab00783fb64bef0c6f83c6 (patch) | |
tree | ac6685e52c73e51acbe05eb14dece77583d9ebc9 /src/or/transports.c | |
parent | 18c97ad8bc85b9c0a0b3cac088f719f7e261c60b (diff) | |
download | tor-b8b46e8ef847c0683fab00783fb64bef0c6f83c6.tar.gz tor-b8b46e8ef847c0683fab00783fb64bef0c6f83c6.zip |
Add some mocks needed to unit test ClientTransportPlugin/ServerTransportPlugin config line parsing
Diffstat (limited to 'src/or/transports.c')
-rw-r--r-- | src/or/transports.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/or/transports.c b/src/or/transports.c index dc30754162..0fb5926681 100644 --- a/src/or/transports.c +++ b/src/or/transports.c @@ -324,9 +324,9 @@ transport_add(transport_t *t) /** Remember a new pluggable transport proxy at <b>addr</b>:<b>port</b>. * <b>name</b> is set to the name of the protocol this proxy uses. * <b>socks_ver</b> is set to the SOCKS version of the proxy. */ -int -transport_add_from_config(const tor_addr_t *addr, uint16_t port, - const char *name, int socks_ver) +MOCK_IMPL(int, +transport_add_from_config, (const tor_addr_t *addr, uint16_t port, + const char *name, int socks_ver)) { transport_t *t = transport_new(addr, port, name, socks_ver, NULL); @@ -1349,9 +1349,9 @@ managed_proxy_create(const smartlist_t *transport_list, * Requires that proxy_argv be a NULL-terminated array of command-line * elements, containing at least one element. **/ -void -pt_kickstart_proxy(const smartlist_t *transport_list, - char **proxy_argv, int is_server) +MOCK_IMPL(void, +pt_kickstart_proxy, (const smartlist_t *transport_list, + char **proxy_argv, int is_server)) { managed_proxy_t *mp=NULL; transport_t *old_transport = NULL; |