MCPcopy
hub / github.com/sshuttle/sshuttle / test_get_tcp_dstip

Function test_get_tcp_dstip

tests/client/test_methods_tproxy.py:17–22  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

15
16
17def test_get_tcp_dstip():
18 sock = Mock()
19 sock.getsockname.return_value = ('127.0.0.1', 1024)
20 method = get_method('tproxy')
21 assert method.get_tcp_dstip(sock) == ('127.0.0.1', 1024)
22 assert sock.mock_calls == [call.getsockname()]
23
24
25@patch("sshuttle.methods.tproxy.recv_udp")

Callers

nothing calls this directly

Calls 2

get_methodFunction · 0.90
get_tcp_dstipMethod · 0.45

Tested by

no test coverage detected